aboutsummaryrefslogtreecommitdiff
path: root/libdbusmenu-glib/client.c
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2010-04-16 10:50:54 -0500
committerTed Gould <ted@gould.cx>2010-04-16 10:50:54 -0500
commitbd3f67fa6f4e0806c43f1bfb6517dad71702fe7b (patch)
treeb2836812b90e4dc13b4fccf865a1958ad4a21144 /libdbusmenu-glib/client.c
parent209320abfce67eef832cfe30a8c24b9505cf9718 (diff)
parent6085d46272fb067b475f433ecf5a5477dfa4e721 (diff)
downloadlibdbusmenu-bd3f67fa6f4e0806c43f1bfb6517dad71702fe7b.tar.gz
libdbusmenu-bd3f67fa6f4e0806c43f1bfb6517dad71702fe7b.tar.bz2
libdbusmenu-bd3f67fa6f4e0806c43f1bfb6517dad71702fe7b.zip
* Upstream Merge
* Decrementing refs when added to child menus
Diffstat (limited to 'libdbusmenu-glib/client.c')
-rw-r--r--libdbusmenu-glib/client.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/libdbusmenu-glib/client.c b/libdbusmenu-glib/client.c
index d61b1ae..f5e7115 100644
--- a/libdbusmenu-glib/client.c
+++ b/libdbusmenu-glib/client.c
@@ -810,6 +810,7 @@ parse_layout_xml(DbusmenuClient * client, xmlNodePtr node, DbusmenuMenuitem * it
dbusmenu_menuitem_child_delete(item, childmi);
}
dbusmenu_menuitem_child_add_position(item, newchildmi, position);
+ g_object_unref(newchildmi);
} else {
dbusmenu_menuitem_child_reorder(item, childmi, position);
}
@@ -847,9 +848,6 @@ parse_layout (DbusmenuClient * client, const gchar * layout)
xmlNodePtr root = xmlDocGetRootElement(xmldoc);
DbusmenuMenuitem * oldroot = priv->root;
- if (oldroot != NULL) {
- g_object_ref(oldroot);
- }
priv->root = parse_layout_xml(client, root, priv->root, NULL, priv->menuproxy);
xmlFreeDoc(xmldoc);