title: Curl - checking connection
body: <p>I used Curl 7.2.9 and checked connection this way:</p>
  
  <p>Here's example:</p>
  
  <pre><code>curl = curl_easy_init();
  bool result = false;
  if(curl)
  {
      curl_easy_setopt(curl, CURLOPT_URL, m_checkConnectionUrl);
      CURLcode res = curl_easy_perform(curl);
  }
  if(res != CURLE_OK)
  {
  
  }
  else
  {
      // connection is available
  }
  </code></pre>
  
  <p>Now I switched to curl-7.33.0 and got *CURLE_WRITE_ERROR* error,
  and to make it work I must code it like</p>
  
  <pre><code>std::string output;
  char* encodedUrl = curl_easy_escape(curl, m_checkConnectionUrl, 0);
  curl_easy_setopt(curl, CURLOPT_POST, 0);
  curl_easy_setopt(curl, CURLOPT_URL, encodedUrl);
  curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, writeMemoryCurlCallbackStub);
  CURLcode res = curl_easy_perform(curl);
  </code></pre>
  
  <p>But I don't need to write anything. Any ideas?</p>