简体   繁体   中英

Windows loader problem - turn on verbose mode

I'm in the process of reorganizing some of the legacy libraries in our application which has unmanaged code calling into libraries of managed code. While I have the code reorganized, it produces the following loader error:


...
'app.exe': Loaded 'C:\WINDOWS\system32\CsDisp.dll'
'app.exe': Loaded 'C:\WINDOWS\system32\psapi.dll'
'app.exe': Loaded 'C:\WINDOWS\system32\shell32.dll'
'app.exe': Loaded 'C:\appCode\Debug\daq206_32.dll', Binary was not built with debug information.
'app.exe': Loaded 'C:\appCode\Debug\SiUSBXp.dll', Binary was not built with debug information.
'app.exe': Loaded 'C:\appCode\Debug\AdlinkDAQ.dll', Symbols loaded.
'app.exe': Loaded 'C:\WINDOWS\system32\P9842.dll', Binary was not built with debug information.
LDR: LdrRelocateImageWithBias() failed 0xc0000018
LDR: OldBase     : 10000000
LDR: NewBase     : 00A80000
LDR: Diff        : 0x7c90d6fa0012f6cc
LDR: NextOffset  : 00000000
LDR: *NextOffset : 0x0
LDR: SizeOfBlock : 0xa80000
Debugger:: An unhandled non-continuable exception was thrown during process load

I believe 0xc0000018 error is an overlapping address range. So, I have two questions. First, what linker options may cause this error? I'm currently linking with /DYNAMICBASE:NO and /FIXED:No as this was how some of the previous libraries were set up.
Second, is there a way to turn on verbose mode for the loader so I can see what exactly it's trying to load? P9842 is a third party library so I imagine it is getting to one of my libraries after P9842 and failing on that one. Can I narrow it down? Thanks.

Don't know about the first question. A search for that status code hit this article with the interesting note that "Before XP there was no check in Windows for page mappings with different memory types. Windows XP does check though. A second memory type mapping attempt will fail with the STATUS_CONFLICTING_ADDRESSES (0xc0000018) error message." Might be relevant if you are using MapViewOfFile...

For the second question, you want to see loader snaps. See this article at msdn . This command should help: "gflags -i yourApp.exe +sls"

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM