summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimo Sirainen <cras@irssi.org>2000-07-10 23:27:37 +0000
committercras <cras@dbcabf3a-b0e7-0310-adc4-f8d773084564>2000-07-10 23:27:37 +0000
commitf05068ba7c152fe720f663feac2ae97af61f98a2 (patch)
treeea148aa30a394ed6505eb3e7d97e1c8322aaaaad
parentdcc2e89b2e0a99645b4f49360c3b76958730563e (diff)
downloadirssi-f05068ba7c152fe720f663feac2ae97af61f98a2.zip
/IGNORE -replies fixes
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@457 dbcabf3a-b0e7-0310-adc4-f8d773084564
-rw-r--r--src/irc/core/ignore.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/irc/core/ignore.c b/src/irc/core/ignore.c
index d0336bb4..e45574f9 100644
--- a/src/irc/core/ignore.c
+++ b/src/irc/core/ignore.c
@@ -42,6 +42,11 @@ static int ignore_check_replies(IGNORE_REC *rec, IRC_SERVER_REC *server,
CHANNEL_REC *chanrec;
GSList *nicks, *tmp;
+ g_return_val_if_fail(rec != NULL, FALSE);
+ g_return_val_if_fail(server != NULL, FALSE);
+ g_return_val_if_fail(channel != NULL, FALSE);
+ g_return_val_if_fail(text != NULL, FALSE);
+
chanrec = channel_find(server, channel);
if (chanrec == NULL) return FALSE;
@@ -101,7 +106,8 @@ int ignore_check(IRC_SERVER_REC *server, const char *nick, const char *host,
irc_mask_match_address(rec->mask, nick, host);
if (!ok) {
/* nick didn't match, but maybe this is a reply to nick? */
- if (!rec->replies || !ignore_check_replies(rec, server, channel, text))
+ if (!rec->replies || channel == NULL ||
+ !ignore_check_replies(rec, server, channel, text))
continue;
}
}