[telepathy-idle-0.2] telepathy-idle: Channel names can start with a '!'
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sat Oct 31 23:01:10 UTC 2020
Module: telepathy-idle
Branch: telepathy-idle-0.2
Commit: c1ae3d2bdc7801cdf60adb6a5cdb6390a0749014
URL: http://cgit.freedesktop.org/telepathy/telepathy-idle/commit/?id=c1ae3d2bdc7801cdf60adb6a5cdb6390a0749014
Author: Daniel Landau <daniel at landau.fi>
Date: Wed Nov 9 00:09:17 2016 +0200
Channel names can start with a '!'
According to RFC2811 (https://tools.ietf.org/html/rfc2811#section-3.2)
channel names can start with a bang. Without this check the initial bang
gets stripped out and Telepathy tries to ensure as a channel without the
prefix. That obviously fails, leading to the messages from that channel
arriving as "private" messages.
---
src/idle-parser.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/idle-parser.c b/src/idle-parser.c
index 71ca8b1..2d0ec17 100644
--- a/src/idle-parser.c
+++ b/src/idle-parser.c
@@ -518,7 +518,9 @@ static gboolean _parse_atom(IdleParser *parser, GValueArray *arr, char atom, con
gchar *id, *bang = NULL;
gchar modechar = '\0';
- if (idle_muc_channel_is_modechar(token[0])) {
+ /* Channel names can start with a '!', so don't strip that
+ * (https://tools.ietf.org/html/rfc2811#section-3.2) */
+ if (atom != 'r' && idle_muc_channel_is_modechar(token[0])) {
modechar = token[0];
token++;
}
More information about the telepathy-commits
mailing list