summaryrefslogtreecommitdiff
path: root/degesch.c
diff options
context:
space:
mode:
Diffstat (limited to 'degesch.c')
-rw-r--r--degesch.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/degesch.c b/degesch.c
index b24f502..c840245 100644
--- a/degesch.c
+++ b/degesch.c
@@ -5486,7 +5486,7 @@ irc_handle_privmsg_text (struct server *s,
}
char *nickname = irc_cut_nickname (msg->prefix);
- const char *prefixes = irc_get_privmsg_prefix
+ char *prefixes = irc_get_privmsg_prefix
(s, str_map_find (&s->irc_users, nickname), target);
// IRCv3.2 echo-message could otherwise cause us to highlight ourselves
@@ -5505,6 +5505,7 @@ irc_handle_privmsg_text (struct server *s,
"#a<#S#S>#r #m", ATTR_HIGHLIGHT, prefixes, nickname, text->str);
free (nickname);
+ free (prefixes);
}
static void
@@ -6516,12 +6517,13 @@ static void
log_autosplit_privmsg (struct server *s,
struct send_autosplit_args *a, struct buffer *buffer, const char *line)
{
- const char *prefixes = irc_get_privmsg_prefix (s, s->irc_user, a->target);
+ char *prefixes = irc_get_privmsg_prefix (s, s->irc_user, a->target);
if (buffer && soft_assert (s->irc_user))
log_outcoming_privmsg (s, buffer,
prefixes, s->irc_user->nickname, line);
else
log_outcoming_orphan_privmsg (s, a->target, line);
+ free (prefixes);
}
#define SEND_AUTOSPLIT_PRIVMSG(s, target, message) \