CURL *curl;
http_raw_data_t *raw_data = DA_NULL;
curl = http_info->http_msg->curl;
+ if (http_info->proxy_info) {
+ DA_LOGI("Proxy is set.");
+ res = curl_easy_getinfo(curl, CURLINFO_HTTP_CONNECTCODE, &status);
+ } else {
res = curl_easy_getinfo(curl, CURLINFO_RESPONSE_CODE, &status);
+ }
if (res != CURLE_OK) {
DA_LOGE("Fail to get response status code");
return;
}
- DA_LOGV("status code[%d]", (int)status);
+ DA_LOGI("status code[%d]", (int)status);
if (http_info->http_msg_response)
http_info->http_msg_response->status_code = (int)status;
raw_data = (http_raw_data_t *)calloc(1, sizeof(http_raw_data_t));
if (proxy_info && strlen(proxy_info->addr) > 0) {
if (!strstr(proxy_info->addr, "0.0.0.0")) {
curl_easy_setopt(curl, CURLOPT_PROXY, proxy_info->addr);
+ DA_LOGI("proxy[%s] is used.", proxy_info->addr);
if (proxy_info->user_name || proxy_info->password)
curl_easy_setopt(curl, CURLOPT_PROXYAUTH, CURLAUTH_ANY);
if (proxy_info->user_name)