summaryrefslogtreecommitdiff
path: root/lib/net.js
diff options
context:
space:
mode:
authorFedor Indutny <fedor.indutny@gmail.com>2013-04-08 00:50:40 +0400
committerFedor Indutny <fedor.indutny@gmail.com>2013-04-08 01:17:40 +0400
commiteb39c9854a29f20c9b77eb9379efccd6d245abbb (patch)
treec90584a43410a7e16ac2c807fd90869f36eb124c /lib/net.js
parent77715edee854ff9f2107a612de28e3fa5e20f8b4 (diff)
downloadandroid-node-v8-eb39c9854a29f20c9b77eb9379efccd6d245abbb.tar.gz
android-node-v8-eb39c9854a29f20c9b77eb9379efccd6d245abbb.tar.bz2
android-node-v8-eb39c9854a29f20c9b77eb9379efccd6d245abbb.zip
net: fix buffer iteration in bytesWritten
Diffstat (limited to 'lib/net.js')
-rw-r--r--lib/net.js3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/net.js b/lib/net.js
index 6174b40eac..4b2622be0d 100644
--- a/lib/net.js
+++ b/lib/net.js
@@ -667,8 +667,7 @@ Socket.prototype.__defineGetter__('bytesWritten', function() {
encoding = this._pendingEncoding;
state.buffer.forEach(function(el) {
- el = el[0];
- bytes += Buffer.byteLength(el[0], el[1]);
+ bytes += Buffer.byteLength(el.chunk);
});
if (data)