Comment 7 for bug 1313042

Revision history for this message
Manfred Hampl (m-hampl) wrote : Re: console-kit-daemon session hang (sometimes w/ Glib-CRITICAL warning)

I assume that the GLIB-Critical messages can be avoided by adding some statements to reset the IDs in the source to prevent calling g_source_remove with an id that was already removed once:

e.g. for consolekit:
ck-job.c
        if (job->priv->out_watch_id > 0) {
                g_source_remove (job->priv->out_watch_id);
+ job->priv->out_watch_id = 0;
        }
        if (job->priv->err_watch_id > 0) {
                g_source_remove (job->priv->err_watch_id);
+ job->priv->err_watch_id = 0;
        }

ck-run-programs.c
        g_source_remove (cd->timeout_id);
+ cd->timeout_id = 0;

ck-tty-idle-monitor.c
        if (tty_idle_monitor->priv->timeout_id > 0) {
                g_source_remove (tty_idle_monitor->priv->timeout_id);
+ tty_idle_monitor->priv->timeout_id = 0;
        }

ck-vt-monitor.c
        if (vt_monitor->priv->process_queue_id > 0) {
                g_source_remove (vt_monitor->priv->process_queue_id);
+ vt_monitor->priv->process_queue_id = 0;
        }

(Not sure whether I correctly identified all cases where a variable should be reset after use.)
As already stated by others - the ssh hang most probably is not related to the GLIB critical error message noise.