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

Passing empty parameter to wsl --exec fails with "The parameter is incorrect" #6072

Closed
segrey opened this issue Oct 11, 2020 · 4 comments
Closed
Labels

Comments

@segrey
Copy link

segrey commented Oct 11, 2020

Environment

Windows build number: Microsoft Windows [Version 10.0.19042.546]
Your Distribution version: Ubuntu-20.04
Whether the issue is on WSL 2 and/or WSL 1: the issue is both on WSL 1 and WSL 2

Steps to reproduce

Run wsl.exe --distribution Ubuntu-20.04 --exec /bin/echo "" in cmd.exe.

image

WSL logs:

Expected behavior

wsl.exe --distribution Ubuntu-20.04 --exec /bin/echo "" should output an empty line, like wsl.exe --distribution Ubuntu-20.04 --exec /bin/bash -c "/bin/echo ''" does.

Actual behavior

The command fails with error The parameter is incorrect..

@therealkenc
Copy link
Collaborator

Please collect WSL logs and post the backlink to the feedback item here.

@segrey
Copy link
Author

segrey commented Oct 14, 2020

Done: https://aka.ms/AA9ypz2

@licanhua licanhua added the bug label Oct 20, 2020
@licanhua
Copy link
Collaborator

This is a bug.
@benhillis When LxssCreateProcess parse arguments, "" is treated as Invalid parameter. maybe we should support empty parameter and convert empty back to "" before we pass it to linux.

Copy link
Contributor

This issue has been automatically closed since it has not had any activity for the past year. If you're still experiencing this issue please re-file this as a new issue or feature request.

Thank you!

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

No branches or pull requests

3 participants