gtkicontheme: check if the context quark string is not null
On windows you might not have a theme installed by default which means that when trying to create the context quark it will fail. If then we try to replace a NULL key in the hash table it will crash. https://bugzilla.gnome.org/show_bug.cgi?id=769859
This commit is contained in:
@@ -3179,7 +3179,8 @@ theme_list_contexts (IconTheme *theme,
|
||||
dir = l->data;
|
||||
|
||||
context = g_quark_to_string (dir->context);
|
||||
g_hash_table_replace (contexts, (gpointer) context, NULL);
|
||||
if (context != NULL)
|
||||
g_hash_table_replace (contexts, (gpointer) context, NULL);
|
||||
|
||||
l = l->next;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user