On Thu, 2003-07-10 at 17:16, Andreas Aardal Hanssen wrote:
> >I don't really see where the problem is. Both client and server have to
> >know what messages map to which sequences and they have to be fully
> >synced all the time. If client requests sequences which don't exist, or
> 
> No, they are not fully synced all the time. That's impossible. How can a 
> client always be in sync? How can you prevent a client from searching for 
> messages with msn 1000:1050 when the last thing it knew was that such 
> messages existed?

Client doesn't have to be synced with the actual state of mailbox, it
has to be synced with the state server has told it. If server hasn't
sent EXPUNGEs for messages 1000:1050, then they exist from client's
point of view, and server must allow using them as well. If client has
seen them, client knows the number of messages in mailbox has been
reduced, and must not try to fetch messages outside it.

Remember that EXPUNGEs can be sent only after client initiated command
and before it's OK/NO/BAD response. Client must have parsed replies to
(most) commands it previously sent before trying to send commands with
message sequences. It can't be "slightly out of sync" regarding to
sequence numbers.

> If you FETCH message 1000:1050 and there are no messages there, then that 
> is an error. If you search for messages with msn 1000:1050 and there are 
> none, then the search result is empty.
> 
> There is no _error_ in searching for message number 1000:1050 even if that 
> doesn't match anything. Error <=> BAD.

I think they both mean bugs in client which should be fixed.


Reply via email to