cURL / Mailing Lists / curl-library / Single Mail


curl_easy_perform can't download huge file

From: Sino <>
Date: Thu, 3 Dec 2015 10:27:40 +0800


I am using libcurl 7.35.0 on ubuntu 14.04 x86-64 platform.

What I want to do is to download one huge file greater than 200M by
using curl_easy_perform.

It always downloads partial file, for example, one 433M file, it
always ends at the size of 190M or so. curl_easy_perform returns
without error.

here are options I set.

    curl_easy_setopt(handle, CURLOPT_URL, pi->url);
    curl_easy_setopt(handle, CURLOPT_TCP_KEEPALIVE, 1L);
    curl_easy_setopt(handle, CURLOPT_TCP_KEEPIDLE, 15L);
    curl_easy_setopt(handle, CURLOPT_TCP_KEEPINTVL, 30L);

But curl command tool can download the total file.

Anyone can help on that?

Thanks very much.
List admin:
Received on 2015-12-03