Bug #1642 Embedded mysql crashes when called from dll
Submitted: 24 Oct 2003 2:14 Modified: 16 Nov 2003 17:22
Reporter: Miroslav Rajcic Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Server: Embedded Library ( libmysqld ) Severity:S2 (Serious)
Version:4.0.15 OS:Windows (Windows 2000, Windows XP)
Assigned to: Dean Ellis CPU Architecture:Any

[24 Oct 2003 2:14] Miroslav Rajcic
Description:
Having the most basic code to start embedded mysql server, same code works if it is being compiled as exe, and crashes if compiled in a DLL (called from DLL exported function).

For non-embedded server everything works OK either way.

How to repeat:
1. put some basic code for embedded server start in a exported DLL function
2. create exe that loads the DLL and calls this function
3. app crashes at embedded server initialisation

Suggested fix:
Perhaps some compilation flag? (since the same code works in exe)
[3 Nov 2003 19:06] Dean Ellis
I am unable to duplicate this using MySQL 4.0.16.  If testing against 4.0.16 does not resolve the issue, please submit a complete test case.

Thank you
[4 Nov 2003 23:56] Miroslav Rajcic
I've tested again using v4.0.16 and the bug is still there.

See my sample at:
http://atol.sourceforge.net/test_bin.zip  (3.5 MB)
http://atol.sourceforge.net/test_src.zip  (10 kB)
[16 Nov 2003 17:22] MySQL Verification Team
I tested your test code against the latest bk 4.0 tree and
not crash happens. i added some lines of code for to print
before the return line.

E:\bug\test\test_fail\DbTestExe>DbTestExe
I am printing this before the return 0; code line
that means no crash :)