chore: add logging for get tun name from fd

This commit is contained in:
wwqgtxx
2026-04-01 09:41:16 +08:00
parent 018a2918fa
commit 0120b1d76d
+3
View File
@@ -158,6 +158,9 @@ func New(options LC.Tun, tunnel C.Tunnel, additions ...inbound.Addition) (l *Lis
if tunnelName, err := getTunnelName(int32(options.FileDescriptor)); err == nil {
tunName = tunnelName // sing-tun must have the truth tun interface name even it from a fd
forwarderBindInterface = true
log.Debugln("[TUN] use tun name %s for fd %d", tunnelName, options.FileDescriptor)
} else {
log.Warnln("[TUN] get tun name failed for fd %d, fallback to use tun interface name %s", options.FileDescriptor, tunName)
}
}
routeAddress := options.RouteAddress