Mailwatch 1.3.0 incorrectly shows unread messages - debug info

Dale Whitfield dale.4d at gmail.com
Tue Sep 21 16:00:15 CEST 2021


Hi,

In summary. Usually after 24hrs, or overnight, mailwatch continues to show unread messages when this is not the case.

System info in brief:

Mail format is: MailDir
Debian 11.0
Kernel 5.14.3 - probably not relevant, same behaviour on 5.13 kernels and currently 5.14.6
mailwatch 1.3.0-1 (debian)

With some pointers ot hints or missing info, I'm happy to debug further and rebuild code to try out issues. But the SIGTRAP that's generated is very odd. Someone left debug code in there or deliberate?

Digging deeper.

In 'failed' state:
Right-click on mailwatch icon -> Open Properties
Click on Edit - mailwatch traps (SIGTRAP) and restarts (see debug info below) 
SIGTRAP occurs in g_logv()

In non-failed state, this brings up expected mailbox edit.

Note also that mailwatch stops spawning threads during the failed state period.

1. attach with gdb to mailwatch when in failed state
2. observe - no thread activity
3. send mailwatch SIGHUP
4. mailwatch restarts and runs normally

What follows is a bunch of output from a gdb session:

===============================

root at nuc:~$ps aux | grep mailwatch
dale        1994  0.0  3.5 267743920 574960 ?    Sl   Sep15   0:06 /usr/lib/x86_64-linux-gnu/xfce4/panel/wrapper-2.0 /usr/lib/x86_64-linux-gnu/xfce4/panel/plugins/libmailwatch.so 5 27262987 mailwatch Mail Watcher Check mail from multiple mailboxes

root at nuc:~$gdb -p 1994
Attaching to process 1994
[New LWP 2001]
[New LWP 2004]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
0x00007ff1095393ff in __GI___poll (fds=0x559adabe8de0, nfds=3, timeout=10000) at ../sysdeps/unix/sysv/linux/poll.c:29
29	../sysdeps/unix/sysv/linux/poll.c: No such file or directory.
(gdb) cont
Continuing.
[Detaching after fork from child process 144084]

Thread 1 "panel-5-mailwat" received signal SIGTRAP, Trace/breakpoint trap.
0x00007ff109663ca7 in g_log_structured_array () from /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
(gdb) cont
Continuing.

Thread 1 "panel-5-mailwat" received signal SIGTRAP, Trace/breakpoint trap.
0x00007ff109664332 in g_logv () from /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
(gdb) backtrace
#0  0x00007ff109664332 in g_logv () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#1  0x00007ff10966459f in g_log () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007ff1098a684a in  () at /usr/lib/x86_64-linux-gnu/libgio-2.0.so.0
#3  0x00007ff10976b306 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#4  0x00007ff10976b6d4 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#5  0x00007ff10976d264 in g_object_new_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#6  0x00007ff10976d5c9 in g_object_new () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#7  0x00007ff109db61fc in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#8  0x00007ff109db77a0 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#9  0x00007ff109db1776 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#10 0x00007ff1097660a2 in g_closure_invoke () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#11 0x00007ff109778413 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#12 0x00007ff10977e6cf in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#13 0x00007ff10977ee5f in g_signal_emit_by_name () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#14 0x00007ff109dc2d19 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#15 0x00007ff10976b306 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#16 0x00007ff10976d74c in g_object_setv () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#17 0x00007ff10976e42b in g_object_set_property () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#18 0x00007ff10976b306 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#19 0x00007ff10976d74c in g_object_setv () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#20 0x00007ff10976e42b in g_object_set_property () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#21 0x00007ff10976b306 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#22 0x00007ff10976d74c in g_object_setv () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#23 0x00007ff10976e42b in g_object_set_property () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#24 0x00007ff109db122f in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#25 0x00007ff10976b306 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#26 0x00007ff10976b738 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#27 0x00007ff10976d264 in g_object_new_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#28 0x00007ff10976d5c9 in g_object_new () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#29 0x00007ff107ebf520 in maildir_get_setup_page (mailbox=0x559adaaa0030) at mailwatch-mailbox-maildir.c:340
#30 0x00007ff107ec9939 in config_run_addedit_window
    (title=0x7ff0a02281d0 "Edit Mailbox: 4d", parent=0x559adbc6e400, mailbox_name=0x7ff0a022b550 "4d", mailbox=0x559adaaa0030, new_mailbox_name=0x7fffa776ceb8) at mailwatch.c:608
#31 0x00007ff107ec9fd3 in config_do_edit_window (sel=0x559ada9aa350, parent=0x559adbc6e400) at mailwatch.c:708
#32 0x00007ff107eca897 in config_edit_btn_clicked_cb (w=0x559adac58dc0, mailwatch=0x559adaa5bb00) at mailwatch.c:866
#33 0x00007ff1097662ee in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#34 0x00007ff10977ea48 in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#35 0x00007ff10977ec3f in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#36 0x00007ff109d14310 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#37 0x00007ff1097662ee in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#38 0x00007ff10977ea48 in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#39 0x00007ff10977ec3f in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#40 0x00007ff109d125d0 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#41 0x00007ff109fcfccb in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#42 0x00007ff1097662ee in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#43 0x00007ff10977ea48 in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#44 0x00007ff10977ec3f in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#45 0x00007ff109dde2d4 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#46 0x00007ff109769100 in g_cclosure_marshal_VOID__BOXEDv () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#47 0x00007ff1097662ee in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#48 0x00007ff10977ea48 in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#49 0x00007ff10977ec3f in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#50 0x00007ff109ddb387 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#51 0x00007ff109ddca1b in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#52 0x00007ff109ddfaaf in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#53 0x00007ff109da5fdc in gtk_event_controller_handle_event () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#54 0x00007ff109f71c4d in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#55 0x00007ff109fc99f8 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#56 0x00007ff1097662ee in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#57 0x00007ff10977ddf9 in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#58 0x00007ff10977ec3f in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#59 0x00007ff109f73d04 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#60 0x00007ff109e26e00 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#61 0x00007ff109e28a63 in gtk_main_do_event () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#62 0x00007ff109b11785 in  () at /usr/lib/x86_64-linux-gnu/libgdk-3.so.0
#63 0x00007ff109b452e2 in  () at /usr/lib/x86_64-linux-gnu/libgdk-3.so.0
#64 0x00007ff10965ce6b in g_main_context_dispatch () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#65 0x00007ff10965d118 in  () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#66 0x00007ff10965d40b in g_main_loop_run () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#67 0x00007ff109e27a55 in gtk_main () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#68 0x0000559ada42aaea in main ()
(gdb) cont
Continuing.

=== Now manually send mailwatch SIGHUP ===

Thread 1 "panel-5-mailwat" received signal SIGHUP, Hangup.
0x00007ff1098a684a in ?? () from /usr/lib/x86_64-linux-gnu/libgio-2.0.so.0
(gdb) cont
Continuing.

=== restart gdb with new PID ===

root at nuc:~$gdb -p 144445

Attaching to process 144445
[New LWP 144446]
[New LWP 144447]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
0x00007f4de63163ff in __GI___poll (fds=0x558770f457e0, nfds=3, timeout=9999) at ../sysdeps/unix/sysv/linux/poll.c:29
29	../sysdeps/unix/sysv/linux/poll.c: No such file or directory.
(gdb) cont
Continuing.
[New Thread 0x7f4d2e7b4700 (LWP 144661)]
[New Thread 0x7f4d2dfb3700 (LWP 144662)]
[Thread 0x7f4d2e7b4700 (LWP 144661) exited]
[New Thread 0x7f4d2d7b2700 (LWP 144663)]
[Thread 0x7f4d2dfb3700 (LWP 144662) exited]
[New Thread 0x7f4d2cfb1700 (LWP 144664)]
[Thread 0x7f4d2d7b2700 (LWP 144663) exited]
[New Thread 0x7f4d2c7b0700 (LWP 144665)]
[Thread 0x7f4d2cfb1700 (LWP 144664) exited]
[New Thread 0x7f4d2bfaf700 (LWP 144666)]
[Thread 0x7f4d2c7b0700 (LWP 144665) exited]
[Thread 0x7f4d2bfaf700 (LWP 144666) exited]
[New Thread 0x7f4d2b7ae700 (LWP 144667)]
[Thread 0x7f4d2b7ae700 (LWP 144667) exited]
[New Thread 0x7f4d2afad700 (LWP 144668)]
[New Thread 0x7f4d2a7ac700 (LWP 144669)]
[Thread 0x7f4d2afad700 (LWP 144668) exited]
[New Thread 0x7f4d29fab700 (LWP 144670)]
[Thread 0x7f4d2a7ac700 (LWP 144669) exited]
[New Thread 0x7f4d297aa700 (LWP 144671)]
[Thread 0x7f4d29fab700 (LWP 144670) exited]
[New Thread 0x7f4d28fa9700 (LWP 144672)]
[Thread 0x7f4d297aa700 (LWP 144671) exited]
[New Thread 0x7f4d287a8700 (LWP 144673)]
[Thread 0x7f4d28fa9700 (LWP 144672) exited]
[New Thread 0x7f4d27fa7700 (LWP 144674)]
[Thread 0x7f4d287a8700 (LWP 144673) exited]
[New Thread 0x7f4d277a6700 (LWP 144675)]
[Thread 0x7f4d27fa7700 (LWP 144674) exited]
[New Thread 0x7f4d26fa5700 (LWP 144676)]
[Thread 0x7f4d277a6700 (LWP 144675) exited]
[New Thread 0x7f4d267a4700 (LWP 144677)]
[Thread 0x7f4d26fa5700 (LWP 144676) exited]
[New Thread 0x7f4d25fa3700 (LWP 144678)]
[Thread 0x7f4d267a4700 (LWP 144677) exited]



More information about the Xfce4-dev mailing list