I finally decided to port my hobby project from GD3.01 to GD3.5 and ran into an issue.
If I build using the statically linked LIB everything is fine - but I want to build using the dynamically linked lib (LIB/DLL).
Here's what I'm seeing, with a repro for one of the samples:
* Copy the win32\Simple project
* Open it up in VS2003
* In the project properties, set Linker:General:Additional Library Directories to dll\vs2003-debug
* Copy the GapiDraw.DLL from that folder into the project folder
* Compile and run
The app runs fine until you exit
Unhandled exception at 0x7c901230 in simple.exe: User breakpoint.
The callstack is:
ntdll.dll!7c901230()
ntdll.dll!7c96c943()
ntdll.dll!7c96cd80()
ntdll.dll!7c960af8()
kernel32.dll!7c85e7af()
msvcr71d.dll!_CrtIsValidHeapPointer(const void * pUserData=0x00a34f68) Line 1807 C
msvcr71d.dll!_free_dbg_lk(void * pUserData=0x00a34f68, int nBlockUse=1) Line 1132 + 0x9 C
msvcr71d.dll!_free_dbg(void * pUserData=0x00a34f68, int nBlockUse=1) Line 1070 + 0xd C
msvcr71d.dll!operator delete(void * pUserData=0x00a34f68) Line 54 + 0x10 C++
GapiDraw.dll!10005685()
> simple.exe!CMyApplication::~CMyApplication() Line 72 + 0x38 C++
simple.exe!CMyApplication::`scalar deleting destructor'() + 0x2b C++
simple.exe!WinMain(HINSTANCE__ * hInst=0x00400000, HINSTANCE__ * hPrevInst=0x00000000, char * pCmdLine=0x00141f23, int nCmdShow=1) Line 55 + 0x33 C++
simple.exe!WinMainCRTStartup() Line 251 + 0x30 C
kernel32.dll!7c816d4f()
ntdll.dll!7c915b4f()
kernel32.dll!7c8399f3()
In other words, it's puking in the delete operator of the first CGapiSurface it tries to tear down.
Are there additional steps needed to get the use of the DLL working? Did I miss the docs somewhere?
