From 11aaf1b325be353f7ac9e5ebbf4d9c6ed2cf722e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C5=99emysl=20Janouch?= Date: Thu, 24 Sep 2015 02:03:10 +0200 Subject: [PATCH] degesch: fix logging of outgoing status messages "/msg @#test test" would log "MSG(): test" --- degesch.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/degesch.c b/degesch.c index 1c8427c..0500fa2 100644 --- a/degesch.c +++ b/degesch.c @@ -2523,6 +2523,16 @@ formatter_parse_mirc (struct formatter *self, const char *s) static void formatter_parse_nick (struct formatter *self, char *s) { + // For outgoing messages; maybe we should add a special #t for them + // which would also make us not cut off the userhost part, ever + if (irc_is_channel (self->s, irc_skip_statusmsg (self->s, s))) + { + char *tmp = irc_to_utf8 (self->ctx, s); + FORMATTER_ADD_TEXT (self, tmp); + free (tmp); + return; + } + char *nick = irc_cut_nickname (s); int color = siphash_wrapper (nick, strlen (nick)) % 7;