This is the mail archive of the
mailing list for the Cygwin project.
Re: dlopen() bug (new testcase)
- From: Bernhard Loos <bernloos at web dot de>
- To: cygwin at cygwin dot com
- Date: Wed, 22 Mar 2006 23:07:35 +0100
- Subject: Re: dlopen() bug (new testcase)
> -----Ursprüngliche Nachricht-----
> Von: skaller <skaller<at>users<dot>sourceforge<dot>net>
> On Wed, 2006-03-22 at 03:35 +0100, Bernhard Loos wrote:
> > If the C++library declares its calls as 'extern "C"' (as it is done in the example),
> > AFAIK there shouldn't be any problem.
> Doesn't matter what you think you know -- it's not a permitted thing
> to do, you never know what implementors are going to change.
Cygwin itself is a C++-library and it works well with C-programs. There is also a C-binding for QT.
> Ouch. Hmm. But the code isn't doing anything!
> This does look weird -- my system is doing what you're doing
> all the time. It was crashing badly for ages until someone pointed
> out there was a bug in libstdc++ handling string crossing
> DLL boundaries. Since I fixed that the code works fine.
> Perhaps you can try to build it, get Release Candidate 6
Where do you see any string in the testcase?
In fact it does something: it creates the static classes cin and cout and a few others.
I were able to extract the code causing the crash.
If the constructor of lala calls key_init_once(), it crashs just like the example with <iostream>
Otherwise it hangs.
It would be really nice, if somebody with some more knowlegde could take a look at this,
because I'm unable to debug the program. I get only some strange errormessages and no
This is a new CrashTest.cc, the other files remains the same:
static pthread_once_t once = PTHREAD_ONCE_INIT;
extern "C" __declspec(dllexport)
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html