-
Notifications
You must be signed in to change notification settings - Fork 30k
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: migrate ASYNC_CALL to AsyncCall #18144
Conversation
@@ -1030,26 +1031,6 @@ static void WriteString(const FunctionCallbackInfo<Value>& args) { | |||
SYNC_CALL(write, nullptr, fd, &uvbuf, 1, pos) | |||
return args.GetReturnValue().Set(SYNC_RESULT); | |||
} | |||
|
|||
FSReqWrap* req_wrap = | |||
FSReqWrap::New(env, req.As<Object>(), "write", buf, UTF8, ownership); |
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.
Just noticed that the ownership is lost below. I've fixed it locally but when writing a test for it it seems that fs.write
does not work on external two-byte strings on master.
There were some infra issues on linux one. Just in case, a new CI: https://ci.nodejs.org/job/node-test-pull-request/12540/ |
Landed in eca73a2, thanks! |
This patch migrates all the `ASYNC_CALL` macro in `node_file.cc` to the template counterpart AsyncCall. Also goes with a different style of wrapping the arguments so it's clearer to see what arguments are passed to which `uv_fs_*` functions. PR-URL: #18144 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com>
This patch migrates all the
ASYNC_CALL
macro in node_file.cc to the template counterpartAsyncCall
. Also goes with a different style of wrapping the arguments so it's clearer to see what arguments are passed to whichuv_fs_*
functions.Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passesAffected core subsystem(s)
fs