diff --git a/src/irc/dcc/dcc.c b/src/irc/dcc/dcc.c index eca4fe64..01ab0e59 100644 --- a/src/irc/dcc/dcc.c +++ b/src/irc/dcc/dcc.c @@ -57,8 +57,9 @@ void dcc_unregister_type(const char *type) pos = gslist_find_string(dcc_types, type); if (pos != NULL) { - dcc_types = g_slist_remove(dcc_types, pos->data); - g_free(pos->data); + void *tmp = pos->data; + dcc_types = g_slist_remove(dcc_types, pos->data); + g_free(tmp); } }