From: havoc Date: Tue, 24 Sep 2002 22:11:44 +0000 (+0000) Subject: fix some prototype warnings X-Git-Tag: RELEASE_0_2_0_RC1~201 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=a79a57664e9b2420bb4b5a06cde2e84b7191e967;p=xonotic%2Fdarkplaces.git fix some prototype warnings git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2436 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/net.h b/net.h index 55800b04..e4be15b8 100644 --- a/net.h +++ b/net.h @@ -170,12 +170,12 @@ typedef struct int (*Read) (int socket, qbyte *buf, int len, struct qsockaddr *addr); int (*Write) (int socket, qbyte *buf, int len, struct qsockaddr *addr); int (*Broadcast) (int socket, qbyte *buf, int len); - char * (*AddrToString) (struct qsockaddr *addr); + char * (*AddrToString) (const struct qsockaddr *addr); int (*StringToAddr) (const char *string, struct qsockaddr *addr); int (*GetSocketAddr) (int socket, struct qsockaddr *addr); - int (*GetNameFromAddr) (struct qsockaddr *addr, char *name); + int (*GetNameFromAddr) (const struct qsockaddr *addr, char *name); int (*GetAddrFromName) (const char *name, struct qsockaddr *addr); - int (*AddrCompare) (struct qsockaddr *addr1, struct qsockaddr *addr2); + int (*AddrCompare) (const struct qsockaddr *addr1, const struct qsockaddr *addr2); int (*GetSocketPort) (struct qsockaddr *addr); int (*SetSocketPort) (struct qsockaddr *addr, int port); } net_landriver_t; diff --git a/net_wipx.c b/net_wipx.c index 3e62cb4c..7bed13c7 100644 --- a/net_wipx.c +++ b/net_wipx.c @@ -411,7 +411,7 @@ int WIPX_GetAddrFromName(const char *name, struct qsockaddr *addr) //============================================================================= -int WIPX_AddrCompare (struct qsockaddr *addr1, struct qsockaddr *addr2) +int WIPX_AddrCompare (const struct qsockaddr *addr1, const struct qsockaddr *addr2) { if (addr1->sa_family != addr2->sa_family) return -1; diff --git a/net_wipx.h b/net_wipx.h index 120b2ab3..82bb49bb 100644 --- a/net_wipx.h +++ b/net_wipx.h @@ -39,7 +39,7 @@ int WIPX_StringToAddr (const char *string, struct qsockaddr *addr); int WIPX_GetSocketAddr (int socket, struct qsockaddr *addr); int WIPX_GetNameFromAddr (const struct qsockaddr *addr, char *name); int WIPX_GetAddrFromName (const char *name, struct qsockaddr *addr); -int WIPX_AddrCompare (struct qsockaddr *addr1, struct qsockaddr *addr2); +int WIPX_AddrCompare (const struct qsockaddr *addr1, const struct qsockaddr *addr2); int WIPX_GetSocketPort (struct qsockaddr *addr); int WIPX_SetSocketPort (struct qsockaddr *addr, int port);