]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
add nosignal
authorRupa Schomaker <rupa@rupa.com>
Fri, 18 Dec 2009 20:16:37 +0000 (20:16 +0000)
committerRupa Schomaker <rupa@rupa.com>
Fri, 18 Dec 2009 20:16:37 +0000 (20:16 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@15998 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/mod/applications/mod_curl/mod_curl.c

index 61ee66db6529630f541ded8249812b2219682f87..30dff12b430019f48fe39f232a6b71e36f175f39 100755 (executable)
@@ -129,17 +129,18 @@ static http_data_t *do_lookup_url(switch_memory_pool_t *pool, const char *url, c
                curl_easy_setopt(curl_handle, CURLOPT_SSL_VERIFYHOST, 0);
        }
        if (!strcasecmp(method, "head")) {
-               curl_easy_setopt(curl_handle, CURLOPT_NOBODY, SWITCH_TRUE);
+               curl_easy_setopt(curl_handle, CURLOPT_NOBODY, 1);
        } else if (!strcasecmp(method, "post")) {
                curl_easy_setopt(curl_handle, CURLOPT_POSTFIELDSIZE, strlen(data));
                curl_easy_setopt(curl_handle, CURLOPT_POSTFIELDS, (void *) data);
                switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Post data: %s\n", data);
        } else {
-               curl_easy_setopt(curl_handle, CURLOPT_HTTPGET, SWITCH_TRUE);
+               curl_easy_setopt(curl_handle, CURLOPT_HTTPGET, 1);
        }
        curl_easy_setopt(curl_handle, CURLOPT_FOLLOWLOCATION, 0);
        curl_easy_setopt(curl_handle, CURLOPT_MAXREDIRS, 0);
        curl_easy_setopt(curl_handle, CURLOPT_URL, url);
+       curl_easy_setopt(curl_handle, CURLOPT_NOSIGNAL, 1);
        curl_easy_setopt(curl_handle, CURLOPT_WRITEFUNCTION, file_callback);
        curl_easy_setopt(curl_handle, CURLOPT_WRITEDATA, (void *) http_data);
        curl_easy_setopt(curl_handle, CURLOPT_HEADERFUNCTION, header_callback);