Skip to content

Commit 54c8ea5

Browse files
committed
Fix http_simple server for new API
1 parent 51c1526 commit 54c8ea5

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

benchmark/http_simple.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,25 @@
1-
libDir = process.path.join(process.path.dirname(__filename), "../lib");
1+
path = require("path");
2+
3+
libDir = path.join(path.dirname(__filename), "../lib");
24
require.paths.unshift(libDir);
35

46
process.mixin(require("sys"));
5-
http = require("sys");
7+
http = require("http");
68

79
fixed = ""
810
for (var i = 0; i < 20*1024; i++) {
911
fixed += "C";
1012
}
13+
1114
stored = {};
15+
1216
http.createServer(function (req, res) {
1317
var commands = req.uri.path.split("/");
1418
var command = commands[1];
1519
var body = "";
1620
var arg = commands[2];
1721
var status = 200;
1822

19-
p(req.uri.params);
20-
2123
if (command == "bytes") {
2224
var n = parseInt(arg, 10)
2325
if (n <= 0)

0 commit comments

Comments
 (0)