summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 66124ee)
raw | patch | inline | side by side (parent: 66124ee)
author | Florian Forster <octo@huhu.verplant.org> | |
Sun, 8 Aug 2010 08:59:15 +0000 (10:59 +0200) | ||
committer | Florian Forster <octo@huhu.verplant.org> | |
Sun, 8 Aug 2010 08:59:15 +0000 (10:59 +0200) |
src/curl_json.c | patch | blob | history |
diff --git a/src/curl_json.c b/src/curl_json.c
index a7acc81ca42a233393ca6701b0cb244f1d6206a4..e34f90aa5346148eb69376de89f8bbd4440d44e0 100644 (file)
--- a/src/curl_json.c
+++ b/src/curl_json.c
curl_easy_getinfo(curl, CURLINFO_EFFECTIVE_URL, &url);
curl_easy_getinfo(curl, CURLINFO_RESPONSE_CODE, &rc);
- if (rc != 200)
+ /* The response code is zero if a non-HTTP transport was used. */
+ if ((rc != 0) && (rc != 200))
{
ERROR ("curl_json plugin: curl_easy_perform failed with response code %ld (%s)",
rc, url);