-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Make open O_CREATE mode 0 work #23137
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
Make open O_CREATE mode 0 work #23137
Conversation
In nodefs we first create the node with permissions 0 and then try to open it. The open fails because we don't have read permissions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
Can we combine the test into and existing test for open
flags?
Well I think the right test would be |
This is an automatic change generated by tools/maint/rebaseline_tests.py. The following (18) test expectation files were updated by running the tests with `--rebaseline`: ``` other/codesize/test_codesize_cxx_ctors1.gzsize: 8351 => 8407 [+56 bytes / +0.67%] other/codesize/test_codesize_cxx_ctors1.jssize: 20343 => 20486 [+143 bytes / +0.70%] other/codesize/test_codesize_cxx_ctors2.gzsize: 8334 => 8390 [+56 bytes / +0.67%] other/codesize/test_codesize_cxx_ctors2.jssize: 20311 => 20454 [+143 bytes / +0.70%] other/codesize/test_codesize_cxx_except.gzsize: 9356 => 9411 [+55 bytes / +0.59%] other/codesize/test_codesize_cxx_except.jssize: 24112 => 24255 [+143 bytes / +0.59%] other/codesize/test_codesize_cxx_except_wasm.gzsize: 8321 => 8373 [+52 bytes / +0.62%] other/codesize/test_codesize_cxx_except_wasm.jssize: 20236 => 20379 [+143 bytes / +0.71%] other/codesize/test_codesize_cxx_except_wasm_exnref.gzsize: 8321 => 8373 [+52 bytes / +0.62%] other/codesize/test_codesize_cxx_except_wasm_exnref.jssize: 20236 => 20379 [+143 bytes / +0.71%] other/codesize/test_codesize_cxx_lto.gzsize: 8347 => 8404 [+57 bytes / +0.68%] other/codesize/test_codesize_cxx_lto.jssize: 20367 => 20510 [+143 bytes / +0.70%] other/codesize/test_codesize_cxx_mangle.gzsize: 9359 => 9416 [+57 bytes / +0.61%] other/codesize/test_codesize_cxx_mangle.jssize: 24112 => 24255 [+143 bytes / +0.59%] other/codesize/test_codesize_cxx_noexcept.gzsize: 8351 => 8407 [+56 bytes / +0.67%] other/codesize/test_codesize_cxx_noexcept.jssize: 20343 => 20486 [+143 bytes / +0.70%] other/codesize/test_codesize_files_js_fs.gzsize: 7654 => 7702 [+48 bytes / +0.63%] other/codesize/test_codesize_files_js_fs.jssize: 18838 => 18980 [+142 bytes / +0.75%] Average change: +0.66% (+0.59% - +0.75%) ```
So that the behavior matches the behavior on linux. This makes the test pass on nodefs and noderawfs. This allows merging the test added in #23137 into test_fcntl_open.c
In nodefs we first create the node with permissions 0 and then try to open it. The open fails because we don't have read permissions.