diff options
Diffstat (limited to 'CommonLibs/Sockets.h')
-rw-r--r-- | CommonLibs/Sockets.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/CommonLibs/Sockets.h b/CommonLibs/Sockets.h index 0a70269..8312843 100644 --- a/CommonLibs/Sockets.h +++ b/CommonLibs/Sockets.h @@ -144,11 +144,11 @@ class UDPSocket : public DatagramSocket { public: /** Open a USP socket with an OS-assigned port and no default destination. */ - UDPSocket( unsigned short localPort=0); + UDPSocket(const char *localIP, unsigned short localPort); /** Given a full specification, open the socket and set the dest address. */ - UDPSocket( unsigned short localPort, - const char * remoteIP, unsigned short remotePort); + UDPSocket(const char *localIP, unsigned short localPort, + const char *remoteIP, unsigned short remotePort); /** Set the destination port. */ void destination( unsigned short wDestPort, const char * wDestIP ); @@ -157,7 +157,7 @@ public: unsigned short port() const; /** Open and bind the UDP socket to a local port. */ - void open(unsigned short localPort=0); + void open(unsigned short localPort=0, const char *wlocalIP="127.0.0.1"); /** Give the return address of the most recently received packet. */ const struct sockaddr_in* source() const { return (const struct sockaddr_in*)mSource; } |