aboutsummaryrefslogtreecommitdiff
path: root/libdbusmenu-glib
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2011-02-24 08:18:31 -0600
committerTed Gould <ted@gould.cx>2011-02-24 08:18:31 -0600
commit59469d1643fdc81563544da189bf773fe1b80367 (patch)
tree6a264f9c186f0b7ed2da8871b2f6febd0acb4f74 /libdbusmenu-glib
parent6b5872cc49cefb1de3cf2395cca3f2e7a5efbfea (diff)
parent4c9b48b9f83801a398437f8fbf3f60a46d55b110 (diff)
downloadlibdbusmenu-59469d1643fdc81563544da189bf773fe1b80367.tar.gz
libdbusmenu-59469d1643fdc81563544da189bf773fe1b80367.tar.bz2
libdbusmenu-59469d1643fdc81563544da189bf773fe1b80367.zip
Make sure to not recurse if the value says we shouldn't
Diffstat (limited to 'libdbusmenu-glib')
-rw-r--r--libdbusmenu-glib/menuitem.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libdbusmenu-glib/menuitem.c b/libdbusmenu-glib/menuitem.c
index cdd2109..f7e4716 100644
--- a/libdbusmenu-glib/menuitem.c
+++ b/libdbusmenu-glib/menuitem.c
@@ -1436,7 +1436,7 @@ dbusmenu_menuitem_build_variant (DbusmenuMenuitem * mi, const gchar ** propertie
/* Pillage the children */
GList * children = dbusmenu_menuitem_get_children(mi);
- if (children == NULL && recurse != 0) {
+ if (children == NULL || recurse == 0) {
g_variant_builder_add_value(&tupleb, g_variant_new_array(G_VARIANT_TYPE_VARIANT, NULL, 0));
} else {
GVariantBuilder childrenbuilder;