Comparing version 0.0.0 to 0.0.1
@@ -7,6 +7,6 @@ /* vim: set expandtab tabstop=2 shiftwidth=2 foldmethod=marker: */ | ||
var route = function (buffer, proxy) { | ||
var route = function (buffer, socket, proxy) { | ||
var $ = null; | ||
for (var i = 0; i < proxy.parser.length; i++) { | ||
$ = (proxy.parser[i])(buffer); | ||
$ = (proxy.parser[i])(buffer, socket); | ||
if ($) { | ||
@@ -44,3 +44,3 @@ return $; | ||
var H = Buffer.concat(_header); | ||
var R = route(H, _that); | ||
var R = route(H, client, _that); | ||
if (R) { | ||
@@ -47,0 +47,0 @@ client.pause(); |
@@ -5,3 +5,3 @@ { | ||
"keywords": [ "tcp proxy" ], | ||
"version": "0.0.0", | ||
"version": "0.0.1", | ||
"author": "Aleafs Zhang (zhangxc83@gmail.com)", | ||
@@ -8,0 +8,0 @@ "repository": { |
@@ -6,3 +6,3 @@ [![Build Status](https://secure.travis-ci.org/aleafs/sproxy.png?branch=master)](http://travis-ci.org/aleafs/sproxy) | ||
`sproxy` | ||
`tcproxy` | ||
@@ -9,0 +9,0 @@ ## License |
7531