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

fs: recursion should bail on permission error #31505

Closed
wants to merge 7 commits into from
Closed

Conversation

bcoe
Copy link
Contributor

@bcoe bcoe commented Jan 25, 2020

When creating directories recursively, the logic should bail immediately on UV_EACCES and bubble the error to the user.

Fixes: #31481

CC: @isaacs

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • documentation is changed or added
  • commit message follows commit guidelines

@nodejs-github-bot nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. fs Issues and PRs related to the fs subsystem / file system. labels Jan 25, 2020
When creating directories recursively, the logic should bail
immediately on UV_EACCES and bubble the error to the user.

Fixes: nodejs#31481
@nodejs-github-bot
Copy link
Collaborator

src/node_file.cc Outdated Show resolved Hide resolved
@nodejs-github-bot

This comment has been minimized.

@nodejs-github-bot

This comment has been minimized.

src/node_file.cc Outdated Show resolved Hide resolved
@nodejs-github-bot
Copy link
Collaborator

@bcoe bcoe added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Jan 27, 2020
@Trott
Copy link
Member

Trott commented Jan 27, 2020

Landed in f284290

@Trott Trott closed this Jan 27, 2020
Trott pushed a commit that referenced this pull request Jan 27, 2020
When creating directories recursively, the logic should bail
immediately on UV_EACCES and bubble the error to the user.

PR-URL: #31505
Fixes: #31481
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Rich Trott <rtrott@gmail.com>
codebytere pushed a commit that referenced this pull request Feb 17, 2020
When creating directories recursively, the logic should bail
immediately on UV_EACCES and bubble the error to the user.

PR-URL: #31505
Fixes: #31481
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Rich Trott <rtrott@gmail.com>
@codebytere codebytere mentioned this pull request Feb 17, 2020
codebytere pushed a commit that referenced this pull request Mar 15, 2020
When creating directories recursively, the logic should bail
immediately on UV_EACCES and bubble the error to the user.

PR-URL: #31505
Fixes: #31481
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Rich Trott <rtrott@gmail.com>
codebytere pushed a commit that referenced this pull request Mar 17, 2020
When creating directories recursively, the logic should bail
immediately on UV_EACCES and bubble the error to the user.

PR-URL: #31505
Fixes: #31481
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Rich Trott <rtrott@gmail.com>
@codebytere codebytere mentioned this pull request Mar 17, 2020
codebytere pushed a commit that referenced this pull request Mar 30, 2020
When creating directories recursively, the logic should bail
immediately on UV_EACCES and bubble the error to the user.

PR-URL: #31505
Fixes: #31481
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. c++ Issues and PRs that require attention from people who are familiar with C++. fs Issues and PRs related to the fs subsystem / file system.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Misleading error message when recursive fs.mkdir fails with EACCES
4 participants