MBOX-Line: From petite_abeille at mac.com  Sun Nov  6 12:15:34 2011
To: imap-protocol@u.washington.edu
From: Petite Abeille <petite_abeille@mac.com>
Date: Fri Jun  8 12:34:47 2018
Subject: [Imap-protocol] [noob] select & unseen?
Message-ID: <C61A1BDF-03DD-4ED9-BFCA-C6183F07DD3E@mac.com>

Hello,

Given a mailbox containing only \Seen messages, what kind of UNSEEN response is SELECT supposed to return?

Looking at, say, dovecot implementation, it doesn't return any UNSEEN data if all messages are \Seen:

	if (status.first_unseen_seq != 0) {
		client_send_line(client,
			t_strdup_printf("* OK [UNSEEN %u] First unseen.",
					status.first_unseen_seq));
	}

On the other hand, the spec for SELECT seems to mandate returning all the data: "the server MUST send the following untagged data".

What gives?

Thanks in advance.

Cheers,

--


