Description
Description
If a dotnet self-contained app starts up from a path where a component contains a backslash (e.g. /home/cooluser/fancy\folder/app_binary
, where one of the folders in the path is named fancy\folder
, with a backslash in the folder name), the runtime startup will fail, and the cryptic error message Failed to create CoreCLR, HRESULT: 0x80004005
will be displayed.
Reproduction Steps
mkdir test_console_app
cd test_console_app
dotnet new console
dotnet publish --self-contained -p:PublishSingleFile=true test_console_app.csproj --runtime linux-x64 --self-contained true --configuration Release --framework net6.0
mkdir s\\test
cp bin/Release/net6.0/linux-x64/publish/test_console_app s\\test/
s\\test/test_console_app
Expected behavior
The app should run. Failing that, an error message that provides relevant information should be displayed.
Actual behavior
The app crashes with the message
Failed to create CoreCLR, HRESULT: 0x80004005
Regression?
Unknown.
Known Workarounds
Run from only paths without backslashes in folder names.
Configuration
- Reproduced in dotnet 6.0.400
- Any OS supporting backslashes in folder names (reproduced on multiple Linux distros and OSX)
- Any architecture tested
- Most likely specific to self-contained apps
- Before any user code (Blazor/non-Blazor irrelevant)
Other information
If you run the app with COREHOST_TRACE=3
, you still don't get anything terribly useful; it continues exactly as per normal until it prints Failed to create CoreCLR, HRESULT: 0x80004005
to the log and immediately exits.
Metadata
Metadata
Assignees
Type
Projects
Status