Hi Caolán, all,
when looking into
https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/745836 which
has by now collected some 20 duplicates, I have more open questions
than answers.
Some disassembling lead to the real point of failure being
(in 3.3.2/3.4 on amd64):
239 OSL_ASSERT( xThrower.is() );
240 xThrower->throwException( exc );
0x000000000001edd3 <+675>: mov %rbx,%rsi
0x000000000001edd6 <+678>: mov (%rdi),%rax
0x000000000001edd9 <+681>: callq *0x18(%rax)
241 }
With an eip of 0x100000 (in the i386 bug reports) meaning the call goes
into nirvana.
Digging deeper, I found ExceptionThrower::get() on the 3.4 branch to:
a) not using a static variable for s_pThrower thus making the if always
eval to true.
b) not even double-checking s_pThrower after aquireing the guard, making
the whole thing pretty pointless.
c) However, I think even as is, the should not be harmful at least on
gcc, if http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13684 is really
fixed (and the testcode in the issue performs good on my machine).
But what about other compilers?
Caolan has fixed this on master with commit
ure:c51c13ff92adbe1d3f22bee6d907132c48d16602, if it was broken.
Depending on how compilers handle this, it might be worth to cherrypick
to 3-4.
So unless I overlooked something there, the error really is not in the
singleton creation (at least with my gcc), leading to the cause to
possibly be something going wrong in the uno2cpp.mapInterface(..) call
just before. Does that sound plausible? I just want to make sure, before
digging even deeper into the disassembly.
Best,
Bjoern
--
https://launchpad.net/~bjoern-michaelsen
Context
- [Libreoffice] Multiple issues with cppuhelper/source/exc_thrower.cxx · Bjoern Michaelsen
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.