Re: Todo list continued

On Wed, 17 Nov 1999, Peter Williams wrote:
-- snip --
>o POP3 working
-- snip --

I have a test-rig of a POP3 receiver (which could also be extended for SMTP
sending as well) which does not require threading and won't (necessarily) lock
up the main app window.

I would be happy to finish up and submit it, but I have limited time for
studying the existing code; basically, if I don't lock up the main app window,
I have to coordinate mailbox updates with it.  Can someone tell me briefly how
this works with the current Balsa system?

My POP3 receiver is set up as a finite-state machine using a "dispatch" function
call; state information is stored in a structure.  I read up to a given bufsize
(presently 2048 bytes) per read on the socket, which is much more efficient
than the multiple 1 byte reads in the libmutt code, and then internally parse
out the lines of data and/or protocol responses, sending them one at a time to
the dispatch function.  Because the dispatch function is stored as a pointer in
the state structure, I can easily extend the system to handle SMTP (it would be
just a different dispatch function).  Any partial line remaining is stored in
the state structure to be used on the next pass.

If I need to, I can use temp files to store messages so that they can be
added to the inbox in a single open-write(loop)-close procedure.

I admit I have been looking at the "stable" version; I am
going to look over the current code ASAP.

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]