From: Daniel P. Berrange Date: Mon, 22 Jul 2013 15:32:28 +0000 (+0100) Subject: Fix handling of DBus errors emitted by the bus itself X-Git-Tag: v1.1.1-rc1~12 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c64904b7459b2f21e55221bf977119dc77a4be55;p=thirdparty%2Flibvirt.git Fix handling of DBus errors emitted by the bus itself Current code for handling dbus errors only works for errors received from the remote application itself. We must also handle errors emitted by the bus itself, for example, when it fails to spawn the target service. Signed-off-by: Daniel P. Berrange --- diff --git a/src/util/virdbus.c b/src/util/virdbus.c index 6221bdc4da..9b0977a5f6 100644 --- a/src/util/virdbus.c +++ b/src/util/virdbus.c @@ -1129,9 +1129,8 @@ int virDBusCallMethod(DBusConnection *conn, call, VIR_DBUS_METHOD_CALL_TIMEOUT_MILLIS, &error))) { - virReportError(VIR_ERR_INTERNAL_ERROR, - _("Cannot send to %s.%s on path %s with interface %s: %s"), - destination, member, path, interface, NULLSTR(error.message)); + virReportDBusServiceError(error.message ? error.message : "unknown error", + error.name); goto cleanup; }