Summary: | JOIN sent during autojoin has useless channel keys | ||
---|---|---|---|
Product: | [Applications] konversation | Reporter: | Nicolás Alvarez <nalvarez> |
Component: | protocol | Assignee: | Konversation Developers <konversation-devel> |
Status: | RESOLVED FIXED | ||
Severity: | minor | CC: | hein |
Priority: | NOR | ||
Version: | Git | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Nicolás Alvarez
2010-07-31 02:36:21 UTC
I should add that while it behaving this way isn't pretty, it's also harmless - the code makes sure that no auto-join command is sent that exceeds the maximum buffer length instead (it produces multiple messages as necessary), so the wasted characters aren't fatal. Changing this code so it doesn't emit trailing ",." segments will complicate it considerably for relatively little gain. commit 978fd7b94d09c674ef76387bdc3ac34822bf4a96 Author: Eike Hein <hein@kde.org> Date: Sat Jul 31 19:34:59 2010 +0200 Pop off trailing placeholder segments in the last auto-join command. BUG:246321 diff --git a/ChangeLog b/ChangeLog index bd8fd86..f3edf35 100644 --- a/ChangeLog +++ b/ChangeLog @@ -48,6 +48,10 @@ Changes since 1.3.1: * Fixed a bug causing the chat text notification messages originating in the Watched Nicknames Online system to be logged in HTML format (and thus HTML source to be displayed e.g. in backlog replay). +* Fixed a (harmless) bug causing unnecessary trailing "." placeholder channel + key segments to be added to the raw format auto-join command (or to the + last of multiple such auto-join commands when the amount of auto-join + channels requires multiple commands to be generated). Changes from 1.3 to 1.3.1: diff --git a/src/irc/server.cpp b/src/irc/server.cpp index bc92da2..b87fd78 100644 --- a/src/irc/server.cpp +++ b/src/irc/server.cpp @@ -3597,6 +3597,8 @@ QStringList Server::generateJoinCommand(const Konversation::ChannelList &tmpList passwords << password; } + while (!passwords.isEmpty() && passwords.last() == ".") passwords.pop_back(); + joinCommands << "JOIN " + channels.join(",") + ' ' + passwords.join(","); return joinCommands; |