summaryrefslogtreecommitdiffstats
path: root/src/pulsecore
diff options
context:
space:
mode:
authorTanu Kaskinen <ext-tanu.kaskinen@nokia.com>2009-12-03 15:28:36 +0200
committerColin Guthrie <cguthrie@mandriva.org>2009-12-03 21:50:19 +0000
commit7b1b68ce2cfbc735065f1af45811f33a8a6bf6ea (patch)
tree83140ce4f729b2979ccad6b2b70aa17b2d9bb42a /src/pulsecore
parent4c793cfc76360676b3881d7943b49adf892594d2 (diff)
dbus: Handle the cases when a non-existing interface is detected in an incoming message.
Diffstat (limited to 'src/pulsecore')
-rw-r--r--src/pulsecore/protocol-dbus.c8
-rw-r--r--src/pulsecore/protocol-dbus.h1
2 files changed, 9 insertions, 0 deletions
diff --git a/src/pulsecore/protocol-dbus.c b/src/pulsecore/protocol-dbus.c
index e427bb19..95518a13 100644
--- a/src/pulsecore/protocol-dbus.c
+++ b/src/pulsecore/protocol-dbus.c
@@ -552,10 +552,18 @@ static DBusHandlerResult handle_message_cb(DBusConnection *connection, DBusMessa
pa_dbus_send_error(connection, message, DBUS_ERROR_UNKNOWN_METHOD, "No such method: %s", call_info.method);
break;
+ case NO_SUCH_INTERFACE:
+ pa_dbus_send_error(connection, message, PA_DBUS_ERROR_NO_SUCH_INTERFACE, "No such interface: %s", call_info.interface);
+ break;
+
case NO_SUCH_PROPERTY:
pa_dbus_send_error(connection, message, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "No such property: %s", call_info.property);
break;
+ case NO_SUCH_PROPERTY_INTERFACE:
+ pa_dbus_send_error(connection, message, PA_DBUS_ERROR_NO_SUCH_INTERFACE, "No such property interface: %s", call_info.property_interface);
+ break;
+
case INVALID_METHOD_SIG:
pa_dbus_send_error(connection, message, DBUS_ERROR_INVALID_ARGS,
"Invalid signature for method %s: '%s'. Expected '%s'.",
diff --git a/src/pulsecore/protocol-dbus.h b/src/pulsecore/protocol-dbus.h
index 6d100f7c..89999337 100644
--- a/src/pulsecore/protocol-dbus.h
+++ b/src/pulsecore/protocol-dbus.h
@@ -35,6 +35,7 @@
#define PA_DBUS_CORE_INTERFACE "org.PulseAudio.Core1"
#define PA_DBUS_CORE_OBJECT_PATH "/org/pulseaudio/core1"
+#define PA_DBUS_ERROR_NO_SUCH_INTERFACE PA_DBUS_CORE_INTERFACE ".NoSuchInterfaceError"
#define PA_DBUS_ERROR_NO_SUCH_PROPERTY PA_DBUS_CORE_INTERFACE ".NoSuchPropertyError"
#define PA_DBUS_ERROR_NOT_FOUND PA_DBUS_CORE_INTERFACE ".NotFoundError"