Apache OpenOffice (AOO) Bugzilla – Issue 17725
"pthread_mutex_destroy: mutex is still in use" when initializing templates for first time use
Last modified: 2013-08-07 14:43:45 UTC
I ran into this while reproducing issue 8492. Kai requested I open a new issue for just the valgrind error. 0. Find a Red Hat 8.0 x86 system (others may do, but that's what I used) 1. Install valgrind 1.9.6. 2. Delete the ~/OpenOffice1.1 directory. 3. Do a net install into your ~/OpenOffice1.1 directory 4. Run OpenOffice under Valgrind (see http://kegel.com/openoffice/#valgrind) 5. Create a template. The dialog box "Initializing templates for first time use" should pop up, and the stack traceback of the problem should appear in the valgrind log. Here's the first bit of the log: pthread_mutex_destroy: mutex is still in use at 0x41384C9D: pthread_error (vg_libpthread.c:292) by 0x41385B49: __pthread_mutex_destroy (vg_libpthread.c:1002) by 0x40979D4F: osl_destroyMutex (in /opt/OpenOffice.org1.1beta2/program/libsal.so.3.1.0) by 0x44F991EB: (within /opt/OpenOffice.org1.1beta2/program/libucb1.so) by 0x44F7DD06: (within /opt/OpenOffice.org1.1beta2/program/libucb1.so) by 0x408FF887: cppu::OWeakObject::release() (in /opt/OpenOffice.org1.1beta2/program/libcppuhelpergcc3.so.3.1.0) by 0x44F7DDB9: (within /opt/OpenOffice.org1.1beta2/program/libucb1.so) by 0x4A700FC9: (within /opt/OpenOffice.org1.1beta2/program/libucphier1.so) by 0x4A6F9A82: (within /opt/OpenOffice.org1.1beta2/program/libucphier1.so) by 0x408555B9: ucb::Content_Impl::executeCommand(com::sun::star::ucb::Command const&) (in /opt/OpenOffice.org1.1beta2/program/libucbhelper2gcc3.so) Full log at http://kegel.com/openoffice/crash-8492.txt
Adding keyword "crash" because this is the kind of bug that is likely to cause a crash on some systems. Assigning to Kai as requested adding cc: sewardj. I set target to 1.1.1 though I'd much prefer to see this fixed in 1.1, as I have a feeling the OpenOffice folks do not yet take this kind of error seriously enough to try to fix it in the weeks remaining before 1.1.
Bug: PersistentPropertySet::setPropertyValue() (ucb/source/core/usbstore.cxx) is buggy - there's a missing m_pImpl->m_aMutex.release() and additionally, in case of an unexpected exception, the mutex will also not be released. Solution: Rewrite PersistentPropertySet::setPropertyValue() and PersistentPropertySet::setPropertyValues() (to fix the unexpected exception problem, which also exists in that function) to use osl::ClearableGuard instead of manual osl::Mutex::acquire() and osl::Mutex::release().
Changing prio, because P2 is only for real and not for potential crashes.
duplicate of 14255, see my additional notes there. *** This issue has been marked as a duplicate of 14255 ***
Dan, for your info, fix for 14255 made it into OO 1.1 RC3.
So *that's* how bugs get into "NEW, DUPLICATE" state!
close issue.