aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2011-02-14 22:33:02 -0600
committerTed Gould <ted@gould.cx>2011-02-14 22:33:02 -0600
commit3cebed3db50dd6325c725d87a6ec5eabc21d2ba3 (patch)
treecd921faf8fdc2474c3f53ab44fa96b96190c6f35
parenteef89215a5632e7e08b39bab1ab9795b5cdebf7d (diff)
downloadlibdbusmenu-3cebed3db50dd6325c725d87a6ec5eabc21d2ba3.tar.gz
libdbusmenu-3cebed3db50dd6325c725d87a6ec5eabc21d2ba3.tar.bz2
libdbusmenu-3cebed3db50dd6325c725d87a6ec5eabc21d2ba3.zip
Making sure the root isn't NULL before continuing
-rw-r--r--tests/test-glib-layout-client.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/test-glib-layout-client.c b/tests/test-glib-layout-client.c
index 5ea0cf8..3afe042 100644
--- a/tests/test-glib-layout-client.c
+++ b/tests/test-glib-layout-client.c
@@ -81,6 +81,11 @@ layout_updated (DbusmenuClient * client, gpointer data)
g_debug("Layout Updated");
DbusmenuMenuitem * menuroot = dbusmenu_client_get_root(client);
+ if (menuroot == NULL) {
+ g_debug("Root NULL, waiting");
+ return;
+ }
+
layout_t * layout = &layouts[layouton];
if (!verify_root_to_layout(menuroot, layout)) {