[pulseaudio-discuss] Memory oddities in module-dbus-protocol

David Henningsson david.henningsson at canonical.com
Thu Jan 26 03:35:11 PST 2012


I'm trying to trace down a memory error in module-dbus-protocol, but I 
am confused.

Either you use synchronous hooks, and then you can reference the 
original core objects, or you use asynchronous subscription events, in 
which case the pointers can become dangling at any time, so you can't 
point into the core and have to make memory copies of *everything*. Right?

The card is handled by subscription events, and I get memory errors on 
quit [1] due to it referencing the profile's name as a hash key (!). But 
while investigating I also saw pa_dbusiface_card_profile objects having 
a pointer to the profile, which is disturbing.

If this is the only place where things are broken, I can fix it. But if 
the same logic faults apply to all over the dbus protocol module, that 
makes me quite uneasy with shipping it in a stable distribution, 
especially as I don't know any consumer that makes use of this information.

Comments/insights welcome.

-- 
David Henningsson, Canonical Ltd.
http://launchpad.net/~diwic

[1] http://paste.ubuntu.com/817509


More information about the pulseaudio-discuss mailing list