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

Yet another permission denied #26

Open
elibarzilay opened this issue Sep 29, 2022 · 0 comments
Open

Yet another permission denied #26

elibarzilay opened this issue Sep 29, 2022 · 0 comments

Comments

@elibarzilay
Copy link

Recently wsld started failing on one of my machines with an obscure permission denied message. After fumbling with it for a while, I figured out that this is an issue of not being able to remove /tmp/.X11-unix/X0, and sudo-removing it made things good again.

Two things are relevant here:

  1. I think that this has started recently because I did a new ubuntu setup -- and it now starts wslg as part of the setup, which means that you're left with a root-owned directory.
  2. It would therefore be nice to revise the code a bit and say what exactly caused the error rather than a vague "permission denied" -- it would at least save me a couple of hours trying to run in random directions.

I think that the offending code is

let _ = std::fs::create_dir_all("/tmp/.X11-unix");
let _ = std::fs::remove_file(&name);

which looks like it's ignoring the prospect of not being able to write that, and fails in a generic way rather that just telling you what went wrong.

(This is probably a duplicate of a few other issues, and adding an error would mean not spending time telling people about removing the files :)

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