Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnatoli Papirovski <apapirovski@mac.com>2017-12-12 01:55:17 +0300
committerAnatoli Papirovski <apapirovski@mac.com>2017-12-18 17:58:02 +0300
commitd36e1b4fed57b34d93e70d3408d753e00b8ed754 (patch)
tree03e0a12b194453231ad7391ff16b2c7cf3a489f2 /src/pipe_wrap.cc
parent68c63a9fa362138bed852714862ac37b85c06adb (diff)
net,src: refactor writeQueueSize tracking
Currently, writeQueueSize is never used in C++ and barely used within JS. Instead of constantly updating the value on the JS object, create a getter that will retrieve the most up-to-date value from C++. For the vast majority of cases though, create a new prop on Socket.prototype[kLastWriteQueueSize] using a Symbol. Use this to track the current write size, entirely in JS land. PR-URL: https://github.com/nodejs/node/pull/17650 Reviewed-By: Anna Henningsen <anna@addaleax.net>
Diffstat (limited to 'src/pipe_wrap.cc')
-rw-r--r--src/pipe_wrap.cc1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/pipe_wrap.cc b/src/pipe_wrap.cc
index 76280f0ce77..c6dce756cea 100644
--- a/src/pipe_wrap.cc
+++ b/src/pipe_wrap.cc
@@ -165,7 +165,6 @@ PipeWrap::PipeWrap(Environment* env,
int r = uv_pipe_init(env->event_loop(), &handle_, ipc);
CHECK_EQ(r, 0); // How do we proxy this error up to javascript?
// Suggestion: uv_pipe_init() returns void.
- UpdateWriteQueueSize();
}