View previous topic :: View next topic |
Author |
Message |
dsimcha
Joined: 24 Oct 2008 Posts: 16
|
Posted: Tue Jul 20, 2010 9:08 am Post subject: DLL Loader + Invalid DLLs |
|
|
How do I make gtkD's DLL loader automatically ignore unsuccessful DLL loads? When I run a program I created in gtkD and compiled using (32-bit) DMD2 from a Win64 console and try to load a file dialog, I get:
"The image file C:\Program Files (x86)\Symantec\Symantec Endpoint Protection\SnacNp64.dll is valid, but is for a machine type other than the current machine. Select OK to continue, or CANCEL to fail the DLL load."
When I select cancel everything works fine. When I select ok, I get an access violation, presumably because gtkD tries to load a 64-bit DLL into a 32-bit program.
However, when I run from a Cygwin terminal instead of a native Win64 one, it seems that the Cygwin console catches the error and forces the DLL to be loaded, thus crashing my application.
This error does not seem to happen for other 32-bit GTK-based apps, such as GIMP, on the same machine. |
|
Back to top |
|
|
Mike Wey
Joined: 07 May 2007 Posts: 428
|
Posted: Tue Jul 20, 2010 2:54 pm Post subject: |
|
|
The loaded dll's are defined in src/gtkc/paths.d but SnacNp64.dll isn't one of them, windows might be trying to load the dll as a dependency. But i cant imagine why. |
|
Back to top |
|
|
dsimcha
Joined: 24 Oct 2008 Posts: 16
|
Posted: Tue Jul 20, 2010 3:43 pm Post subject: |
|
|
Mike Wey wrote: | The loaded dll's are defined in src/gtkc/paths.d but SnacNp64.dll isn't one of them, windows might be trying to load the dll as a dependency. But i cant imagine why. |
It has to do with network drives apparently. It only happens when I have a network drive connected. When I don't everything works fine. |
|
Back to top |
|
|
|