Browse Source

Fix compile errors on Windows

Rod Hynes 11 years ago
parent
commit
c57613b23d
2 changed files with 3 additions and 4 deletions
  1. 1 1
      psiphon/LookupIP_nobind.go
  2. 2 3
      psiphon/TCPConn_windows.go

+ 1 - 1
psiphon/LookupIP_nobind.go

@@ -28,7 +28,7 @@ import (
 // LookupIP resolves a hostname. When BindToDevice is not required, it
 // simply uses net.LookuIP.
 func LookupIP(host string, config *DialConfig) (addrs []net.IP, err error) {
-	if config.BindToDeviceServiceAddr != "" {
+	if config.BindToDeviceServiceAddress != "" {
 		Fatal("LookupIP with bind not supported on this platform")
 	}
 	return net.LookupIP(host)

+ 2 - 3
psiphon/TCPConn_windows.go

@@ -23,14 +23,13 @@ package psiphon
 
 import (
 	"net"
-	"time"
 )
 
 type interruptibleTCPSocket struct {
 }
 
-func interruptibleTCPDial(addr string, config *TCPConfig) (conn *TCPConn, err error) {
-	if config.BindToDeviceServiceAddr != "" {
+func interruptibleTCPDial(addr string, config *DialConfig) (conn *TCPConn, err error) {
+	if config.BindToDeviceServiceAddress != "" {
 		Fatal("psiphon.interruptibleTCPDial with bind not supported on Windows")
 	}
 	// Note: using standard net.Dial(); interruptible connections not supported on Windows