1

When I try to load an extension such as sos or psscor4 using the .load commmand in Windbg, it exhibits a behavior I did not expect. So, may be it is just a matter of setting my expectation right as to this behavior being normal.

For example, when I say:

0:00> .load "C:\Windows\Microsoft.NET\Framework64\v4.0.30319\sos.dll"

It complains as follows:

The call to LoadLibrary(C:WindowsMicrosoft.NETFramework64v4.0.30319sos.dll) failed, Win32 error 0n2 "The system cannot find the file specified." Please check your debugger configuration and/or network access.

I infer that it is expecting me to escape the backslash.

However, when I escape the backslash character like so, it works just fine and loads the extension.

0:00> .load "C:\\Windows\Microsoft.NET\\Framework64\\v4.0.30319\\sos.dll"
Water Cooler v2
  • 32,724
  • 54
  • 166
  • 336

2 Answers2

2

Hi use look like this

@"C:\Windows\Microsoft.NET\Framework64\v4.0.30319\sos.dll"

hope it help

  • I know I can do that. The question is not "what should I do?" The question is -- is that the right behavior? Or is there a setting where it recognizes a single backslash? – Water Cooler v2 Apr 07 '17 at 16:24
  • Thank you. Please let me cross-validate that assertion because the source of my confusion and of asking this question is -- I recall vaguely that all the Windbg demos I watched loaded this with a single backslash. Can't remember, though, if they said `@` (fixed literal). – Water Cooler v2 Apr 07 '17 at 16:29
  • Look! This guy runs it without escaping the backslashes. http://stackoverflow.com/q/25929496/303685 – Water Cooler v2 Apr 07 '17 at 21:22
  • Thank you so much for the alternative. – Water Cooler v2 Apr 08 '17 at 07:58
2

It loads fine without quotation marks

0:00> .load C:\Windows\Microsoft.NET\Framework64\v4.0.30319\sos.dll

even if the path contains spaces.

Thomas Weller
  • 55,411
  • 20
  • 125
  • 222