summaryrefslogtreecommitdiff
path: root/lib/_stream_passthrough.js
diff options
context:
space:
mode:
authorisaacs <i@izs.me>2013-03-03 19:14:06 -0800
committerisaacs <i@izs.me>2013-03-05 14:27:15 -0800
commit426b4c625802c7b6913fa09237aa9745bf3ae84a (patch)
tree81756bcb6720145decb01160df08b5315784657b /lib/_stream_passthrough.js
parentcd68d86c3283af2f4b3c349c2081c609e3978b9b (diff)
downloadandroid-node-v8-426b4c625802c7b6913fa09237aa9745bf3ae84a.tar.gz
android-node-v8-426b4c625802c7b6913fa09237aa9745bf3ae84a.tar.bz2
android-node-v8-426b4c625802c7b6913fa09237aa9745bf3ae84a.zip
stream: _write takes an encoding argument
This vastly reduces the overhead of decodeStrings:false streams, such as net and http.
Diffstat (limited to 'lib/_stream_passthrough.js')
-rw-r--r--lib/_stream_passthrough.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/_stream_passthrough.js b/lib/_stream_passthrough.js
index 557d6de99a..a5e986430d 100644
--- a/lib/_stream_passthrough.js
+++ b/lib/_stream_passthrough.js
@@ -36,6 +36,6 @@ function PassThrough(options) {
Transform.call(this, options);
}
-PassThrough.prototype._transform = function(chunk, cb) {
+PassThrough.prototype._transform = function(chunk, encoding, cb) {
cb(null, chunk);
};