diff options
-rw-r--r-- | kirc.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -510,12 +510,12 @@ static void rawParser(char *string) { printf("%*s<<< \x1b[34;1m%s\x1b[0m", g - 3, "", nickname); } else if (!strncmp(command, "PART", 4)) { printf("%*s<-- \x1b[34;1m%s\x1b[0m", g - 3, "", nickname); - if (strstr(channel, chan_default) == NULL) { + if (channel != NULL && strstr(channel, chan_default) == NULL) { printf(" [\x1b[33m%s\x1b[0m] ", channel); } } else if (!strncmp(command, "JOIN", 4)) { printf("%*s--> \x1b[32;1m%s\x1b[0m", g - 3, "", nickname); - if (strstr(channel, chan_default) == NULL) { + if (channel != NULL && strstr(channel, chan_default) == NULL) { printf(" [\x1b[33m%s\x1b[0m] ", channel); } } else if (!strncmp(command, "NICK", 4)) { |