开发者

c++ Debugging Exception c0000139

I am currently trying to get to the bottom of a client crash with one of our applications. I have wrapped the app in an exception handler which creates a mini-dump when the crash occurs.

The application crashes with the exception c0000139 (of which there isn't a huge amount of documentation).

The callstack looks like this

ntdll.dll!_RtlRaiseStatus@4()  + 0x26 bytes 
ntdll.dll!_LdrpSnapThunk@32()  + 0x26f48 bytes  
ntdll.dll!_LdrpSnapIAT@16()  + 0xd9 bytes   
ntdll.dll!_LdrpHandleOneOldFormatImportDescriptor@16()  + 0x7a bytes    
ntdll.dll!_LdrpHandleOldFormatImportDescriptors@16()  + 0x2e bytes  
ntdll.dll!_LdrpWalkImportDescriptor@8()  + 0x11d bytes  
ntdll.dll!_LdrpLoadDll@24()  - 0x265 bytes  
ntdll.dll!_LdrLoadDll@16()  + 0x110 bytes   
kernel32.dll!_LoadLibraryExW@12()  + 0xc8 bytes 
odbc32.dll!_ODBCLoadLibraryEx@12()  + 0x29 bytes    
odbc开发者_StackOverflow社区32.dll!_LoadDriver@12()  + 0x119f bytes 
odbc32.dll!_SQLDriverConnectW@32()  + 0x1be bytes   
odbc32.dll!_SQLDriverConnect@32()  + 0x125 bytes

It looks like the program is trying to create a database connection (to Oracle via ODBC) and somehow failing to either find the dll or has found a dll with the wrong entry point.

I was wondering if anyone could offer advice an how to track this problem down further, or if anyone has experienced this problem I'd be interested in hearing how you solved it.

Thanks in advance

Rich


That exception code is Entry point not found - something is trying to load a DLL and the DLL cannot find all the DLLs it needs.

Use depends.exe to show what the DLL requires.


Enable loader snaps (gflags -i yourapp.exe +sls) and have it pinpoint the library its failing to find/load (starting the program under the debugger will spew all the loader diagnostics).

Alternatively, get the name of the library from the crash dump by examining parameters of LoadLibraryExW call.


Thanks for all the responses.

Turns out (at least this seems like it was the problem) that we had a configuration problem. Half of the software was set to load the 9i drivers and half of the software was expecting the 10g drivers.

It's early days yet and we need to test this, however it seems very likely that this was the cause.

Cheers Rich

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜