libstc++ (?) problem on CURRENT?
barbara.xxx1975 at libero.it
Sat Nov 6 09:57:06 UTC 2010
I had a problem running the IcedTea java plugin on CURRENT i386, while it
works on 8_STABLE.
But maybe it's not a problem related to the port.
Just to be clear, I'm not looking for a solution about the port here, I'm just
wondering why the same c++ code is working on 8_STABLE and it's segfaulting on
CURRENT, considering also that AFAIK the gcc version in both the base systems
is the same.
In the part of the code causing the crash, a std::map is read with an iterator
in a for loop, and if a condition is met, an entry is erased.
The following is the bt I'm getting:
#0 0x29e36247 in kill () from /lib/libc.so.7
#1 0x29e361a6 in raise () from /lib/libc.so.7
#2 0x282424f6 in XRE_LockProfileDirectory () from
#3 <signal handler called>
#4 0x29c8f1b2 in std::_Rb_tree_increment () from
/usr/lib/libstdc++.so.6 #5 0x2ef92402 in
IcedTeaPluginUtilities::invalidateInstance () from
I wrote a "patch" for the IcedTea plugin, replacing the for loop with a while
and increasing the iterator before erasing from the map, and it seems working.
Then I wrote a simple program that do something similar to IcedTea, so there
is no need to build the whole java/openjdk6 port to do some testing.
Running it on 8_STABLE it works, on CURRENT it crashes.
You can find more details in this discussion on the freebsd-java ml:
You can find the patch and the sample code in the discussion above, anyway I'm
reporting them here too:
I hope that the crash is not caused by a bad environment, can anyone else test
More information about the freebsd-current