summaryrefslogtreecommitdiff
path: root/benchmark/http_simple_auto.js
diff options
context:
space:
mode:
Diffstat (limited to 'benchmark/http_simple_auto.js')
-rw-r--r--benchmark/http_simple_auto.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/benchmark/http_simple_auto.js b/benchmark/http_simple_auto.js
index a2271ce1e0..7d209d8a11 100644
--- a/benchmark/http_simple_auto.js
+++ b/benchmark/http_simple_auto.js
@@ -47,7 +47,7 @@ var server = http.createServer(function(req, res) {
n = parseInt(arg, 10);
if (n <= 0) throw new Error('bytes called with n <= 0');
if (storedBuffer[n] === undefined) {
- storedBuffer[n] = new Buffer(n);
+ storedBuffer[n] = Buffer.allocUnsafe(n);
for (i = 0; i < n; i++) {
storedBuffer[n][i] = 'C'.charCodeAt(0);
}