I understand that you enclose as much calls as you can inside mutt_allow_interrupts(1); ... mutt_allow_interrupts(0); How does that translate later on , how does it help ncurses or any other code that's supposed to run run ? Your code doesn't have any specific code written to exit that loop , it just has code allowing some key to be pressed. I suspect there is already code written that will run when you press a key during the fetch ?
On 7/10/09, Kyle Wheeler <[email protected]> wrote: > On Friday, July 10 at 05:24 AM, quoth b a: >> When pressing <enter> to view an email with a big attachement mutt >> becomes unresponsive until the message is fetched. > > I've had the same complaint. > >> I don't like this and I will fix it in the next few days by binding >> the escape key to break the loop on lines 463 - 516 inside message.c >> in imap_fetch_message. That loop is getting the message,and if it's >> 22MB for example you'll have to wait for some time , what if you >> decide you DON'T want to download it any more and you want to >> interrupt the fetching process? > > Indeed! Although it would be far more useful if mutt could download > *partial* messages... but it's not really set up for offloading MIME > decomposition to the IMAP server. > >> I forgot to mention that what I want to get done is listed under the >> file imap/TODO >> >> 9 * Interruptible socket calls, preferably without having to abort the >> 10 connection. For example large downloads could be chunked. > > What I do is simply allow interrupts during socket reads. It's clunky, > because it aborts the connection, but it gets the job done (see > attachment). > > ~Kyle > -- > What progress we are making. In the Middle Ages they would have burned > me. Now they are content with burning my books. > -- Sigmund Freud >
