Merge branch 'plugin-automation'
[ardour.git] / gtk2_ardour / pingback.cc
index c108e5e96e1bec765c6140bd7c3eeaeced470c46..62d9191daf09c3983579d69656aaedd1b71b424f 100644 (file)
 #include <fstream>
 #include <cstring>
 
+#ifndef PLATFORM_WINDOWS
 #include <sys/utsname.h>
+#endif
+
 #include <curl/curl.h>
 
 #include <glibmm/miscutils.h>
@@ -70,6 +73,7 @@ struct ping_call {
 static void*
 _pingback (void *arg)
 {
+#ifndef PLATFORM_WINDOWS
        ping_call* cm = static_cast<ping_call*> (arg);
        CURL* c;
        struct utsname utb;
@@ -88,13 +92,6 @@ _pingback (void *arg)
        curl_easy_setopt (c, CURLOPT_WRITEDATA, &return_str); 
        char errbuf[CURL_ERROR_SIZE];
        curl_easy_setopt (c, CURLOPT_ERRORBUFFER, errbuf); 
-       /* we really would prefer to be able to authenticate the certificate
-          but this has issues that right now (march 2013), i don't understand.
-       */
-       curl_easy_setopt (c, CURLOPT_SSL_VERIFYPEER, 0);
-
-       //get announcements from our server
-       std::cerr << "Checking for Announcements from ardour.org  ...\n";
 
        string url;
 
@@ -135,7 +132,7 @@ _pingback (void *arg)
        return_str = "";
 
        if (curl_easy_perform (c) == 0) {
-               int http_status; 
+               long http_status; 
 
                curl_easy_getinfo (c, CURLINFO_RESPONSE_CODE, &http_status);
 
@@ -165,6 +162,8 @@ _pingback (void *arg)
        curl_easy_cleanup (c);
        delete cm;
 
+#endif /* PLATFORM_WINDOWS */
+
        return 0;
 }