From: Bluezery <ohpowel@gmail.com>

Subject: [E-devel] [ecore_con] Bug fix when data is NULL.

If data is NULL, curl makes length field as -1 .
length filed should be set by 0.



SVN revision: 65006
This commit is contained in:
Bluezery 2011-11-10 06:35:53 +00:00 committed by Carsten Haitzler
parent 1b00894c58
commit 216ea5012c
1 changed files with 3 additions and 4 deletions

View File

@ -695,10 +695,9 @@ _ecore_con_url_send(Ecore_Con_Url *url_con,
curl_easy_setopt(url_con->curl_easy, CURLOPT_POSTFIELDS, data);
curl_easy_setopt(url_con->curl_easy, CURLOPT_POSTFIELDSIZE, length);
}
else if (mode == MODE_POST)
{
curl_easy_setopt(url_con->curl_easy, CURLOPT_POST, 1);
}
else curl_easy_setopt(url_con->curl_easy, CURLOPT_POSTFIELDSIZE, 0);
if (mode == MODE_POST)
curl_easy_setopt(url_con->curl_easy, CURLOPT_POST, 1);
}
switch (url_con->time_condition)