Apache OpenOffice (AOO) Bugzilla – Issue 106355
Mac OS X: crash reporting does not work in soffice spawned after crash
Last modified: 2010-07-26 19:47:44 UTC
When upon a crash on Mac OS X DoRestart in desktop/source/app/app.cxx forks and execs a new instance of the soffice process, this call is made from within the signal handler, with many signals blocked (InitSignal in sal/osl/unx/signal.c does sigfillset(&sa_mask) and does not include SA_NODEFER in sa_flags). The signal mask is inherited by the new process, so signal handling (and thus crash reporting) will not work in the new process. A fix might be to adjust the signal mask at the end of InitSignal in sal/osl/unx/signal.c: + sigset_t unset; + if (sigemptyset(&unset) < 0 || + pthread_sigmask(SIG_SETMASK, &unset, NULL) < 0) + { + OSL_TRACE("sigemptyset or pthread_sigmask failed"); + } + return sal_True;
.
fixed as <http://hg.services.openoffice.org/cws/sb119/rev/12a7f6de6dc5> (virtually identical to the above patch)
Thanks! IMHO this fix deserves to get into OOo321 too.
@hdu: This was probably broken for a very long time (maybe since the beginnings). Not sure it qualifies for OOo 3.2.1, but feel free to lobby.
Yup, crash reporting on OOo Aqua had problems for a long time. Often no automated report got created, sometimes the backtraces from the Apple crash reporter or the Java crash reporter provided some clues. A working OOoAqua specific crash reporting infrastructure would be so much better: it has access to the matching unstripped binaries so it can create good backtraces also in product builds. @release managers: the fix here solves the probable root cause for many crash reporting issues on OOoAqua which severly hampered working on OOoAqua crashes. Please support my bidding for an ASAP target
@hdu: Please note that apart from this issue (breaking crash handling in soffice instance automatically restarted after crash) there is also a second issue on Mac OS X, namely that crash handling becomes unreliable as soon as an in-process JVM is created (i.e., as soon as anything implemented in Java is used within OOo). It is unclear to me whether this fix would susbstantially increase the number of successfully received crash reports for Mac OS X.
Ah, ok. So the problems with JVM-crash reporting have a different root cause. Nevertheless crash reporting failing for the other scenarios has troubled the OOoAqua port for a long time so I'm very happy that these problems will be gone soon. The sooner the better...
@tm: please verify (see the menu item trick in the description of issue 108411 for a reliable mechanism to let OOo crash)
checked and verified in cws sb119 -> OK !
close issue