hirc

IRC client
Log | Files | Refs

commit 0d5d83beec5a134110e513b218d268dc6d9cf3e0
parent fd5b930e6e1b6b238b54d13b71bcf2edf0801ce6
Author: hhvn <dev@hhvn.uk>
Date:   Wed, 30 Mar 2022 15:41:25 +0100

Free after tokenization

Diffstat:
Msrc/hist.c | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/hist.c b/src/hist.c @@ -78,9 +78,10 @@ hist_create(struct HistInfo *histinfo, struct Nick *from, char *msg, new->from = nick_dup(from); } else if (**new->_params == ':') { np = NULL; - if (histinfo->channel) { + if (histinfo->channel && histinfo->channel->nicks) { prefix_tokenize(*new->_params, &nick, NULL, NULL); np = nick_get(&histinfo->channel->nicks, nick); + free(nick); } if (np)