mirror of
https://github.com/XTLS/Xray-core.git
synced 2026-10-17 21:14:01 +00:00
Make dial fail on interface bind err
This commit is contained in:
@@ -22,7 +22,7 @@ func applyOutboundSocketOptions(network string, address string, fd uintptr, conf
|
||||
|
||||
if config.Interface != "" {
|
||||
if err := syscall.BindToDevice(int(fd), config.Interface); err != nil {
|
||||
return errors.New("failed to set Interface").Base(err)
|
||||
return NewBindError(err)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user