From: Martin Ling Date: Fri, 29 Aug 2014 16:35:46 +0000 (+0100) Subject: C++: Fix hash table initialisation in map_to_hash_variant. X-Git-Tag: libsigrok-0.4.0~1082 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=b31581f8a8fab97004603ba61c16c3758c14c777;p=libsigrok.git C++: Fix hash table initialisation in map_to_hash_variant. --- diff --git a/bindings/cxx/classes.cpp b/bindings/cxx/classes.cpp index bb7cec69..403499de 100644 --- a/bindings/cxx/classes.cpp +++ b/bindings/cxx/classes.cpp @@ -44,8 +44,7 @@ static const char *valid_string(const char *input) static GHashTable *map_to_hash_variant(map input) { auto output = g_hash_table_new_full( - g_variant_hash, g_variant_equal, g_free, - (void (*)(void *))g_variant_unref); + g_str_hash, g_str_equal, g_free, (GDestroyNotify) g_variant_unref); for (auto entry : input) g_hash_table_insert(output, g_strdup(entry.first.c_str()),