Hi, while I have been debugging some kevent() related problems I have stumbled upon this in imap process:
(gdb) bt
#0 0x00000000 in ?? ()
#1 0x0808befd in notify_callback (context=0x80fa040) at
index-mailbox-check.c:65
#2 0x080c1ede in event_callback (context=0x80f3160) at
ioloop-notify-kqueue.c:46
#3 0x080c2aff in io_loop_handler_run (ioloop=0x80ed200) at
ioloop-kqueue.c:184
#4 0x080c1c02 in io_loop_run (ioloop=0x80ed200) at ioloop.c:235
#5 0x080649ab in main (argc=1, argv=0xbfbfea58, envp=0xbfbfea60) at
main.c:238
(gdb) frame 1
#1 0x0808befd in notify_callback (context=0x80fa040) at
index-mailbox-check.c:65
65 ibox->notify_callback(&ibox->box,
ibox->notify_context);
(gdb) l
60 ibox->notify_last_check = ioloop_time;
61 if ((unsigned int)(ioloop_time - ibox->notify_last_sent) >=
62 ibox->min_notify_interval) {
63 ibox->notify_last_sent = ioloop_time;
64 ibox->notify_pending = FALSE;
65 ibox->notify_callback(&ibox->box,
ibox->notify_context);
66 } else {
67 ibox->notify_pending = TRUE;
68 }
69 }
(gdb) inspect ibox
$10 = (struct index_mailbox *) 0x80fa040
(gdb) inspect *ibox
$11 = {box = {name = 0x80fa160 "INBOX", storage = 0x80eba40, v = {
is_readonly = 0x808e4b8
The notify_callback field is NULL and the process SIGSEGVs. I know very little about IMAP protocol and I think this could be just a case of bad handling of invalid input. The IMAP session I had follows:
[...] a1 OK Logged in. a2 SELECT INBOX
- FLAGS (\Answered \Flagged \Deleted \Seen \Draft NonJunk)
- OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft NonJunk \*)] Flags permitted.
- 131 EXISTS
- 1 RECENT
- OK [UNSEEN 99] First unseen.
- OK [UIDVALIDITY 1137196697] UIDs valid
- OK [UIDNEXT 134] Predicted next UID a2 OK [READ-WRITE] Select completed. a3 IDLE
- idling
- 132 EXISTS
- 2 RECENT a4 DONE a3 BAD Expected DONE.
Vaclav Haisman