Project

General

Profile

Bug #1011

CTCP requests are not sent correctly

Added by flamingspinach over 14 years ago. Updated over 14 years ago.

Status:
Resolved
Priority:
Low
Assignee:
Category:
Quassel Core
Target version:
Start date:
08/10/2010
Due date:
% Done:

100%

Estimated time:
Version:
0.6.1
OS:
Any

Description

CTCP requests have an extra whitespace character in the message sent to the server. This causes some clients (such as X-Chat) to fail to recognize the standard CTCP requests, such as "VERSION", because they do not strip the whitespace from the received CTCP request, "VERSION ".

Marked this as core, though I'm not sure whether the client or the core is responsible here.

Associated revisions

Revision 9e4d32bf (diff)
Added by johu over 14 years ago

improved ctcp handler method, fixes #1011
do not add space in ctcp handler method pack if message is empty

Revision bb51c809 (diff)
Added by johu over 14 years ago

improved ctcp handler method, fixes #1011
do not add space in ctcp handler method pack if message is empty

History

#1 Updated by Anonymous over 14 years ago

i think the space comes from the non-existent 'message' after VERSION;

in src/core/ctcphandler.cpp(164) pack() is defined: return XDELIM + ctcpTag + ' ' + xdelimQuote(message) + XDELIM;
in src/core/ctcphandler.cpp(170) in query() one can find the following line
params << serverEncode(bufname) << lowLevelQuote(pack(serverEncode(ctcpTag), userEncode(bufname, message)));
here ctcpTag = 'VERSION' and message is whatever section() gives for empty stuff, see http://doc.trolltech.com/3.3/qstring.html#section

so to fix it, one would have to check whether message is empty and if so, don't pack it (i think)

#2 Updated by Anonymous over 14 years ago

i think the space comes from the non-existent 'message' after VERSION;

in src/core/ctcphandler.cpp(164) pack() is defined: return XDELIM + ctcpTag + ' ' + xdelimQuote(message) + XDELIM;
in src/core/ctcphandler.cpp(170) in query() one can find the following line
params << serverEncode(bufname) << lowLevelQuote(pack(serverEncode(ctcpTag), userEncode(bufname, message)));
here ctcpTag = 'VERSION' and message is whatever section() gives for empty stuff, see http://doc.trolltech.com/3.3/qstring.html#section

so to fix it, one would have to check whether message is empty and if so, don't pack it (i think)

#3 Updated by johu over 14 years ago

  • Status changed from New to Assigned
  • Assignee set to johu
  • Priority changed from Normal to Low
  • Target version set to 0.6.2
  • Version changed from 0.7-pre to 0.6.1

#4 Updated by johu over 14 years ago

  • Status changed from Assigned to Resolved
  • % Done changed from 0 to 100

Also available in: Atom PDF