capture debug log from a application that contains manage and native code

Costa Jorge 11 Reputation points
2022-06-13T10:48:37.807+00:00

Hi,

im trying to get debug session log from a application while enabling gflags loader snapes. This option allow us for example to track why native dlls fail to be loaded.

There is this https://www.codeproject.com/Articles/13345/DbMon-NET-A-simple-NET-OutputDebugString-capturer which can capture debug log from a manage instance…

I want to extend that and capture also the native log, namely these:
54c4:673c @ 323918531 - LdrpProcessWork - ERROR: Unable to load DLL: “VCRUNTIME140D.dll”, Parent Module: “E:\prod\ts-build\BuildDrop\work\bin_x64\libzmq-v142-mt-gd-4_3_4.dll”, Status: 0xc0000135
54c4:06e8 @ 323918531 - LdrpResolveDllName - ENTER: DLL name: C:\Users\buildmaster\AppData\Local\Microsoft\WindowsApps\VCRUNTIME140_1D.dll
54c4:58a8 @ 323918531 - LdrpProcessWork - ERROR: Unable to load DLL: “MSVCP140D.dll”, Parent Module: “E:\prod\ts-build\BuildDrop\work\bin_x64\libzmq-v142-mt-gd-4_3_4.dll”, Status: 0xc0000135
54c4:7d18 @ 323918531 - LdrpResolveDllName - RETURN: Status: 0xc0000135

54c4:06e8 @ 323918578 - LdrpLoadDllInternal - RETURN: Status: 0xc0000135
54c4:06e8 @ 323918578 - LdrLoadDll - RETURN: Status: 0xc0000135
Exception thrown at 0x00007FFE732A4F99 in TeklaStructures.exe: Microsoft C++ exception: EEFileLoadException at memory location 0x00000074E8CFA8B8.

This is a tool for a CI process to quickly debug dll load exceptions wihtout firing up Visual Studio or WinGdb

Any hints, doc available i can use to achieve this.

Thanks in advance
Jorge Costa

Ive posted here https://developercommunity.visualstudio.com/home?port=1025&fsid=46f364c9-3f55-4e8b-86ee-5ce827839720&entry=problem but unfortenlly no luck getting any help...

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,709 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.