changeset 21585:1d7bb1681e7b

imap: Add imap_client.logged_out at LOGOUT This is useful for determining if client did a clean logout
author Timo Sirainen <timo.sirainen@dovecot.fi>
date Thu, 16 Feb 2017 20:17:32 +0200
parents 69316c5e2424
children 85d1fdc8fc56
files src/imap/cmd-logout.c src/imap/imap-client.h
diffstat 2 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/imap/cmd-logout.c	Thu Feb 16 20:14:55 2017 +0200
+++ b/src/imap/cmd-logout.c	Thu Feb 16 20:17:32 2017 +0200
@@ -8,6 +8,7 @@
 {
 	struct client *client = cmd->client;
 
+	client->logged_out = TRUE;
 	client_send_line(client, "* BYE Logging out");
 
 	if (client->mailbox != NULL) {
--- a/src/imap/imap-client.h	Thu Feb 16 20:14:55 2017 +0200
+++ b/src/imap/imap-client.h	Thu Feb 16 20:17:32 2017 +0200
@@ -191,6 +191,7 @@
 	/* syncing marks this TRUE when it sees \Deleted flags. this is by
 	   EXPUNGE for Outlook-workaround. */
 	unsigned int sync_seen_deletes:1;
+	unsigned int logged_out:1;
 	unsigned int disconnected:1;
 	unsigned int destroyed:1;
 	unsigned int handling_input:1;