Fixes for upstream changes in GLib g_source_remove()