<<< Date Index >>>     <<< Thread Index >>>

Re: [Mutt] #2935: Occasional segfault when IMAP inbox updates



#2935: Occasional segfault when IMAP inbox updates
---------------------+------------------------------------------------------
  Reporter:  skunk   |       Owner:  brendan       
      Type:  defect  |      Status:  assigned      
  Priority:  major   |   Milestone:  1.6           
 Component:  IMAP    |     Version:  1.5.19        
Resolution:          |    Keywords:  duplicate 2902
---------------------+------------------------------------------------------
Changes (by uspoerlein):

 * cc: uspoerlein@xxxxxxxxx (added)
  * version:  1.5.18 => 1.5.19


Comment:

 FWIW, I encounter this every other day with mutt v1.5.19 and the sidebar
 patch. I'm connecting via IMAP and use the header cache. This never
 happened using Maildir directly.

 It crashed just again, mutt is sitting there idle, while offlineimap is
 syncing state to that IMAP server. So messages were moved/renamed/etc
 without mutt knowing.

 Since the moved mails caused a screen refresh and mutt jumping to another
 mail to display, it panic'ed due to NULL pointers. Please let me know if
 you think this could've been fixed between 1.5.19 and tip, so I'll try a
 fresh checkout.


 {{{
 ---Mutt: =INBOX [Msgs:22 New:2 Flag:3 Post:1 Inc:14
 
48K]---(threads/date)-------------------------------------------------------------------------------(all)---
 Fetching message headers... 0/23 (0%)
 Program received signal SIGSEGV, Segmentation fault.
 [Switching to Thread 0x28701040 (LWP 100191)]
 mx_update_context (ctx=0x28744400, new_messages=2) at mx.c:1617
 1617          h->security = crypt_query (h->content);
 (gdb) bt
 #0  mx_update_context (ctx=0x28744400, new_messages=2) at mx.c:1617
 #1  0x080d14d2 in imap_read_headers (idata=0x287fa480, msgbegin=22,
 msgend=22) at message.c:372
 #2  0x080ca786 in imap_cmd_finish (idata=0x287fa480) at command.c:294
 #3  0x080cc2f8 in imap_check_mailbox (ctx=0x28744400,
 index_hint=0xbfbfdde4, force=0) at imap.c:1420
 #4  0x08062e3a in mutt_index_menu () at curs_main.c:485
 #5  0x0807e186 in main (argc=Error accessing memory address 0x5c: Bad
 address.
 ) at main.c:1022
 (gdb) f 0
 #0  mx_update_context (ctx=0x28744400, new_messages=2) at mx.c:1617
 1617          h->security = crypt_query (h->content);
 (gdb) p *ctx
 $1 = {path = 0x28788060 "imap://XXXX/INBOX", fp = 0x0, atime = 0, mtime =
 0, size = 54511, vsize = 59292, pattern = 0x0, limit_pattern = 0x0,
   hdrs = 0x2890a480, last_tag = 0x0, tree = 0x28788080, id_hash = 0x0,
 subj_hash = 0x0, thread_hash = 0x287067d0, v2r = 0x2890a600, hdrmax = 96,
   msgcount = 24, vcount = 23, tagged = 0, new = 1, unread = 1, deleted =
 0, flagged = 3, msgnotreadyet = -1, magic = 5, rights = "\177\001",
   compressinfo = 0x0, realpath = 0x0, locked = 0, changed = 1, readonly =
 0, dontwrite = 0, append = 0, quiet = 0, collapsed = 0, closing = 0,
 peekonly = 0,
   data = 0x287fa480, mx_close = 0x80cc3d0 <imap_close_mailbox>}
 (gdb) p ctx->hdrs[msgno]
 $5 = (HEADER *) 0x0
 (gdb) p msgno
 $6 = 23

 }}}

-- 
Ticket URL: <http://dev.mutt.org/trac/ticket/2935#comment:19>
Mutt <http://www.mutt.org/>
The Mutt mail user agent