mirror of https://github.com/BOINC/boinc.git
- don't include config.h from network.h (Gabor Gombas)
svn path=/trunk/boinc/; revision=18428
This commit is contained in:
parent
16e87bc84e
commit
d7aacaac32
|
@ -5700,3 +5700,13 @@ David 16 June 2009
|
|||
|
||||
client/
|
||||
client_types.cpp,h
|
||||
|
||||
David 16 June 2009
|
||||
- don't include config.h from network.h (Gabor Gombas)
|
||||
|
||||
client/
|
||||
gui_rpc_server.cpp
|
||||
m4/
|
||||
boinc_getsockopt.m4
|
||||
lib/
|
||||
network.cpp,h
|
||||
|
|
|
@ -250,7 +250,7 @@ int GUI_RPC_CONN_SET::init(bool last_time) {
|
|||
int one = 1;
|
||||
setsockopt(lsock, SOL_SOCKET, SO_REUSEADDR, (char*)&one, 4);
|
||||
|
||||
retval = bind(lsock, (const sockaddr*)(&addr), (boinc_socklen_t)sizeof(addr));
|
||||
retval = bind(lsock, (const sockaddr*)(&addr), (socklen_t)sizeof(addr));
|
||||
if (retval) {
|
||||
#ifndef _WIN32
|
||||
retval = errno; // Display the real error code
|
||||
|
@ -367,8 +367,8 @@ void GUI_RPC_CONN_SET::got_select(FDSET_GROUP& fg) {
|
|||
return;
|
||||
}
|
||||
|
||||
boinc_socklen_t addr_len = sizeof(addr);
|
||||
sock = accept(lsock, (struct sockaddr*)&addr, (boinc_socklen_t*)&addr_len);
|
||||
socklen_t addr_len = sizeof(addr);
|
||||
sock = accept(lsock, (struct sockaddr*)&addr, (socklen_t*)&addr_len);
|
||||
if (sock == -1) {
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -174,7 +174,7 @@ void boinc_close_socket(int sock) {
|
|||
}
|
||||
|
||||
int get_socket_error(int fd) {
|
||||
boinc_socklen_t intsize = sizeof(int);
|
||||
socklen_t intsize = sizeof(int);
|
||||
int n;
|
||||
#if defined(_WIN32) && defined(USE_WINSOCK)
|
||||
getsockopt(fd, SOL_SOCKET, SO_ERROR, (char *)&n, &intsize);
|
||||
|
|
|
@ -22,7 +22,6 @@
|
|||
#ifndef _WIN32
|
||||
#include <sys/select.h>
|
||||
#include <unistd.h>
|
||||
#include "config.h"
|
||||
#else
|
||||
#include "boinc_win.h"
|
||||
#endif
|
||||
|
@ -49,14 +48,6 @@ extern int get_socket_error(int fd);
|
|||
extern const char* socket_error_str();
|
||||
extern void reset_dns();
|
||||
|
||||
#if defined(_WIN32) && defined(USE_WINSOCK)
|
||||
typedef int boinc_socklen_t;
|
||||
#define SHUT_WR SD_SEND
|
||||
#else
|
||||
typedef BOINC_SOCKLEN_T boinc_socklen_t;
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef NETWORK_ALIVE_LAN
|
||||
#define NETWORK_ALIVE_LAN 0x00000001
|
||||
#endif
|
||||
|
|
|
@ -71,5 +71,10 @@ CFLAGS="${B_SV_CFLAGS}"
|
|||
CPPFLAGS="${B_SV_CPPFLAGS}"
|
||||
AC_DEFINE_UNQUOTED([BOINC_SOCKLEN_T],[${boinc_cv_getsockopt_type}],[Define to the type pointed to by the 5th parameter of getsockopt])
|
||||
AC_LANG_POP(C)
|
||||
AH_BOTTOM([
|
||||
#ifndef HAVE_SOCKLEN_T
|
||||
typedef BOINC_SOCKLEN_T socklen_t;
|
||||
#endif
|
||||
])
|
||||
])
|
||||
|
||||
|
|
Loading…
Reference in New Issue