1
0
mirror of https://github.com/ShadowKatStudios/OC-Minitel.git synced 2024-11-23 10:38:05 +11:00

added static route support to the OpenOS implementation

This commit is contained in:
Izaya 2018-02-16 22:33:08 +11:00
parent df605f3ca4
commit dd62eab75d
2 changed files with 9 additions and 2 deletions

View File

@ -31,7 +31,8 @@ address {
time last received time last received
} }
]]-- ]]--
local rcache = {} local sroutes = {}
local rcache = setmetatable({},{__index=sroutes})
local rctime = 30 local rctime = 30
--[[ --[[
@ -211,3 +212,9 @@ function set_port(sn)
port = tonumber(sn) or 4096 port = tonumber(sn) or 4096
print("port = "..tostring(port)) print("port = "..tostring(port))
end end
function set_route(to,laddr,raddr)
sroutes[to] = {laddr,raddr,0}
end
function del_route(to)
sroutes[to] = nil
end

View File

@ -1,5 +1,5 @@
# Minitel # Minitel
An easy-to-implement networking protocol for OpenComputers. Not to be confused with the French computer network of the same name. An easy-to-implement networking protocol for OpenComputers. Not to be confused with the [French computer network of the same name](https://en.wikipedia.org/wiki/Minitel).
## Layers ## Layers
Minitel presently implements [layer 3](protocol-3.md) of the OSI model. Minitel presently implements [layer 3](protocol-3.md) of the OSI model.