From: Vladimir Marek <Vladimir.Marek@Oracle.COM>
To: notmuch@notmuchmail.org
Subject: crash during saving
Date: Tue, 16 Apr 2013 15:56:00 +0200 [thread overview]
Message-ID: <20130416135600.GA7807@pub.cz.oracle.com> (raw)
Hi,
I just indexed my mail archive by notmuch and I'm starting to play with
mutt-kz. The biggest stopper right now is that mutt cores when set
already read mail to new (toggle-new in mutt). Once I try to leave the
virtual folder (be it to another folder or because of quitting mutt) it
crashes.
I haven't had the time yet to investigate deeper, so I'll just post
whatever info I have and hope that it will be something obvious for you
:)
It seems that mutt is calling "notmuch_message_maildir_flags_to_tags"
which in turn tries to remove flag "draft" which probably is not present
and thus raises an exception. Does
"notmuch_message_maildir_flags_to_tags" expect the mail to be in certain
state (have certain flags set) or it should not crash no matter which
flags were and are now set?
Now to be fair I have to say that this is on Solaris with handful of
patches applied to make notmuch compilable there by Oracle Studio
compilers. (I'm working on finalizing the patches to have them suitable
for review, which I want to post soon).
Any tips welcome :)
Thank you
--
Vlad
The stack looks like:
(dbx) where
[1] _lwp_kill(0x1, 0x6, 0xfeffd028, 0xfe5f2168), at 0xfe5f9265
[2] thr_kill(0x1, 0x6, 0xfeffd028, 0xfe5a0fe1), at 0xfe5f218a
[3] raise(0x6, 0x0, 0xfeffd084, 0xfe57873d), at 0xfe5a0fed
[4] abort(0x0), at 0xfe57875d
[5] __Cimpl::default_terminate(0x0), at 0x8705898
[6] std::terminate(0x0, 0x89290a8, 0xfeffd0ac, 0x89290a8, 0x0, 0x89290a8), at 0x87055cb
[7] __Cimpl::ex_terminate(0x884afac, 0x0), at 0x8705736
---- hidden frames, use 'where -h' to see them all ----
=>[10] Xapian::Document::Internal::remove_term(this = 0x8b14cb8, tname = CLASS), line 404 in "omdocument.cc"
[11] Xapian::Document::remove_term(this = 0x98e3684, tname = CLASS), line 156 in "omdocument.cc"
[12] _notmuch_message_remove_term(message = 0x98e3650, prefix_name = 0x884149b "tag", value = 0x88e9f09 "draft"), line 960 in "message.cc"
[13] notmuch_message_remove_tag(message = 0x98e3650, tag = 0x88e9f09 "draft"), line 1019 in "message.cc"
[14] notmuch_message_maildir_flags_to_tags(message = 0x98e3650), line 1126 in "message.cc"
[15] rename_filename(db = 0x98e26c0, old = 0xfeffd48d "/tank/vm/vmarek/mail/archive/064/cur/1366056222.6981_56079.vi64-x3-2e-prg06:2,S", new = 0xfeffd38e "/tank/vm/vmarek/mail/archive/064/cur/1366056222.6981_56079.vi64-x3-2e-prg06:2,", h = 0x8b1b880), line 1192 in "mutt_notmuch.c"
[16] nm_sync(ctx = 0x8ac77f0, index_hint = 0xfeffdb68), line 1277 in "mutt_notmuch.c"
[17] sync_mailbox(ctx = 0x8ac77f0, index_hint = 0xfeffdb68), line 822 in "mx.c"
[18] mx_close_mailbox(ctx = 0x8ac77f0, index_hint = 0xfeffdb68), line 1020 in "mx.c"
[19] mutt_index_menu(), line 954 in "curs_main.c"
[20] main(argc = 1, argv = 0xfeffea38), line 1056 in "main.c"
(dbx) print -r tname
tname = {
basic_string<char,std::char_traits<char>,std::allocator<char> >::_String_base<char,std::allocator<char> >::_M_start = 0x8b2b900 "Kdraft"
basic_string<char,std::char_traits<char>,std::allocator<char> >::_String_base<char,std::allocator<char> >::_M_finish = 0x8b2b906 ""
basic_string<char,std::char_traits<char>,std::allocator<char> >::_String_base<char,std::allocator<char> >::_M_end_of_storage = {
basic_string<char,std::char_traits<char>,std::allocator<char> >::_String_base<char,std::allocator<char> >::_STLP_alloc_proxy<char*,char,std::allocator<char> >::_M_data = 0x8b2b907 "T^O"
}
}
(dbx) list
404 throw Xapian::InvalidArgumentError("Term `" + tname +
405 "' is not present in document, in "
406 "Xapian::Document::Internal::remove_term()");
407 }
408 positions_modified = !i->second.positions.empty();
409 terms.erase(i);
410 }
411
412 void
413 Xapian::Document::Internal::clear_terms()
(dbx) frame 15
Current function is rename_filename
1192 notmuch_message_maildir_flags_to_tags(msg);
(dbx) list
1192 notmuch_message_maildir_flags_to_tags(msg);
1193 update_tags(msg, nm_header_get_tags(h));
1194 }
1195
1196 rc = 0;
1197 done:
1198 if (msg)
1199 notmuch_message_destroy(msg);
1200 notmuch_database_end_atomic(db);
1201 return rc;
(dbx) frame 14
Current function is notmuch_message_maildir_flags_to_tags
1126 status = notmuch_message_remove_tag (message, flag2tag[i].tag);
(dbx) print filename
filename = 0x8b24e10 "/tank/vm/vmarek/mail/archive/064/cur/1366056222.6981_56079.vi64-x3-2e-prg06:2,"
(dbx) print *flags
*flags = '\0'
(dbx) print *filenames
*filenames = {
iterator = (nil)
}
next reply other threads:[~2013-04-16 14:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-16 13:56 Vladimir Marek [this message]
2013-04-16 19:58 ` crash during saving Blake Jones
2013-04-16 20:05 ` Vladimir Marek
2013-04-17 8:53 ` Vladimir Marek
2013-04-17 14:05 ` Blake Jones
2013-04-19 14:27 ` Vladimir Marek
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130416135600.GA7807@pub.cz.oracle.com \
--to=vladimir.marek@oracle.com \
--cc=notmuch@notmuchmail.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).