Bug 3261

Summary: Deleting a message while it's downloaded causes a segfault
Product: Claws Mail (GTK 2) Reporter: Gumnos <clawsmail>
Component: UI/Message ListAssignee: users
Status: RESOLVED WORKSFORME    
Severity: normal CC: clawsmail
Priority: P3    
Version: 3.8.1   
Hardware: PC   
OS: Linux   

Description Gumnos 2014-08-28 19:04:41 UTC
I've tried several versions but am reporting on what I've got on this machine (Debian Stable's default).  I was able to trigger it recently on FreeBSD10 which should have a fairly recent version (I've since reformatted that box).  The following steps reproduce the issue fairly reliably:

1) I've just received new mail (happens to be an IMAP account< 

2) I select the new-mail in the message-list window

3) WHILE THE MESSAGE IS STILL DOWNLOADING, I hit the Delete key (or "=" which runs my processing rules, and a deleting-rule gets triggered for the still-downloading message) Claws segfaults.


Observations:

- it seems to happen most frequently with larger messages (multiple attachments, etc).  There seems to be some race-condition between where the headers get downloaded and the body gets downloaded for display.

- it doesn't seem to happen nearly as frequently if I use control+D (which I have mapped to delete as well) instead of the Delete key.

- it may also have something to do with writing back the "this message has been read" status when I jump to the message. I've not been able to track down where in the "new mail -> select the message -> download the body -> display the message in the view window -> mark it read" process that the segfault gets triggered other than that it's after I've selected an unread+uncached message.
Comment 1 Gumnos 2014-08-28 19:06:26 UTC
For what it's worth, it's much easier to reproduce on a slow network IMAP/IMAPS connection.
Comment 2 Paul 2014-08-28 19:19:08 UTC
I cannot reproduce this crash using version 3.10.1.
3.8.1 is old, (released over 2 years ago), and much has changed. Re-open this if you can reproduce the crash with the latest release. Thanks.