[pulseaudio-discuss] userdata not being relayed in callback method
Colin Guthrie
gmane at colin.guthr.ie
Wed Oct 14 00:28:33 PDT 2009
'Twas brillig, and Forwind info at 13/10/09 22:36 did gyre and gimble:
> Hi folks,
>
> I have made considerable progress from earlier on. I have almost
> completed my task but it looks as if there may be a bug or more than
> likely I'm being a bit stupid ?
>
> I'm on 0.9.1.4 on Jaunty.
>
> Scenario:
>
> On a PA_SUBSCRIPTION_EVENT_SINK_INPUT my subscription callback method is
> called with the relevant userdata obj which was passed in at the main
> method stage. All fine so far.
>
> After receiving this event, I then call
>
> pa_context_get_sink_input_info(c, index,
> context_get_sink_input_info_callback, userdata)); //please note at
> this point the userdata obj is as it should be.
>
> But when the callback is called the userdata obj is NULL !
>
> Any ideas ?
>
> Code is pasted below
The functions themselves look OK, but it's entirely possible
context_get_sink_input_info_callback() is used/called elsewhere too.
The error messages you print out are identical by the way... which may
lead to strange debug info.
I'd also try your app on a newer PA as .14 is quite old and was a bit of
a short lived release anyway, .15 was more of a long term release. That
said, I don't remember any specific commits claiming to fix callback
userdata, but that said, I've not read *every* commit and my memory is
not *always* reliable anyway :p
Col
--
Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/
Day Job:
Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
Mandriva Linux Contributor [http://www.mandriva.com/]
PulseAudio Hacker [http://www.pulseaudio.org/]
Trac Hacker [http://trac.edgewall.org/]
More information about the pulseaudio-discuss
mailing list