mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-23 10:42:11 +01:00
GDesktopAppInfo: Ignore flushing the session bus when there's not
In some cases (such as in our CI tests) we may not have any dbus session set after launching, but we always assumed so. In case we have not a session bus set, we only have to return early. (cherry-picked from commit eee15225c74559f1ba02c78175a25be186cf1cf7)
This commit is contained in:
parent
b4dde57935
commit
d1766e99e5
@ -3354,11 +3354,16 @@ launch_uris_bus_get_cb (GObject *object,
|
||||
g_task_return_error (task, g_steal_pointer (&error));
|
||||
g_object_unref (task);
|
||||
}
|
||||
else
|
||||
else if (session_bus)
|
||||
g_dbus_connection_flush (session_bus,
|
||||
cancellable,
|
||||
launch_uris_flush_cb,
|
||||
g_steal_pointer (&task));
|
||||
else
|
||||
{
|
||||
g_task_return_boolean (task, TRUE);
|
||||
g_clear_object (&task);
|
||||
}
|
||||
}
|
||||
|
||||
g_clear_object (&session_bus);
|
||||
|
Loading…
x
Reference in New Issue
Block a user