dbus_server_listen: Assert that implementations return a known result

If they didn't, we'd probably leak the server and/or the error.

Signed-off-by: Simon McVittie <smcv@collabora.com>
Reviewed-by: Philip Withnall <withnall@endlessm.com>
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=107194
This commit is contained in:
Simon McVittie 2018-07-11 16:14:27 +01:00
parent b940ccdbd1
commit 8868aac95d

View file

@ -631,6 +631,10 @@ dbus_server_listen (const char *address,
/* keep trying addresses */
}
else
{
_dbus_assert_not_reached ("Unknown result in dbus_server_listen");
}
}
_dbus_assert (server == NULL);