Commit 2b7963b4 authored by rswindell's avatar rswindell
Browse files

Remove the DLLCALL noise, we don't need it.

parent a4676fd8
......@@ -144,7 +144,7 @@ static socket_option_t socket_options[] = {
{ NULL }
};
int DLLCALL getSocketOptionByName(const char* name, int* level)
int getSocketOptionByName(const char* name, int* level)
{
int i;
......@@ -162,12 +162,12 @@ int DLLCALL getSocketOptionByName(const char* name, int* level)
return(strtol(name,NULL,0));
}
socket_option_t* DLLCALL getSocketOptionList(void)
socket_option_t* getSocketOptionList(void)
{
return(socket_options);
}
int DLLCALL sendfilesocket(int sock, int file, off_t *offset, off_t count)
int sendfilesocket(int sock, int file, off_t *offset, off_t count)
{
char buf[1024*16];
off_t len;
......@@ -229,7 +229,7 @@ int DLLCALL sendfilesocket(int sock, int file, off_t *offset, off_t count)
return(total);
}
int DLLCALL recvfilesocket(int sock, int file, off_t *offset, off_t count)
int recvfilesocket(int sock, int file, off_t *offset, off_t count)
{
/* Writes a file from a socket -
*
......@@ -284,7 +284,7 @@ int DLLCALL recvfilesocket(int sock, int file, off_t *offset, off_t count)
/* Return true if connected, optionally sets *rd_p to true if read data available */
BOOL DLLCALL socket_check(SOCKET sock, BOOL* rd_p, BOOL* wr_p, DWORD timeout)
BOOL socket_check(SOCKET sock, BOOL* rd_p, BOOL* wr_p, DWORD timeout)
{
char ch;
int i,rd;
......@@ -343,7 +343,7 @@ BOOL DLLCALL socket_check(SOCKET sock, BOOL* rd_p, BOOL* wr_p, DWORD timeout)
return(FALSE);
}
int DLLCALL retry_bind(SOCKET s, const struct sockaddr *addr, socklen_t addrlen
int retry_bind(SOCKET s, const struct sockaddr *addr, socklen_t addrlen
,uint retries, uint wait_secs
,const char* prot
,int (*lprintf)(int level, const char *fmt, ...))
......@@ -372,7 +372,7 @@ int DLLCALL retry_bind(SOCKET s, const struct sockaddr *addr, socklen_t addrlen
return(result);
}
int DLLCALL nonblocking_connect(SOCKET sock, struct sockaddr* addr, size_t size, unsigned timeout)
int nonblocking_connect(SOCKET sock, struct sockaddr* addr, size_t size, unsigned timeout)
{
int result;
......@@ -408,7 +408,7 @@ int DLLCALL nonblocking_connect(SOCKET sock, struct sockaddr* addr, size_t size,
}
union xp_sockaddr* DLLCALL inet_ptoaddr(char *addr_str, union xp_sockaddr *addr, size_t size)
union xp_sockaddr* inet_ptoaddr(char *addr_str, union xp_sockaddr *addr, size_t size)
{
struct addrinfo hints = {0};
struct addrinfo *res, *cur;
......@@ -435,7 +435,7 @@ union xp_sockaddr* DLLCALL inet_ptoaddr(char *addr_str, union xp_sockaddr *addr,
return addr;
}
const char* DLLCALL inet_addrtop(union xp_sockaddr *addr, char *dest, size_t size)
const char* inet_addrtop(union xp_sockaddr *addr, char *dest, size_t size)
{
#ifdef _WIN32
if(getnameinfo(&addr->addr, xp_sockaddr_len(addr), dest, size, NULL, 0, NI_NUMERICHOST))
......@@ -458,7 +458,7 @@ const char* DLLCALL inet_addrtop(union xp_sockaddr *addr, char *dest, size_t siz
#endif
}
uint16_t DLLCALL inet_addrport(union xp_sockaddr *addr)
uint16_t inet_addrport(union xp_sockaddr *addr)
{
switch(addr->addr.sa_family) {
case AF_INET:
......@@ -470,7 +470,7 @@ uint16_t DLLCALL inet_addrport(union xp_sockaddr *addr)
}
}
void DLLCALL inet_setaddrport(union xp_sockaddr *addr, uint16_t port)
void inet_setaddrport(union xp_sockaddr *addr, uint16_t port)
{
switch(addr->addr.sa_family) {
case AF_INET:
......@@ -483,7 +483,7 @@ void DLLCALL inet_setaddrport(union xp_sockaddr *addr, uint16_t port)
}
/* Return TRUE if the 2 addresses are the same host (type and address) */
BOOL DLLCALL inet_addrmatch(union xp_sockaddr* addr1, union xp_sockaddr* addr2)
BOOL inet_addrmatch(union xp_sockaddr* addr1, union xp_sockaddr* addr2)
{
if(addr1->addr.sa_family != addr2->addr.sa_family)
return FALSE;
......
......@@ -90,7 +90,7 @@
#endif
#include <errno.h> /* errno */
#include "wrapdll.h" /* DLLEXPORT/DLLCALL */
#include "wrapdll.h" /* DLLEXPORT */
typedef struct {
char* name;
......@@ -222,22 +222,21 @@ static int wsa_error;
extern "C" {
#endif
DLLEXPORT socket_option_t* DLLCALL
getSocketOptionList(void);
DLLEXPORT int DLLCALL getSocketOptionByName(const char* name, int* level);
DLLEXPORT socket_option_t* getSocketOptionList(void);
DLLEXPORT int getSocketOptionByName(const char* name, int* level);
DLLEXPORT int DLLCALL sendfilesocket(int sock, int file, off_t* offset, off_t count);
DLLEXPORT int DLLCALL recvfilesocket(int sock, int file, off_t* offset, off_t count);
DLLEXPORT BOOL DLLCALL socket_check(SOCKET sock, BOOL* rd_p, BOOL* wr_p, DWORD timeout);
DLLEXPORT int DLLCALL retry_bind(SOCKET s, const struct sockaddr *addr, socklen_t addrlen
DLLEXPORT int sendfilesocket(int sock, int file, off_t* offset, off_t count);
DLLEXPORT int recvfilesocket(int sock, int file, off_t* offset, off_t count);
DLLEXPORT BOOL socket_check(SOCKET sock, BOOL* rd_p, BOOL* wr_p, DWORD timeout);
DLLEXPORT int retry_bind(SOCKET s, const struct sockaddr *addr, socklen_t addrlen
,uint retries, uint wait_secs, const char* prot
,int (*lprintf)(int level, const char *fmt, ...));
DLLEXPORT int DLLCALL nonblocking_connect(SOCKET, struct sockaddr*, size_t, unsigned timeout /* seconds */);
DLLEXPORT union xp_sockaddr* DLLCALL inet_ptoaddr(char *addr_str, union xp_sockaddr *addr, size_t size);
DLLEXPORT const char* DLLCALL inet_addrtop(union xp_sockaddr *addr, char *dest, size_t size);
DLLEXPORT uint16_t DLLCALL inet_addrport(union xp_sockaddr *addr);
DLLEXPORT void DLLCALL inet_setaddrport(union xp_sockaddr *addr, uint16_t port);
DLLEXPORT BOOL DLLCALL inet_addrmatch(union xp_sockaddr* addr1, union xp_sockaddr* addr2);
DLLEXPORT int nonblocking_connect(SOCKET, struct sockaddr*, size_t, unsigned timeout /* seconds */);
DLLEXPORT union xp_sockaddr* inet_ptoaddr(char *addr_str, union xp_sockaddr *addr, size_t size);
DLLEXPORT const char* inet_addrtop(union xp_sockaddr *addr, char *dest, size_t size);
DLLEXPORT uint16_t inet_addrport(union xp_sockaddr *addr);
DLLEXPORT void inet_setaddrport(union xp_sockaddr *addr, uint16_t port);
DLLEXPORT BOOL inet_addrmatch(union xp_sockaddr* addr1, union xp_sockaddr* addr2);
#ifdef __cplusplus
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment