dhruvbird/http-sync — pull request #3 by 9re (2012-12-07 10:45:52+00:00)
Title: Post method is not working

in curl_easy_setopt documentation(http://curl.haxx.se/libcurl/c/curl_easy_setopt.html)

Data for CURLOPT_READDATA must be a valid readable FILE *.

so I replaced the codes:

```c
curl_easy_setopt(curl, CURLOPT_READFUNCTION, read_data);
curl_easy_setopt(curl, CURLOPT_READDATA, (void*)&_body);
```

with

```c
if (_body.size()) {
curl_easy_setopt(curl, CURLOPT_POSTFIELDS, reinterpret_cast (&_body[0]));
curl_easy_setopt(curl, CURLOPT_POSTFIELDSIZE_LARGE, (curl_off_t)-1);
}
```