Added GAddress_INET_SetAnyAddress and dummy UNIX address handling.
Anyway, GSocket_GUI_Init/Destroy, GSocket_Enable/Disable_Events and GSocket_Install/Uninstall_Callback are still missing... git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@5617 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1126,6 +1126,11 @@ GSocketError GAddress_INET_SetHostName(GAddress *address, const char *hostname)
|
|||||||
return GSOCK_NOERROR;
|
return GSOCK_NOERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
GSocketError GAddress_INET_SetAnyAddress(GAddress *address)
|
||||||
|
{
|
||||||
|
return GAddress_INET_SetHostAddress(address, INADDR_ANY);
|
||||||
|
}
|
||||||
|
|
||||||
GSocketError GAddress_INET_SetHostAddress(GAddress *address,
|
GSocketError GAddress_INET_SetHostAddress(GAddress *address,
|
||||||
unsigned long hostaddr)
|
unsigned long hostaddr)
|
||||||
{
|
{
|
||||||
@@ -1235,5 +1240,32 @@ unsigned short GAddress_INET_GetPort(GAddress *address)
|
|||||||
return ntohs(addr->sin_port);
|
return ntohs(addr->sin_port);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* -------------------------------------------------------------------------
|
||||||
|
* Unix address family
|
||||||
|
* -------------------------------------------------------------------------
|
||||||
|
*/
|
||||||
|
|
||||||
|
GSocketError _GAddress_Init_UNIX(GAddress *address)
|
||||||
|
{
|
||||||
|
assert (address != NULL);
|
||||||
|
address->m_error = GSOCK_INVADDR;
|
||||||
|
return GSOCK_INVADDR;
|
||||||
|
}
|
||||||
|
|
||||||
|
GSocketError GAddress_UNIX_SetPath(GAddress *address, const char *path)
|
||||||
|
{
|
||||||
|
assert (address != NULL);
|
||||||
|
address->m_error = GSOCK_INVADDR;
|
||||||
|
return GSOCK_INVADDR;
|
||||||
|
}
|
||||||
|
|
||||||
|
GSocketError GAddress_UNIX_GetPath(GAddress *address, char *path, size_t sbuf)
|
||||||
|
{
|
||||||
|
assert (address != NULL);
|
||||||
|
address->m_error = GSOCK_INVADDR;
|
||||||
|
return GSOCK_INVADDR;
|
||||||
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
/* wxUSE_SOCKETS */
|
/* wxUSE_SOCKETS */
|
||||||
|
Reference in New Issue
Block a user