From 2cd85360c6c313001eeabee21e46b16c7526f04c Mon Sep 17 00:00:00 2001 From: 20kdc Date: Sat, 25 Mar 2017 10:51:50 +0000 Subject: [PATCH] OC Hierarchial Gateway fix --- oc/hierarchi.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/oc/hierarchi.lua b/oc/hierarchi.lua index 3a6b51d..9d5291f 100644 --- a/oc/hierarchi.lua +++ b/oc/hierarchi.lua @@ -41,7 +41,7 @@ for a, _ in component.list("modem") do end inboundModem.open(4957) -if not outboundModem then +if not outboundModemAdr then local tunnel = component.tunnel -- Implement just enough of an outbound modem to be useful. outboundModem = { @@ -105,7 +105,7 @@ local function handlePacket(incoming, dat) if not data then return end -- corrupt packet if hops == 255 then return end - local tfrom, tto = checkLen(processFrom(nfrom)), checkLen(processTo(nto)) + local tfrom, tto = checkLen(processFrom(incoming, nfrom)), checkLen(processTo(incoming, nto)) if tfrom and tto then local resdata = cdlib.encode(hops + 1, tfrom, tto, data) if incoming then