diff options
author | LemonBoy <thatlemon@gmail.com> | 2017-10-21 10:44:53 +0200 |
---|---|---|
committer | LemonBoy <thatlemon@gmail.com> | 2018-01-07 12:36:18 +0100 |
commit | 57827ca743e95a6b6ad830fab03f46efaf1d9069 (patch) | |
tree | c2702ebbc3cb3ce91221f62219cdfa691dbb9390 | |
parent | d21706e1cc78284d5e7b2d69ebe4873e459d0e9b (diff) | |
download | irssi-57827ca743e95a6b6ad830fab03f46efaf1d9069.zip |
Don't free the hash table if there's none
Glib doesn't like that and shows a harmless warning.
-rw-r--r-- | src/irc/core/irc-servers.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/irc/core/irc-servers.c b/src/irc/core/irc-servers.c index 7fd83045..3b4e1a52 100644 --- a/src/irc/core/irc-servers.c +++ b/src/irc/core/irc-servers.c @@ -443,8 +443,10 @@ static void sig_disconnected(IRC_SERVER_REC *server) gslist_free_full(server->cap_active, (GDestroyNotify) g_free); server->cap_active = NULL; - g_hash_table_destroy(server->cap_supported); - server->cap_supported = NULL; + if (server->cap_supported) { + g_hash_table_destroy(server->cap_supported); + server->cap_supported = NULL; + } gslist_free_full(server->cap_queue, (GDestroyNotify) g_free); server->cap_queue = NULL; |