Home » U++ Library support » U++ MT-multithreading and servers » MT.cpp __thread sMain related CRASH in VB6 project
MT.cpp __thread sMain related CRASH in VB6 project [message #23993] |
Tue, 15 December 2009 16:20 |
|
kohait00
Messages: 939 Registered: July 2009 Location: Germany
|
Experienced Contributor |
|
|
hi there
got a problem when making a multithreaded DLL which exports stuff and Thread().Start() something. attached is a test environment.
i use the TestDll.dll in a VC6 project, and in a VB6 environment.
while it seems to work in the VC6 project (although Thread::Wait() seems not to work there, but in the other project neither), the app of VB6 crashed at the point in Mt.cpp:137
threadr = sMain = true;
where it crashes with a access violation. seems to have problems, but why only in VB6??
if i remove the __thread in line 75, it works fine in VB6 also. (i dont use CoreCtrl grafics stuff, only the Core).
any idea why?? help greatly apreciated
I thought of the binding problems. the VC6 project is linked agains the TestDll.lib (static binding, dynamic loading), whereas the VB6 project Declares the Lib function (VB6 only can dynamic binding and dynamic loading)
kostah
PS:
all to reproduce this is found in the test environment.
copy the uppproect/TestDll to MyApps and compile with MSC9. (i havent tried this behaviour in MINGW)
the TestDll.dll is compiled using todays current svn release.
[Updated on: Tue, 15 December 2009 16:23] Report message to a moderator
|
|
|
Goto Forum:
Current Time: Wed May 08 06:18:26 CEST 2024
Total time taken to generate the page: 0.02864 seconds
|