[at-spi2-core] Have the registry daemon return an error when fetching an invalid property
- From: Mike Gorse <mgorse src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [at-spi2-core] Have the registry daemon return an error when fetching an invalid property
- Date: Tue, 4 Jan 2011 18:44:15 +0000 (UTC)
commit 830e837b5e5861af08740a1b7467bd43d6e24d19
Author: Mike Gorse <mgorse novell com>
Date: Tue Jan 4 12:46:44 2011 -0600
Have the registry daemon return an error when fetching an invalid property
registryd/registry.c | 10 ++++++++++
1 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/registryd/registry.c b/registryd/registry.c
index 0f8edf6..57f6f10 100644
--- a/registryd/registry.c
+++ b/registryd/registry.c
@@ -1158,6 +1158,16 @@ handle_method_root (DBusConnection *bus, DBusMessage *message, void *user_data)
impl_get_ToolkitName (&iter, user_data);
else if (!strcmp (prop_member, "ToolkitVersion"))
impl_get_ToolkitVersion (&iter, user_data);
+ else
+ {
+ dbus_message_unref (reply);
+ reply = dbus_message_new_error (message, DBUS_ERROR_FAILED, "Property unavailable");
+ }
+ }
+ else
+ {
+ dbus_message_unref (reply);
+ reply = dbus_message_new_error (message, DBUS_ERROR_FAILED, "Property unavailable");
}
}
else
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]