[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#187385: Wine/Mono app crashes with SIGSEGV on dlopen()



Package: libc6
Version:  2.3.1-16

Kernel: 2.4.18-bf2.4
Debian GNU/Linux 3.0 with packages from Debian Sid (unstable)

When I run Wine application which embeds the Mono JIT engine
it crashes at startup. GDB backtrace is:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 16384 (LWP 1286)]
0x40009587 in _dl_catch_error_internal () from /lib/ld-linux.so.2
(gdb) where
#0  0x40009587 in _dl_catch_error_internal () from /lib/ld-linux.so.2
#1  0x4032d27d in dlerror () from /lib/libdl.so.2
#2  0x4032ceb7 in dlopen () from /lib/libdl.so.2
#3  0x40106940 in wine_dlopen (filename=0x805e8f0
    "/usr/local/lib/wine/kernel32.dll.so", flag=2,
    error=0x40742bf0 "?'\003@\230\205\002@??\001@@\035\001@\b",
    errorsize=256) at port.c:517
 #4  0x4010635e in dlopen_dll (name=0x40742d08 "kernel32.dll",
     error=0x40742bf0 "?'\003@\230\205\002@??\001@@\035\001@\b",
     errorsize=256, test_only=0) at loader.c:152
 #5  0x4010684a in wine_dll_load (filename=0x40742d08 "kernel32.dll",
     error=0x40742bf0 "?'\003@\230\205\002@??\001@@\035\001@\b",
     errorsize=256) at loader.c:387

 Crash happens after the first call to the __libc_dl_error_tsd
(libpthread.so.0) on the thread 1 . Before this, code in
_dl_catch_error_internal
calls startup_error_tsd( ld_linux.so.2) on thread 0 and function works
fine. If I check memory content in the debugger just before expected
SIGSEGV, application doesn't crash immediately, but some different error
happens later.

The same problem was reproduced on different computers.

I think that the behaviour is simular to the one described in
NVidia readme and this will help to resolve the problem:

 ftp://download.nvidia.com/XFree86/Linux-x86/1.0-4349/README.txt

 Q: Some OpenGL applications (like Quake3 Arena) crash when I
    start them on Red Hat Linux 9.0.
A: Some versions of the glibc package shipped by Red Hat that support
    TLS do not properly handle using dlopen() to access shared libraries
    which utilize some TLS models.  This problem is exhibited, for example,
    when Quake3 Area dlopen()'s NVIDIA's libGL library.  Please obtain
    at least glibc-2.3.2-11.9 which is available as an update from Red Hat.

 Alexandre Pigolkine




Reply to: