From 88f3737a7f70cfeac067fd9682a22bbd86872fff Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Sun, 22 Nov 2009 15:06:30 +0000 Subject: mod_proxy65: Update for new net.server API, untested --- plugins/mod_proxy65.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'plugins') diff --git a/plugins/mod_proxy65.lua b/plugins/mod_proxy65.lua index 86e958d3..f1314a00 100644 --- a/plugins/mod_proxy65.lua +++ b/plugins/mod_proxy65.lua @@ -48,7 +48,7 @@ function connlistener.listener(conn, data) module:log("debug", "new session found ... ") session.setup = true; sessions[conn] = session; - conn.write(string.char(5, 0)); + conn:write(string.char(5, 0)); end return; end @@ -56,7 +56,7 @@ function connlistener.listener(conn, data) if session.sha ~= nil and transfers[session.sha] ~= nil then local sha = session.sha; if transfers[sha].activated == true and transfers[sha].initiator == conn and transfers[sha].target ~= nil then - transfers[sha].target.write(data); + transfers[sha].target:write(data); return; end end @@ -81,7 +81,7 @@ function connlistener.listener(conn, data) session.sha = sha; module:log("debug", "initiator connected ... "); end - conn.write(string.char(5, 0, 0, 3, sha:len()) .. sha .. string.char(0, 0)); -- VER, REP, RSV, ATYP, BND.ADDR (sha), BND.PORT (2 Byte) + conn:write(string.char(5, 0, 0, 3, sha:len()) .. sha .. string.char(0, 0)); -- VER, REP, RSV, ATYP, BND.ADDR (sha), BND.PORT (2 Byte) else log:module("warn", "Neither data transfer nor initial connect of a participator of a transfer.") conn.close(); -- cgit v1.2.3