summaryrefslogtreecommitdiffstats
path: root/avahi-gobject
diff options
context:
space:
mode:
authorSjoerd Simons <sjoerd@debian.org>2008-06-13 11:11:49 +0000
committerSjoerd Simons <sjoerd@debian.org>2008-06-13 11:11:49 +0000
commit505fd1b5c1dadff46f4b50df76f9ee978351b3dc (patch)
tree7b5620e7a9266ec26aebc62c02f3ce8f35faa7de /avahi-gobject
parentfd17ab54721e05b354610467d0dfc6f1e693c9a8 (diff)
Remove entries from the GaEntryGroupService entry hashed using GaEntryGroupServiceEntry instead of strings. Fixes crash when calling ga_entry_group_service_remove_key
git-svn-id: file:///home/lennart/svn/public/avahi/trunk@1784 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe
Diffstat (limited to 'avahi-gobject')
-rw-r--r--avahi-gobject/ga-entry-group.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/avahi-gobject/ga-entry-group.c b/avahi-gobject/ga-entry-group.c
index cfe12f6..c4f2e37 100644
--- a/avahi-gobject/ga-entry-group.c
+++ b/avahi-gobject/ga-entry-group.c
@@ -556,8 +556,12 @@ gboolean ga_entry_group_service_set_arbitrary(GaEntryGroupService * service,
gboolean ga_entry_group_service_remove_key(GaEntryGroupService * service,
const gchar * key, GError ** error) {
GaEntryGroupServicePrivate *priv = (GaEntryGroupServicePrivate *) service;
+ GaEntryGroupServiceEntry entry;
- g_hash_table_remove(priv->entries, key);
+ entry.value = key;
+ entry.size = strlen(key);
+
+ g_hash_table_remove(priv->entries, &entry);
if (!priv->frozen)
return ga_entry_group_service_thaw(service, error);