194 |
CURLcode res; |
CURLcode res; |
195 |
struct curl_httppost *formpost = NULL; |
struct curl_httppost *formpost = NULL; |
196 |
struct curl_httppost *lastptr = NULL; |
struct curl_httppost *lastptr = NULL; |
197 |
|
struct curl_slist *slist = NULL; |
198 |
|
|
199 |
if (!session) |
if (!session) |
200 |
return -EINVAL; |
return -EINVAL; |
221 |
switch (session->host) { |
switch (session->host) { |
222 |
case HOST_TWITTER: |
case HOST_TWITTER: |
223 |
curl_easy_setopt(curl, CURLOPT_URL, twitter_url); |
curl_easy_setopt(curl, CURLOPT_URL, twitter_url); |
224 |
|
/* |
225 |
|
* twitter doesn't like the "Expect: 100-continue" header |
226 |
|
* anymore, so turn it off. |
227 |
|
*/ |
228 |
|
slist = curl_slist_append(slist, "Expect:"); |
229 |
|
curl_easy_setopt(curl, CURLOPT_HTTPHEADER, slist); |
230 |
break; |
break; |
231 |
case HOST_IDENTICA: |
case HOST_IDENTICA: |
232 |
curl_easy_setopt(curl, CURLOPT_URL, identica_url); |
curl_easy_setopt(curl, CURLOPT_URL, identica_url); |