1
0
mirror of https://github.com/irssi/irssi.git synced 2024-10-27 05:20:20 -04:00

save temporary ignores to config file with timestamp when to unignore.

git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2809 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2002-05-18 04:16:51 +00:00 committed by cras
parent 3eaeeac4f2
commit b96222b311

View File

@ -264,7 +264,7 @@ static void ignore_set_config(IGNORE_REC *rec)
CONFIG_NODE *node;
char *levelstr;
if (rec->level == 0 || rec->unignore_time > 0)
if (rec->level == 0)
return;
node = iconfig_node_traverse("(ignores", TRUE);
@ -281,6 +281,8 @@ static void ignore_set_config(IGNORE_REC *rec)
if (rec->regexp) iconfig_node_set_bool(node, "regexp", TRUE);
if (rec->fullword) iconfig_node_set_bool(node, "fullword", TRUE);
if (rec->replies) iconfig_node_set_bool(node, "replies", TRUE);
if (rec->unignore_time != 0)
iconfig_node_set_int(node, "unignore_time", rec->unignore_time);
if (rec->channels != NULL && *rec->channels != NULL) {
node = config_node_section(node, "channels", NODE_TYPE_LIST);
@ -424,6 +426,7 @@ static void read_ignores(void)
rec->regexp = config_node_get_bool(node, "regexp", FALSE);
rec->fullword = config_node_get_bool(node, "fullword", FALSE);
rec->replies = config_node_get_bool(node, "replies", FALSE);
rec->unignore_time = config_node_get_int(node, "unignore_time", 0);
node = config_node_section(node, "channels", -1);
if (node != NULL) rec->channels = config_node_get_list(node);