Closed GoogleCodeExporter closed 9 years ago
Original comment by zexspect...@gmail.com
on 23 Jun 2010 at 12:22
I replaced exit() with ExitProcess()
Fixed in v.1.2.5.
Original comment by zexspect...@gmail.com
on 26 Jun 2010 at 12:25
I don't think that solves the problem. TerminateProcess() should be called
instead.
Test file:
#include <windows.h>
int main() {
ExitProcess(1);
}
class tmp {
public:
~tmp() {
GetProcAddress(0, 0);
}
} tmp1;
Callstack showing destructor is called:
> ExitTesting.exe!`dynamic atexit destructor for 'tmp1''() + 0x4 bytes C++
msvcr90.dll!doexit(int code=0x00000000, int quick=0x00000000, int retcaller=0x00000001) Line 591 C
msvcr90.dll!_cexit() Line 427 + 0xb bytes C
msvcr90.dll!__CRTDLL_INIT(void * hDllHandle=0x6fb90000, unsigned long dwReason=0x00000000, void * lpreserved=0x00000001) Line 328 C
msvcr90.dll!_CRTDLL_INIT(void * hDllHandle=0x6fb90000, unsigned long dwReason=0x00000000, void * lpreserved=0x00000001) Line 214 + 0xe bytes C
ntdll.dll!_LdrpCallInitRoutine@16() + 0x14 bytes
ntdll.dll!_LdrShutdownProcess@0() + 0x141 bytes
ntdll.dll!_RtlExitUserProcess@4() + 0x74 bytes
kernel32.dll!75ba7363()
ExitTesting.exe!main() Line 4 + 0x8 bytes C++
ExitTesting.exe!__tmainCRTStartup() Line 586 + 0x17 bytes C
kernel32.dll!@BaseThreadInitThunk@12() + 0x12 bytes
ntdll.dll!___RtlUserThreadStart@8() + 0x27 bytes
ntdll.dll!__RtlUserThreadStart@8() + 0x1b bytes
It is possible that an object may be in a state where it is not safe to
destruct, e.g. between delete this->member; and this->member = 0;
Original comment by kevin.m....@gmail.com
on 1 Jul 2010 at 4:28
Will fix this in the next release.
Original comment by zexspect...@gmail.com
on 2 Jul 2010 at 3:41
Fixed in v.1.2.6
Original comment by zexspect...@gmail.com
on 9 Jul 2010 at 5:05
Original issue reported on code.google.com by
kevin.m....@gmail.com
on 22 Jun 2010 at 4:26