From d5564a0e01c3e843e79e01f80c6aad5e98a7101a Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Mon, 11 Mar 2002 18:20:42 +0000 Subject: [PATCH] New queries should begin with last_unread_msg timestamp set to now. This fixes /SET autoclose_query >0 + /SET autocreate_own_query ON closing queries created by your /MSG almost immediately. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2588 dbcabf3a-b0e7-0310-adc4-f8d773084564 --- src/core/queries.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/core/queries.c b/src/core/queries.c index 21bb6db4..f4aae6e7 100644 --- a/src/core/queries.c +++ b/src/core/queries.c @@ -37,6 +37,8 @@ void query_init(QUERY_REC *query, int automatic) MODULE_DATA_INIT(query); query->type = module_get_uniq_id_str("WINDOW ITEM TYPE", "QUERY"); query->destroy = (void (*) (WI_ITEM_REC *)) query_destroy; + query->last_unread_msg = time(NULL); + if (query->server_tag != NULL) { query->server = server_find_tag(query->server_tag); if (query->server != NULL) {