-
Notifications
You must be signed in to change notification settings - Fork 164
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make server4 package compile on Windows
The user can pass directly a net.PacketConn.
- Loading branch information
1 parent
95b2ff6
commit 6488a06
Showing
3 changed files
with
19 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
// +build !windows | ||
|
||
package server4 | ||
|
||
import ( | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package server4 | ||
|
||
import ( | ||
"errors" | ||
"net" | ||
) | ||
|
||
func NewIPv4UDPConn(iface string, addr *net.UDPAddr) (*net.UDPConn, error) { | ||
return nil, errors.New("not implemented on Windows") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package interfaces | ||
|
||
import "errors" | ||
|
||
func BindToInterface(fd int, ifname string) error { | ||
return errors.New("not implemented on Windows") | ||
} |