0

I have a win32 application which was developed in VS C++ 2005. I converted this using VS 2010 C++. Now I have added a new library which I developed in again VS 2010 and linked them. However when I start debugging, I get the following error:

The program '[26432] Test.exe: Native' has exited with code -1073741701 (0xc000007b).

I have a breakpoint in _tWinMain. But the code crashes out even before reaching this point. How do I put/ Where do I put a breakpoint to understand why it is crashing? Any suggestions?

Bridge
  • 29,818
  • 9
  • 60
  • 82
tecMav
  • 305
  • 1
  • 2
  • 11
  • The error is STATUS_INVALID_IMAGE_FORMAT and probably happens during the load of the process, so your issue is probably similar to [this](http://stackoverflow.com/questions/5372565/runtime-error-dll-loading-with-win32-applications-on-x64-system-while-compili) question. – user786653 Dec 02 '12 at 14:41
  • I noticed. But, how or where do I start debugging ? How do I find the offending component? – tecMav Dec 02 '12 at 14:48
  • 3
    As suggested in the answer to the question I linked, using e.g. [Dependency Walker](http://www.dependencywalker.com/). Open the file in it and check if it reports any errors. – user786653 Dec 02 '12 at 14:57
  • Most likely your program is trying to load a DLL with a different "bitness" (32 vs 64). Dependency Walker will show you immediately which one(s) it is. – Carey Gregory Dec 02 '12 at 17:07
  • Thank you 'user786653' and Carey Gregory. I have tried this already as suggested by URLs you are referring to. Dependency Walker pointer IESHIMS.dll missing, but that is there in IE folder. So that must not be the issue. Is there a way to break even before _tWinMain? – tecMav Dec 03 '12 at 06:11
  • You can use a low level debugger like OllyDbg. But I'm not sure if it will help you a lot if you try to debug into the startup code. – David J Dec 03 '12 at 08:18

0 Answers0