summaryrefslogtreecommitdiff
path: root/benchmark/net/tcp-raw-c2s.js
diff options
context:
space:
mode:
authorTrevor Norris <trev.norris@gmail.com>2013-07-08 16:53:41 -0700
committerTrevor Norris <trev.norris@gmail.com>2013-07-08 16:53:41 -0700
commit22668db73d1accf1e9332b6b780b84a144277888 (patch)
treef049a3fb33db26e76318974935cda46d395b2b7e /benchmark/net/tcp-raw-c2s.js
parentead8e26b5bcafdbb978fcfc36853d4f88a9848b5 (diff)
downloadandroid-node-v8-22668db73d1accf1e9332b6b780b84a144277888.tar.gz
android-node-v8-22668db73d1accf1e9332b6b780b84a144277888.tar.bz2
android-node-v8-22668db73d1accf1e9332b6b780b84a144277888.zip
benchmark: update callbacks only receive data
Since the SlabAllocator was removed the buffer length/offset is no longer sent to the onread callback. The benchmarks have been updated to reflect that.
Diffstat (limited to 'benchmark/net/tcp-raw-c2s.js')
-rw-r--r--benchmark/net/tcp-raw-c2s.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/benchmark/net/tcp-raw-c2s.js b/benchmark/net/tcp-raw-c2s.js
index e5b3662a8b..e3c726e452 100644
--- a/benchmark/net/tcp-raw-c2s.js
+++ b/benchmark/net/tcp-raw-c2s.js
@@ -57,7 +57,7 @@ function server() {
bench.end((bytes * 8) / (1024 * 1024 * 1024));
}, dur * 1000);
- clientHandle.onread = function(buffer, offset, length) {
+ clientHandle.onread = function(buffer) {
// we're not expecting to ever get an EOF from the client.
// just lots of data forever.
if (!buffer)
@@ -65,8 +65,7 @@ function server() {
// don't slice the buffer. the point of this is to isolate, not
// simulate real traffic.
- // var chunk = buffer.slice(offset, offset + length);
- bytes += length;
+ bytes += buffer.length;
};
clientHandle.readStart();