mirror of
https://github.com/irssi/irssi.git
synced 2024-12-04 14:46:39 -05:00
New /IGNOREs weren't immediately effective for nicks in channel. Some small
fixes for unignoring levels with /IGNORE. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1630 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
316bd7d142
commit
c1ac5765b3
@ -329,6 +329,7 @@ void ignore_add_rec(IGNORE_REC *rec)
|
||||
ignore_set_config(rec);
|
||||
|
||||
signal_emit("ignore created", 1, rec);
|
||||
nickmatch_rebuild(nickmatch);
|
||||
}
|
||||
|
||||
static void ignore_destroy(IGNORE_REC *rec, int send_signal)
|
||||
|
@ -134,6 +134,18 @@ static void cmd_ignore(const char *data)
|
||||
}
|
||||
|
||||
rec->level = combine_level(rec->level, levels);
|
||||
|
||||
if (new_ignore && rec->level == 0) {
|
||||
/* tried to unignore levels from nonexisting ignore */
|
||||
printformat(NULL, NULL, MSGLEVEL_CLIENTNOTICE,
|
||||
TXT_IGNORE_NOT_FOUND, rec->mask);
|
||||
g_free(rec->mask);
|
||||
g_strfreev(rec->channels);
|
||||
g_free(rec);
|
||||
cmd_params_free(free_arg);
|
||||
return;
|
||||
}
|
||||
|
||||
rec->pattern = (patternarg == NULL || *patternarg == '\0') ?
|
||||
NULL : g_strdup(patternarg);
|
||||
rec->exception = g_hash_table_lookup(optlist, "except") != NULL;
|
||||
@ -144,11 +156,6 @@ static void cmd_ignore(const char *data)
|
||||
if (timestr != NULL)
|
||||
rec->unignore_time = time(NULL)+atoi(timestr);
|
||||
|
||||
if (rec->level == 0) {
|
||||
printformat(NULL, NULL, MSGLEVEL_CLIENTNOTICE, TXT_UNIGNORED,
|
||||
rec->mask == NULL ? "*" : rec->mask);
|
||||
}
|
||||
|
||||
if (new_ignore)
|
||||
ignore_add_rec(rec);
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user