-
Notifications
You must be signed in to change notification settings - Fork 341
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
Fix use of deprecated check_no_isolation
in posix fs shims
#1838
Conversation
Could you also add a test that exercises these functions? Something like |
Sorry for the late reply. I got busy. I addressed your comments in a new commit I just pushed. I can wait for your PR to merge and then rebase and resolve conflicts. |
98f8815
to
a9872e5
Compare
Just noticed that your PR is merged. I rebased my branch and resolved conflicts, wasn't too bad 🙂 |
Update posix fs shims to use new API `reject_in_isolation`, which allows rejection with error code instead of always forcing abort. Error code chosen for each op is the most appropriate one from the list in corresponding syscall's manual. Updated helper APIs to not use quotes (`) around input name while preparing the message. This allows callers to pass multi-word string like -- "`read` from stdin".
Change the code to either `EACCES` (if the op is performed on the path), or `EBADF` (if the op is performed the fd) Updated ops: `stat`, `opendir`, `ftruncate64`, and `readlink` Add a new test for fs ops in isolation.
958b513
to
3a4ad13
Compare
This allows catching extremely incorrect arguments before rejecting due to isolation.
Awesome, thanks a lot. :) |
📌 Commit 20d0f2e has been approved by |
☀️ Test successful - checks-actions |
Update posix fs shims to use new API
reject_in_isolation
, whichallows rejection with error code instead of always forcing abort.
Error code chosen for each op is the most appropriate one from the
list in corresponding syscall's manual.
Updated helper APIs to not use quotes (`) around input name while
preparing the message. This allows callers to pass multi-word string
like -- "`read` from stdin".
Cc #1034