changed names

This commit is contained in:
vadym 2021-09-09 10:30:55 +03:00
parent f4a4274967
commit 052fdd3edf
37 changed files with 240 additions and 240 deletions

View file

@ -9,7 +9,7 @@ import (
"github.com/Arceliar/phony"
"github.com/RiV-chain/RiV-mesh/src/address"
"github.com/RiV-chain/RiV-mesh/src/util"
"github.com/RiV-chain/RiV-mesh/src/yggdrasil"
"github.com/RiV-chain/RiV-mesh/src/mesh"
"golang.org/x/net/icmp"
"golang.org/x/net/ipv6"
)
@ -19,7 +19,7 @@ const tunConnTimeout = 2 * time.Minute
type tunConn struct {
phony.Inbox
tun *TunAdapter
conn *yggdrasil.Conn
conn *mesh.Conn
addr address.Address
snet address.Subnet
stop chan struct{}
@ -181,7 +181,7 @@ func (s *tunConn) _write(bs []byte) (err error) {
err = errors.New("address not allowed")
return
}
msg := yggdrasil.FlowKeyMessage{
msg := mesh.FlowKeyMessage{
FlowKey: util.GetFlowKey(bs),
Message: bs,
}
@ -191,7 +191,7 @@ func (s *tunConn) _write(bs []byte) (err error) {
return
}
s.Act(s.conn, func() {
if e, eok := err.(yggdrasil.ConnError); !eok {
if e, eok := err.(mesh.ConnError); !eok {
if e.Closed() {
s.tun.log.Debugln(s.conn.String(), "TUN/TAP generic write debug:", err)
} else {

View file

@ -28,9 +28,9 @@ import (
type MTU uint16
// TunAdapter represents a running TUN interface and extends the
// yggdrasil.Adapter type. In order to use the TUN adapter with Mesh, you
// should pass this object to the yggdrasil.SetRouterAdapter() function before
// calling yggdrasil.Start().
// mesh.Adapter type. In order to use the TUN adapter with Mesh, you
// should pass this object to the mesh.SetRouterAdapter() function before
// calling mesh.Start().
type TunAdapter struct {
rwc *ipv6rwc.ReadWriteCloser
config *config.NodeConfig