diff --git a/checkin_notes b/checkin_notes index 1d1c917ded..e021dddc56 100644 --- a/checkin_notes +++ b/checkin_notes @@ -6540,3 +6540,17 @@ Rom 1 Nov 2012 samples\vboxwrapper\ vbox.cpp, .h + +David 1 Nov 2012 + - client/manager: move the conditional define of MAXPATHLEN + from boinc_win.h to filesys.h, + so that the client will hopefully build on Hurd, + which doesn't define MAXPATHLEN. + + client/ + http_curl.cpp + lib/ + boinc_win.h + common_defs.h + filesys.h + gui_rpc_client.h diff --git a/client/http_curl.cpp b/client/http_curl.cpp index 01af8bebab..0e673c0cc2 100644 --- a/client/http_curl.cpp +++ b/client/http_curl.cpp @@ -388,13 +388,13 @@ bool HTTP_OP::no_proxy_for_url(const char* url) { return false; } -static int set_cloexec(void*, curl_socket_t fd, curlsocktype purpose) { #ifndef _WIN32 +static int set_cloexec(void*, curl_socket_t fd, curlsocktype purpose) { if (purpose != CURLSOCKTYPE_IPCXN) return 0; fcntl(fd, F_SETFD, FD_CLOEXEC); -#endif return 0; } +#endif // the following will do an HTTP GET or POST using libcurl // @@ -534,11 +534,12 @@ int HTTP_OP::libcurl_exec( // curl_easy_setopt(curlEasy, CURLOPT_NOPROGRESS, 1L); +#ifndef _WIN32 // arrange for a function to get called between socket() and connect() // so that we can mark the socket as close-on-exec // curl_easy_setopt(curlEasy, CURLOPT_SOCKOPTFUNCTION, set_cloexec); - +#endif // setup timeouts // curl_easy_setopt(curlEasy, CURLOPT_TIMEOUT, 0L); diff --git a/lib/boinc_win.h b/lib/boinc_win.h index 8e745a9df1..f51ff3df6d 100644 --- a/lib/boinc_win.h +++ b/lib/boinc_win.h @@ -22,10 +22,6 @@ #ifndef _BOINC_WIN_ #define _BOINC_WIN_ -#ifndef MAXPATHLEN -#define MAXPATHLEN 4096 -#endif - #ifndef __CYGWIN32__ // Windows C Runtime Library diff --git a/lib/common_defs.h b/lib/common_defs.h index 74e85c91ac..c38d834659 100644 --- a/lib/common_defs.h +++ b/lib/common_defs.h @@ -233,5 +233,4 @@ struct VERSION_INFO { #define DEFAULT_SS_EXECUTABLE "boincscr" #endif - #endif diff --git a/lib/filesys.h b/lib/filesys.h index efd129eb05..86e22d8395 100644 --- a/lib/filesys.h +++ b/lib/filesys.h @@ -32,6 +32,10 @@ #endif /* !WIN32 */ +#ifndef MAXPATHLEN +#define MAXPATHLEN 4096 +#endif + #define FILE_RETRY_INTERVAL 5 // On Windows, retry for this period of time, since some other program // (virus scan, defrag, index) may have the file open. diff --git a/lib/gui_rpc_client.h b/lib/gui_rpc_client.h index 153fa2ad7a..f3b2e7f175 100644 --- a/lib/gui_rpc_client.h +++ b/lib/gui_rpc_client.h @@ -33,13 +33,14 @@ #include #endif -#include "miofile.h" -#include "prefs.h" -#include "hostinfo.h" -#include "common_defs.h" -#include "notice.h" -#include "network.h" #include "cc_config.h" +#include "common_defs.h" +#include "filesys.h" +#include "hostinfo.h" +#include "miofile.h" +#include "network.h" +#include "notice.h" +#include "prefs.h" struct GUI_URL { std::string name;