September 26, 2011

Donner Donner
Lab Rat
18 posts

Error: "During startup program exited with code 0xc0000005."

 

Hey,

I reinstalled Windows 7 (64 bit) on my computer and also installed the newest version of QtSDK.
When I imported my project I’m currently working on (from svn), it would compile without any problems.
But when I start the compiled application, it gives me the following error message:
“During startup program exited with code 0xc0000005.”

Now, this happens when I start it from QtCreator as well as when I start the exe using the windows exlorer.

The Project uses two external libraries, which were both built using the same QtSDK.

After searching a little, I found out that this error code often has something to do with DLLs, so I made sure all the needed DLLs are in the application’s directory, which didn’t change anything. I played around with the path-variable, adding the mingw-bin-folder and qt-bin-folder, but the error still shows up. Also when I completely remove all paths that have to do with qt or mingw from the PATH variable, it doesn’t change anything.

Now here comes the weird part:
-When I create a new project, including the two libraries i used and building in one command from both libraries, it works fine. So the libraries (and thus their DLLs) seem to work fine.

-With the original project, I commented out everything from the main()-function, so it doesn’t do anything – still the error occurs.

-I can get rid of the error by commenting out the complete content of the main()-Function AND removig ALL the Source-Files from the Project (except the main.cpp) – then the program starts fine, it just doesn’t do anything obviously. As soon as I add those source files again, althoug everything in main.cpp is still commented out, it crashes again.

-I can’t use the debugger, because no matter where i set the breakpoint, the error shows up before any breakpoint is being reached.

Now, I really don’t know what to do anymore. What could the reason for this error be? What else could I try?

Thanks,
D.

PS: This is the content of my PATH variable (I also tried to remove the last to entries (thought it might have something to do with tortoise svn?), but it didn’t change anything:

  1. C:\Program Files (x86)\AMD APP\bin\x86_64;C:\Program Files (x86)\AMD APP\bin\x86;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files\TortoiseSVN\bin;C:\Programme\QtSDK1_1_3\mingw\bin;

6 replies

September 26, 2011

ludde ludde
Lab Rat
325 posts

Not sure this helps, but if the error code you see is a Windows error code, it means “Access is denied”.
So it could have something to do with file access rights.

September 27, 2011

Donner Donner
Lab Rat
18 posts

Hey,
thanks for your reply!

The problem is, that I don’t know how to detect where exactly the access violation happens as it happens before the application actually starts and any of my code gets executed…

September 27, 2011

Lukas Geyer Lukas Geyer
Lab Rat
2074 posts

Are you absolutely sure that you do not mix different versions of the libraries (for example debug / release)?

October 20, 2011

captainst captainst
Lab Rat
2 posts

Hi there,

Watch the “link” output from compile output and check if you get a warning on “-enable-auto-import”.

If this is the case, then this link might resolve your problem:
http://www.qtcentre.org/threads/44540-qt-4.7.4-linking-error-missing-enable-auto-import

Worked for me. Hope it helps.

June 3, 2013

f.cambria f.cambria
Lab Rat
1 posts

Hi,
in order to solve this issue you have to add this line to .pro file:

QMAKE_LFLAGS= -enable-auto-import -WI

Francesco

June 5, 2013

bjanuario bjanuario
Hobby Entomologist
91 posts

Similar post here: http://qt-project.org/forums/viewthread/1173 [qt-project.org] with resolved issue

Hope this helps
Kind Regards

 
  ‹‹ QWidget: Must constuct a QApplication before a QPaintDevice - OpenGL [Solved]      [SOLVED] Qt 4.7.4 with MSVC2010 include file: ’../../src/corelib/global/qconfig.h’: No such file or directory ››

You must log in to post a reply. Not a member yet? Register here!