_dbus_change_to_daemon_user (audit code path): set DBusError correctly

The other error cases here all set the error instead of just warning.

Signed-off-by: Simon McVittie <smcv@debian.org>
Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de>
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=97009
This commit is contained in:
Simon McVittie 2016-07-21 10:55:06 +01:00 committed by Simon McVittie
parent 76ae52735e
commit b7d280f623

View file

@ -166,8 +166,9 @@ _dbus_change_to_daemon_user (const char *user,
_dbus_strerror (errno));
break;
case -5:
_dbus_warn ("Failed to drop supplementary groups: %s\n",
_dbus_strerror (errno));
dbus_set_error (error, _dbus_error_from_errno (errno),
"Failed to drop supplementary groups: %s",
_dbus_strerror (errno));
break;
case -6:
dbus_set_error (error, _dbus_error_from_errno (errno),