gui/queue: Set gq_queue->gq_visible to NULL after destroying

Otherwise the existance check will still pass the next time
__queue_filter() is called, and we will attempt to destroy it again.

Signed-off-by: Anna Schumaker <Anna@NoWheyCreamery.com>
This commit is contained in:
Anna Schumaker 2016-08-13 08:21:22 -04:00
parent f7e9e8b321
commit 085701ad9d
1 changed files with 3 additions and 1 deletions

View File

@ -91,8 +91,10 @@ void __queue_filter(GtkSearchEntry *entry, gpointer data)
gtk_tree_model_filter_refilter(GTK_TREE_MODEL_FILTER(gq_queue->gq_filter));
gui_view_scroll();
if (gq_queue->gq_visible)
if (gq_queue->gq_visible) {
g_hash_table_destroy(gq_queue->gq_visible);
gq_queue->gq_visible = NULL;
}
}
struct gui_queue *gui_queue_alloc(struct queue *queue, const gchar *text,