summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/nicklist.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/core/nicklist.c b/src/core/nicklist.c
index 9f67f20b..c38df6d4 100644
--- a/src/core/nicklist.c
+++ b/src/core/nicklist.c
@@ -575,9 +575,13 @@ int nick_match_msg(CHANNEL_REC *channel, const char *msg, const char *nick)
if (fullmatch)
return TRUE; /* matched without fuzzyness */
- /* matched with some fuzzyness .. check if there's an exact match
- for some other nick in the same channel. */
- return nick_nfind(channel, msgstart, (int) (msg-msgstart)) == NULL;
+ if (channel != NULL) {
+ /* matched with some fuzzyness .. check if there's an exact match
+ for some other nick in the same channel. */
+ return nick_nfind(channel, msgstart, (int) (msg-msgstart)) == NULL;
+ } else {
+ return TRUE;
+ }
}
void nicklist_init(void)