/* read callback function, fread() look alike */
static size_t read_callback(void *ptr, size_t size, size_t nmemb, void *stream)
{
- size_t retcode;
+ ssize_t retcode;
curl_off_t nread;
intptr_t fd = (intptr_t)stream;
return 1;
}
- sockfd = sockextr;
+ sockfd = (curl_socket_t)sockextr;
/* wait for the socket to become ready for sending */
if(!wait_on_socket(sockfd, 0, 60000L)) {
static size_t write_data(void *ptr, size_t size, size_t nmemb, void *stream)
{
- int written = fwrite(ptr, size, nmemb, (FILE *)stream);
+ size_t written = fwrite(ptr, size, nmemb, (FILE *)stream);
return written;
}