Introduce Bridge
This commit is contained in:
1 parent
64e3cf04cc
commit
57e78e2bec
5 files changed
+174
-132
No files matched your search
+2
-10
@@ -63,14 +63,6 @@ type LocalConnectionStatus struct {
|
||||
}
|
||||
|
||||
func NewStatus(router *Router) *Status {
|
||||
var ifaceName string
|
||||
if router.Iface != nil {
|
||||
ifaceName = router.Iface.Name
|
||||
}
|
||||
var captureStats map[string]int
|
||||
if router.PacketSource != nil {
|
||||
captureStats = router.PacketSource.Stats()
|
||||
}
|
||||
return &Status{
|
||||
Protocol,
|
||||
ProtocolMinVersion,
|
||||
@@ -80,8 +72,8 @@ func NewStatus(router *Router) *Status {
|
||||
router.Ourself.Name.String(),
|
||||
router.Ourself.NickName,
|
||||
router.Port,
|
||||
ifaceName,
|
||||
captureStats,
|
||||
router.Bridge.String(),
|
||||
router.Bridge.Stats(),
|
||||
NewMACStatusSlice(router.Macs),
|
||||
NewPeerStatusSlice(router.Peers),
|
||||
NewUnicastRouteStatusSlice(router.Routes),
|
||||
|
||||
Reference in new issue
Block a user