#848299 icedove crashes with SIGPIPE in libc's send.c

#848299#5
Date:
2016-12-16 00:52:23 UTC
From:
To:
One of icedove's threads randomly(TM) crashes with SIGPIPE in libc's send.c

This can happen shortly after being started or after running for a
couple of hours. No direct trigger identified so far.

Output of gdb:

[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/usr/bin/icedove'.
Program terminated with signal SIGPIPE, Broken pipe.
#0  0x00007ffff7bcd65f in __libc_send (fd=67, buf=0x7fffa9834000, n=31,
flags=0) at ../sysdeps/unix/sysv/linux/x86_64/send.c:26
26      ../sysdeps/unix/sysv/linux/x86_64/send.c: No such file or directory.
[Current thread is 1 (Thread 0x7fffe2ffe700 (LWP 28924))]

backtrace for this particular thread:

(gdb) bt
#0  0x00007ffff7bcd65f in __libc_send (fd=67, buf=0x7fffa9834000, n=31,
flags=0) at ../sysdeps/unix/sysv/linux/x86_64/send.c:26
#1  0x00007ffff5ea4e4b in ?? () from /usr/lib/x86_64-linux-gnu/libnspr4.so
#2  0x00007fffeeca759a in ?? () from /usr/lib/x86_64-linux-gnu/libssl3.so
#3  0x00007fffeec9b999 in ?? () from /usr/lib/x86_64-linux-gnu/libssl3.so
#4  0x00007fffeec9d694 in ?? () from /usr/lib/x86_64-linux-gnu/libssl3.so
#5  0x00007fffeecad9fb in ?? () from /usr/lib/x86_64-linux-gnu/libssl3.so
#6  0x00007ffff3998afe in ?? () from /usr/lib/icedove/libxul.so
#7  0x00007ffff3998b86 in ?? () from /usr/lib/icedove/libxul.so
#8  0x00007ffff22d6fc0 in ?? () from /usr/lib/icedove/libxul.so
#9  0x00007ffff22db356 in ?? () from /usr/lib/icedove/libxul.so
#10 0x00007ffff22d8c50 in ?? () from /usr/lib/icedove/libxul.so
#11 0x00007ffff22d8fdc in ?? () from /usr/lib/icedove/libxul.so
#12 0x00007ffff22e0cb5 in ?? () from /usr/lib/icedove/libxul.so
#13 0x00007ffff225ea53 in ?? () from /usr/lib/icedove/libxul.so
#14 0x00007ffff2278ae9 in ?? () from /usr/lib/icedove/libxul.so
#15 0x00007ffff245be9b in ?? () from /usr/lib/icedove/libxul.so
#16 0x00007ffff244bf62 in ?? () from /usr/lib/icedove/libxul.so
#17 0x00007ffff2260742 in ?? () from /usr/lib/icedove/libxul.so
#18 0x00007ffff5ea8549 in ?? () from /usr/lib/x86_64-linux-gnu/libnspr4.so
#19 0x00007ffff7bc4464 in start_thread (arg=0x7fffe2ffe700) at
pthread_create.c:333
#20 0x00007ffff6e679df in clone () at
../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Core dump exists but I'm not keen of publishing it due to included
sensitive data. I'm happy to help debugging though.

#848299#10
Date:
2016-12-17 08:56:07 UTC
From:
To:
severity 848299 important
usertag 848299 id-crash-45.1.0
thanks

Hello Mirko,
lowering down the severity as Icedove isn't completely broken or renders
the package into a security whole.
https://www.debian.org/Bugs/Developer#severities

On Fri, Dec 16, 2016 at 01:52:23AM +0100, Mirko Vogt wrote:
[...]

Unfortunately this happen since version 45.1.0-1 in unstable/sid and
jessie-security partially. Please look into similar bug reports and
propose a merge within a another bug report if possible.

https://bugs.debian.org/cgi-bin/pkgreport.cgi?tag=id-crash-45.1.0;users=c.schoenert@t-online.de

This looks not very helpful as the debugging symbols are missing.

The Icedove Wiki page contains information for creating good GDB logs,
please have a look. Core dumps are not that helpful at all as we don't
have the time nor the knowledge to analyze them.

https://wiki.debian.org/Icedove

Regards
Carsten

#848299#17
Date:
2017-02-28 21:52:05 UTC
From:
To:
Dear Maintainer,

I'm not 100% sure but I think I have the same issue and I'm able to provide
a verbose stack trace. (or at least a related one)

I have included some interesting but in my oppinion unrelated warning
messages about an incomplete added caldav account.
Just that you see everything that happened from start of icedove until it
crashes.

My Laptop was in hibernation between start of icedove and the crash.

Please tell me if you need more information because I think I will be able
to recreate the crash as it happens very reliably once or twice a day.

GDB Output:

$ /usr/lib/icedove/run-mozilla.sh -g /usr/lib/icedove/icedove-bin 2>&1 |
tee /tmp/icedove-gdb-$(apt-cache show icedove |
 grep Version | awk '{ print $2 }')_$(date +%F_%T).log
MOZILLA_FIVE_HOME=/usr/lib/icedove
  LD_LIBRARY_PATH=/usr/lib/icedove:/usr/lib/icedove/plugins:/usr/lib/icedove
DISPLAY=:0
DYLD_LIBRARY_PATH=/usr/lib/icedove:/usr/lib/icedove
     LIBRARY_PATH=
       SHLIB_PATH=/usr/lib/icedove:/usr/lib/icedove
          LIBPATH=/usr/lib/icedove:/usr/lib/icedove
       ADDON_PATH=
      MOZ_PROGRAM=/usr/lib/icedove/icedove-bin
      MOZ_TOOLKIT=
        moz_debug=1
     moz_debugger=
moz_debugger_args=
/usr/bin/gdb  --args /usr/lib/icedove/icedove-bin
GNU gdb (Debian 7.7.1+dfsg-5) 7.7.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/lib/icedove/icedove-bin...Reading symbols from
/usr/lib/debug//usr/lib/icedove/icedove-bin...done.
done.
(gdb) run
Starting program: /usr/lib/icedove/icedove-bin
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
continue
[New Thread 0x7fffe7eaa700 (LWP 10060)]
[Thread 0x7fffe7eaa700 (LWP 10060) exited]

.... skipping lines ....

[New Thread 0x7fffd5fff700 (LWP 10082)]
[calBackendLoader] Using libical backend at
/usr/lib/icedove/extensions/{e2fda1a4-762b-4020-b5ad-a41df1933103}/components/libical-manifest
[New Thread 0x7fffd4141700 (LWP 10083)]

.... skipping lines ....

[New Thread 0x7fffb9bfe700 (LWP 24770)]
[New ThWarning: There has been an error reading data for calendar: yathos
cloud.  However, this error is believed to be minor, so the program will at
tempt to continue. Error code: DAV_DAV_NOT_CALDAV. Description: The
resource at https://cloud.example.com/remote.php/caldav/ is a DAV
collection but no
t a CalDAV calendar
Warning: There has been an error reading data for calendar: yathos cloud.
However, this error is believed to be minor, so the program will attempt t
o continue. Error code: READ_FAILED. Description:
Error: [calCachedCalendar] replay action failed: null, uri=
https://cloud.example.com/remote.php/caldav/, result=2147500037,
op=[xpconnect wrapped calIO
peration]
Warning: There has been an error reading data for calendar: yathos cloud.
However, this error is believed to be minor, so the program will attempt t
o continue. Error code: DAV_DAV_NOT_CALDAV. Description: The resource at
https://cloud.example.com/remote.php/caldav/ is a DAV collection but not a
Cal
DAV calendar
Warning: There has been an error reading data for calendar: yathos cloud.
However, this error is believed to be minor, so the program will attempt t
o continue. Error code: READ_FAILED. Description:
Error: [calCachedCalendar] replay action failed: null, uri=
https://cloud.example.com/remote.php/caldav/, result=2147500037,
op=[xpconnect wrapped calIO
peration]
read 0x7fff9dfff700 (LWP 24771)]
[New Thread 0x7fff9d7fe700 (LWP 24772)]

.... skipping lines ....

[Thread 0x7fffbf8ff700 (LWP 28573) exited]
[New Thread 0x7fffbf8ff700 (LWP 29515)]
[New Thread 0x7fffbe4ff700 (LWP 29516)]
[New Thread 0x7fffc06ff700 (LWP 29517)]
[New Thread 0x7fffbeeff700 (LWP 29518)]
[New Thread 0x7fffbdcfe700 (LWP 29519)]

Program received signal SIGPIPE, Broken pipe.
[Switching to Thread 0x7fffdfbfe700 (LWP 10065)]
0x00007ffff7bcdf0b in __libc_send (fd=50, buf=buf@entry=0x7fffbc488000,
    n=n@entry=31, flags=-1, flags@entry=0)
    at ../sysdeps/unix/sysv/linux/x86_64/send.c:31
31      ../sysdeps/unix/sysv/linux/x86_64/send.c: Datei oder Verzeichnis
nicht gefunden.
(gdb) continue
Continuing.

Program received signal SIGPIPE, Broken pipe.
0x00007ffff7bcdf0b in __libc_send (fd=60, buf=buf@entry=0x7fffbc4dc000,
    n=n@entry=31, flags=-1, flags@entry=0)
    at ../sysdeps/unix/sysv/linux/x86_64/send.c:31
31      in ../sysdeps/unix/sysv/linux/x86_64/send.c
(gdb) bt
#0  0x00007ffff7bcdf0b in __libc_send (fd=60, buf=buf@entry=0x7fffbc4dc000,
    n=n@entry=31, flags=-1, flags@entry=0)
    at ../sysdeps/unix/sysv/linux/x86_64/send.c:31
#1  0x00007ffff64b3a70 in pt_Send (fd=0x7fffb5a5e730, buf=0x7fffbc4dc000,
    amount=31, flags=0, timeout=4294967295)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/nsprpub/pr/src/pthreads/ptio.c:1914
#2  0x00007ffff5320abe in ssl_DefSend (ss=0x7fffbe55a000,
    buf=0x7fffbc4dc000 "\025\003\003", len=31, flags=0) at ssldef.c:94
#3  0x00007ffff5314254 in ssl3_SendRecord (ss=0x7fffbe55a000, epoch=2,
    type=31, type@entry=content_alert, pIn=0x7fffdfbfdac0 "", nIn=0,
flags=0)
    at ssl3con.c:2973
#4  0x00007ffff5314641 in SSL3_SendAlert (ss=ss@entry=0x7fffbe55a000,
    level=level@entry=alert_warning, desc=desc@entry=close_notify)
    at ssl3con.c:3266
#5  0x00007ffff5325459 in ssl_SecureClose (ss=0x7fffbe55a000)
    at sslsecur.c:1157
#6  0x00007ffff20810b8 in nsNSSSocketInfo::CloseSocketAndDestroy (
    this=0x7fffaf595f80)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/security/manager/ssl/nsNSSIOLayer.cpp:945
#7  0x00007ffff2081147 in nsSSLIOLayerClose (fd=0x7fffb5a5e4c0)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/security/manager/ssl/nsNSSIOLayer.cpp:924
#8  0x00007ffff0982272 in nsSocketTransport::ReleaseFD_Locked (
    this=0x7fffc74d3400, fd=<optimized out>)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/netwerk/base/nsSocketTransport2.cpp:1736
#9  0x00007ffff09865dc in nsSocketTransport::OnSocketDetached (
    this=0x7fffc74d3400, fd=<optimized out>)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/netwerk/base/nsSocketTransport2.cpp:2031
#10 0x00007ffff0983ef2 in nsSocketTransportService::DetachSocket (
    this=this@entry=0x7ffff6b9ae50, listHead=0x7fffe708f000,
    sock=0x7fffe708f060)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/netwerk/base/nsSocketTransportService2.cpp:237
#11 0x00007ffff09841ff in nsSocketTransportService::DoPollIteration (
    this=this@entry=0x7ffff6b9ae50, wait=<optimized out>,
    pollDuration=pollDuration@entry=0x7fffdfbfdcd8)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/netwerk/base/nsSocketTransportService2.cpp:1030
#12 0x00007ffff098bcda in nsSocketTransportService::Run
(this=0x7ffff6b9ae50)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/netwerk/base/nsSocketTransportService2.cpp:865
#13 0x00007ffff090a0d2 in nsThread::ProcessNextEvent (this=0x7ffff6b6d980,
    aMayWait=<optimized out>, aResult=0x7fffdfbfddd7)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/xpcom/threads/nsThread.cpp:972
#14 0x00007ffff0924803 in NS_ProcessNextEvent (aThread=<optimized out>,
    aMayWait=aMayWait@entry=true)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/xpcom/glue/nsThreadUtils.cpp:297
#15 0x00007ffff0b05176 in mozilla::ipc::MessagePumpForNonMainThreads::Run (
    this=0x7fffe0452740, aDelegate=0x7fffe701f760)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/ipc/glue/MessagePump.cpp:355
#16 0x00007ffff0af538f in RunHandler (this=0x7fffe701f760)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/ipc/chromium/src/base/message_loop.cc:227
#17 MessageLoop::Run (this=this@entry=0x7fffe701f760)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/ipc/chromium/src/base/message_loop.cc:201
#18 0x00007ffff090c804 in nsThread::ThreadFunc (aArg=0x7ffff6b6d980)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/xpcom/threads/nsThread.cpp:376
#19 0x00007ffff64b7178 in _pt_root (arg=0x7ffff6b5bc80)
    at
/build/icedove-lSa96L/icedove-45.6.0/mozilla/nsprpub/pr/src/pthreads/ptthread.c:216
#20 0x00007ffff7bc7064 in start_thread (arg=0x7fffdfbfe700)
    at pthread_create.c:309
#21 0x00007ffff6ed662d in clone ()
    at ../sysdeps/unix/sysv/linux/x86_64/clone.S:111

#848299#22
Date:
2018-11-12 14:22:02 UTC
From:
To:
It seems 100% reproducable when run in debugger `gdb /usr/lib/thunderbird/thunderbird-bin`, crashed right after start up.. compared to that, when started normal (`thunderbird`) takes about half a day to crash.
Same backtrace as bevor,


Having had these crashes for quite some time now.. would appreciate a bug fix 😁

#848299#27
Date:
2018-11-12 14:28:46 UTC
From:
To:
[comment 24: https://bugzilla.mozilla.org/show_bug.cgi?id=1377779#c24 ]
#848299#37
Date:
2018-11-12 15:25:32 UTC
From:
To:
Hello Marcel,

Am 12.11.18 um 16:14 schrieb Marcel Partap:

you know that Thunderbird 1:52.9.1-1 is an old version?
The current version is 1:60.3.0-1 in unstable/testing and also in
stable-security.

We will do quite nothing on this old version.

#848299#42
Date:
2018-11-12 15:53:09 UTC
From:
To:
Yes I do know, i wasn't yet courageous enough to update to TB 60 with all my addons.. I recognize now that my approach doesn't help, as even stable now has migrated to TB60. Sorry! for that, I'll check with the new version in the next days and report back. 😅