|
|
cURL Mailing List Monthly Index Single Mail
curl-library Archives
(no subject)
From: Chris Johnson <chrisj_at_terminalreality.com>
Date: Tue, 17 Nov 2009 13:58:59 -0600
I am developing an application with C++ and libcurl. I can download and upload files fine, but I have an issue when trying to get the size of the file that I want to download from the SFTP server before downloading the file.
I am accessing an SFTP server (via sftp://). I use curl_easy_getinfo to set both CURLINFO_CONTENT_LENGTH_UPLOAD and CURLINFO_CONTENT_LENGTH_DOWNLOAD thinking that would give me the size of the file I am trying to download. Unfortunately, CURLINFO_CONTENT_LENGTH_UPLOAD returns -1.0 and CURLINFO_CONTENT_LENGTH_DOWNLOAD returns the size of the file I downloaded last. Is there a way to get the size of the file I'm trying to download before I actually download the file? Does the SFTP server need to be setup with certain attributes to allow this?
Thanks,
These mail archives are generated by hypermail. |
Page updated November 16, 2009.
web site info