Re: [PATCH] device: disconnect signal handlers when modem object removed

2017-02-13 Thread Aleksander Morgado
On Mon, Feb 13, 2017 at 7:05 PM, Ben Chan wrote: > thanks. lgtm. The g_signal_handler_is_connected check in clear_modem seems > unnecessary though? Yeah, we don't really remove the signal handler in any other place, so should be unnecessary. Will fix that before pushing. Thanks for checking! -

Re: [PATCH] device: disconnect signal handlers when modem object removed

2017-02-13 Thread Ben Chan
thanks. lgtm. The g_signal_handler_is_connected check in clear_modem seems unnecessary though? On Mon, Feb 13, 2017 at 6:06 AM, Aleksander Morgado < aleksan...@aleksander.es> wrote: > Don't rely on the automatic disconnection of the signal as the last > reference of the modem object may outlive

[PATCH] device: disconnect signal handlers when modem object removed

2017-02-13 Thread Aleksander Morgado
Don't rely on the automatic disconnection of the signal as the last reference of the modem object may outlive the device object. Also, setup a common clear_modem() function to dispose the internal reference of the modem object, which will take care of the signal disconnection when required. https