mirror of
https://github.com/MetaCubeX/mihomo.git
synced 2024-11-16 11:42:43 +08:00
fix: tun.device not shown in restful api
This commit is contained in:
parent
a08aa10630
commit
f52fe6aa74
|
@ -138,6 +138,7 @@ func New(options LC.Tun, tunnel C.Tunnel, additions ...inbound.Addition) (l *Lis
|
|||
tunName := options.Device
|
||||
if options.FileDescriptor == 0 && (tunName == "" || !checkTunName(tunName)) {
|
||||
tunName = CalculateInterfaceName(InterfaceName)
|
||||
options.Device = tunName
|
||||
}
|
||||
routeAddress := options.RouteAddress
|
||||
if len(options.Inet4RouteAddress) > 0 {
|
||||
|
|
Loading…
Reference in New Issue
Block a user