gmain: remove unix signal watch if its GSourceFunc returns FALSE

g_unix_signal_watch_dispatch() was ignore the callback's return value.
Fix that.

https://bugzilla.gnome.org/show_bug.cgi?id=682560
This commit is contained in:
Dan Winship 2012-08-23 12:38:17 -04:00
parent 99c7c951d9
commit 2427378223

View File

@ -4499,6 +4499,7 @@ g_unix_signal_watch_dispatch (GSource *source,
gpointer user_data)
{
GUnixSignalWatchSource *unix_signal_source;
gboolean again;
unix_signal_source = (GUnixSignalWatchSource *) source;
@ -4509,11 +4510,11 @@ g_unix_signal_watch_dispatch (GSource *source,
return FALSE;
}
(callback) (user_data);
again = (callback) (user_data);
unix_signal_source->pending = FALSE;
return TRUE;
return again;
}
static void