Add DefaultInterfaceMonitor.MyInterface

This commit is contained in:
世界
2025-04-12 14:39:22 +08:00
parent 2121bc3f01
commit f57754918d
5 changed files with 19 additions and 2 deletions

View File

@@ -264,7 +264,7 @@ func (t *NativeTun) Start() error {
if t.options.FileDescriptor != 0 {
return nil
}
t.options.InterfaceMonitor.RegisterMyInterface(t.options.Name)
tunLink, err := netlink.LinkByName(t.options.Name)
if err != nil {
return err