1
0
mirror of https://github.com/irssi/irssi.git synced 2025-02-02 15:08:01 -05:00

restore compat with glib <2.40

This commit is contained in:
ailin-nemui 2018-02-08 14:41:02 +01:00
parent 02712942e0
commit 16912e1a91

View File

@ -158,11 +158,12 @@ static void event_cap (IRC_SERVER_REC *server, char *args, char *nick, char *add
continue;
}
if (!g_hash_table_insert(server->cap_supported, key, val)) {
if (g_hash_table_lookup_extended(server->cap_supported, key, NULL, NULL)) {
/* The specification doesn't say anything about
* duplicated values, let's just warn the user */
g_warning("The server sent the %s capability twice", key);
}
g_hash_table_insert(server->cap_supported, key, val);
}
/* A multiline response is always terminated by a normal one,