aboutsummaryrefslogtreecommitdiff
path: root/libdbusmenu-glib
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2011-01-18 10:47:32 -0600
committerTed Gould <ted@gould.cx>2011-01-18 10:47:32 -0600
commit6cb4e78579f4d202ca797dfbc9a998e1cc58186a (patch)
treec178c0cd75d5910e47939c09161055d0552c49f8 /libdbusmenu-glib
parent74ccb9b179c63ae79719b480247bb844326ab675 (diff)
downloadlibdbusmenu-6cb4e78579f4d202ca797dfbc9a998e1cc58186a.tar.gz
libdbusmenu-6cb4e78579f4d202ca797dfbc9a998e1cc58186a.tar.bz2
libdbusmenu-6cb4e78579f4d202ca797dfbc9a998e1cc58186a.zip
Warn when can't parse.
Diffstat (limited to 'libdbusmenu-glib')
-rw-r--r--libdbusmenu-glib/server.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/libdbusmenu-glib/server.c b/libdbusmenu-glib/server.c
index 75a305c..6be2a60 100644
--- a/libdbusmenu-glib/server.c
+++ b/libdbusmenu-glib/server.c
@@ -1009,7 +1009,13 @@ bus_get_children (DbusmenuServer * server, GVariant * params, GDBusMethodInvocat
ret = g_variant_new("(a(ia{svg}))", g_variant_builder_end(&builder));
} else {
- ret = g_variant_parse(g_variant_type_new("(a(ia{sv}))"), "([(0, {})],)", NULL, NULL, NULL);
+ GError * error = NULL;
+ ret = g_variant_parse(g_variant_type_new("(a(ia{sv}))"), "([(0, {})],)", NULL, NULL, &error);
+ if (error != NULL) {
+ g_warning("Unable to parse '([(0, {})],)' as a '(a(ia{sv}))': %s", error->message);
+ g_error_free(error);
+ ret = NULL;
+ }
}
g_dbus_method_invocation_return_value(invocation, ret);