Problem passing user_data in MMCall object state-changed signal

Aleksander Morgado aleksander at aleksander.es
Wed May 20 11:31:51 UTC 2020


Hey

>
> I am experiencing a strange issue with state-changed GSignal of MMCall object.
> In particular, my user-data is not passed, instead a pointer with an address like 0x01, at least so it seems via GDB.
>
> I connect my GSignal this way:
> call_statechange_signal = g_signal_connect(c, "state-changed", G_CALLBACK(av_mm_call_statechange), m);
>
> where m is my AvModem object.
>
> My callback looks like:
> static void av_mm_call_statechange(MMCall *c, MMCallState oldstate, MMCallState newstate, AvModem *m) {
> ...
> }
>
> Do you have any hints?
>

You're missing the "reason" parameter, see the docs:
https://www.freedesktop.org/software/ModemManager/libmm-glib/1.6.0/MmGdbusCall.html#MmGdbusCall-state-changed

-- 
Aleksander
https://aleksander.es


More information about the ModemManager-devel mailing list