I am experiencing a difficult problem on HP-UX 10.10 that I am hoping
someone might have seen before.
I have compiled a shared library (using HP's C++) that, amongst other
things, creates some threads using the libcma library. Soon after
thread creation (although I can't tell if it is this which is causing
the problem), a call to "new" to allocate a char  fails with a bus
According to the de*, libC's new routine calls malloc in libC and
subsequently malloc in libc. It seems that malloc in libc is wrapped by
mutex locks, as the call stack indicates this.
I have a very simple program which uses shl_load() to load the library
and can jump into a library entry point. The bus errors still occur
when loading the shared library from this simple program.
So, has anyone ever seen bus errors from malloc before? Is there
anything special I should be doing when linking shared libraries that
use pthreads (or the programs that load them)? I have _REENTRANT
defined by the compiler at compile time.
Any suggestions would be much appreciated, as this has me totally baffled.