Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

drstrace fails on Windows UNC paths #2519

Open
gisburn opened this issue Oct 2, 2024 · 2 comments
Open

drstrace fails on Windows UNC paths #2519

gisburn opened this issue Oct 2, 2024 · 2 comments

Comments

@gisburn
Copy link

gisburn commented Oct 2, 2024

Describe the bug
drstrace fails on UNC paths, but works on paths which have a traditional X:\path syntax

To Reproduce
Steps to reproduce the behavior (using Cygwin UNC path //foo/bar/path, but powershell \foo\bar\path gives the same result):

  1. Pick a network filesystem (SMB, MS-NFSv3, ms-nfs41-client, ...) from $ net use # output
  2. CWD into such a filesystem
    cd //derfw1fs10.global.loc/copy/Mainz/wingrendeltest1
  3. Run drstrace
    $ drstrace -- "$(cygpath -w "$PWD/sbin/nfs_mount")"
    <Using system call file C:\Program Files (x86)\Dr. Memory\drmemory\logs\symcache\syscalls_x64.txt>
    ASSERT FAILURE: D:\a\drmemory\drmemory\drstrace\drstrace.c:589: outf != INVALID_FILE (failed to open log file)

Expected behavior
drmemory should run

Actual behavior
drmemory fails with "ASSERT FAILURE: D:\a\drmemory\drmemory\drstrace\drstrace.c:589: outf != INVALID_FILE (failed to open log file)"

Versions

No

  • What operating system version are you running on? ("Windows 10" is not sufficient: give the release number.)

$ cmd /C 'ver'
Microsoft Windows [Version 10.0.19045.4957]

  • Is your application 32-bit or 64-bit?

64bit

@gisburn
Copy link
Author

gisburn commented Oct 2, 2024

Turns out no network share is required, just plan UNC paths.

  1. Example (Cygwin shell):
    cd //localhost/c$/cygwin64/home/roland_mainz/tmp/drstracetest
    $ drstrace -debug -- "$(cygpath -w /home/roland_mainz/work/msnfs41_uidmapping/ms-nfs41-client/destdir/cygdrive/c/cygwin64/sbin/nfs_mount)"
    <Using system call file C:\Program Files (x86)\Dr. Memory\drmemory\logs\symcache\syscalls_x64.txt>
    ASSERT FAILURE: D:\a\drmemory\drmemory\drstrace\drstrace.c:589: outf != INVALID_FILE (failed to open log file)

  2. Example (Powershell):
    cd '\localhost\c$\cygwin64\home\roland_mainz\tmp\drstracetest'
    drstrace -debug -- 'C:\cygwin64\home\roland_mainz\work\msnfs41_uidmapping\ms-nfs41-client\destdir\cygdrive\c\cygwin64\sbin\nfs_mount.exe'
    <Using system call file C:\Program Files (x86)\Dr. Memory\drmemory\logs\symcache\syscalls_x64.txt>
    ASSERT FAILURE: D:\a\drmemory\drmemory\drstrace\drstrace.c:589: outf != INVALID_FILE (failed to open log file)

@gisburn
Copy link
Author

gisburn commented Oct 2, 2024

Correction: Powershell path syntax for local drive C: is '\localhost\c$\cygwin64\home\roland_mainz\tmp\drstracetest' in this case

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant