mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-25 06:56:14 +01:00
gnetworkmonitornm: Set a GError properly on an error handling path
All the other initialisation failure paths set a GError, but this one didn’t. Set a GError to avoid breaking the invariant that returning FALSE should always have a GError set. Signed-off-by: Philip Withnall <withnall@endlessm.com> https://gitlab.gnome.org/GNOME/glib/issues/1523
This commit is contained in:
parent
5bc35a7245
commit
c5761146bc
@ -309,6 +309,8 @@ g_network_monitor_nm_initable_init (GInitable *initable,
|
||||
|
||||
if (!name_owner)
|
||||
{
|
||||
g_set_error (error, G_IO_ERROR, G_IO_ERROR_FAILED,
|
||||
_("NetworkManager not running"));
|
||||
g_object_unref (proxy);
|
||||
return FALSE;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user