-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Description
Description
SDK 9.0.6 has an issue where a Self Contained deployment to a network share no longer works, the process ends immediately with result code (0x80008083); irrespective of using a mapped drive letter or a \\unc
path. Copying the same files to a local drive and executing there works correctly.
Worked under previous 9.0.5
Reproduction Steps
- Build simple "hello world!" exe file
- Publish it to a folder on a network share.
- Attempt to run it. Observe nothing happens!
Example pubxml:
<?xml version="1.0" encoding="utf-8"?>
<!-- https://go.microsoft.com/fwlink/?LinkID=208121. -->
<Project>
<PropertyGroup>
<Configuration>Release</Configuration>
<Platform>Any CPU</Platform>
<PublishDir>\\server.domain.local\share\Software\dummy</PublishDir>
<PublishProtocol>FileSystem</PublishProtocol>
<_TargetId>Folder</_TargetId>
<TargetFramework>net9.0</TargetFramework>
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
<SelfContained>true</SelfContained>
<PublishSingleFile>false</PublishSingleFile>
<PublishReadyToRun>false</PublishReadyToRun>
<PublishTrimmed>false</PublishTrimmed>
</PropertyGroup>
</Project>
Expected behavior
When running \\server.domain.local\share\Software\dummy\consoleapp1.exe
, expect program executes (e.g., output Hello World!)
Actual behavior
Program ends with no output.
Regression?
Worked in previous SDK 9.0.5.
Known Workarounds
- Previous SDK
- Copying files locally first
Configuration
- .Net SDK 9.0.6
- Self-contained deployment, not single-file
- Windows 11 x64
- Believe it is specific to Windows
Other information
Comparing the code tagged 9.0.6 and 9.0.5, this may be related to the (new) calls to is_path_rooted. The C++ "pal::is_path_rooted" (in the Windows implementation) only checks that the second character is a colon, which doesn't work when the path is a \\unc\share
path!
I suggest updating is_path_rooted to permit paths that start with \\
as well (it seems mapped drive letters are translated into \\unc
representations earlier in the process-startup, verified by using native debugger), but I'm unsure of any wider ramifications of that change.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status