Mon, 05 May 2008 14:56:36 +0000
Patch from sadrul to fix IRC servers which neglect to send RPL_LISTSTART
(321) before sending their channel list with RPL_LIST (322).
Fixes #2225
| ChangeLog | file | annotate | diff | comparison | revisions | |
| libpurple/protocols/irc/msgs.c | file | annotate | diff | comparison | revisions |
--- a/ChangeLog Mon May 05 04:54:37 2008 +0000 +++ b/ChangeLog Mon May 05 14:56:36 2008 +0000 @@ -9,6 +9,8 @@ switching between different operating systems. * Fix reception of IRC PART without a part message on Undernet (fixes a problem with litter in the channel user list). + * IRC no longer crashes on /list on servers which erroneously omit + RPL_LISTSTART. Pidgin: * The typing notification in the conversation history can be disabled or
--- a/libpurple/protocols/irc/msgs.c Mon May 05 04:54:37 2008 +0000 +++ b/libpurple/protocols/irc/msgs.c Mon May 05 14:56:36 2008 +0000 @@ -422,6 +422,11 @@ if (!args[0] || !args[1] || !args[2] || !args[3]) return; + if (!purple_roomlist_get_in_progress(irc->roomlist)) { + purple_debug_warning("irc", "Buggy server didn't send RPL_LISTSTART.\n"); + purple_roomlist_set_in_progress(irc->roomlist, TRUE); + } + room = purple_roomlist_room_new(PURPLE_ROOMLIST_ROOMTYPE_ROOM, args[1], NULL); purple_roomlist_room_add_field(irc->roomlist, room, args[1]); purple_roomlist_room_add_field(irc->roomlist, room, GINT_TO_POINTER(strtol(args[2], NULL, 10)));