cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: Is it possiable to let the `PROGRESS METER' give precise results upto bytes?

From: Hongyi Zhao <hongyi.zhao_at_gmail.com>
Date: Thu, 7 May 2015 22:21:01 +0800

2015-05-06 23:23 GMT+08:00 Daniel Stenberg <daniel_at_haxx.se>:
> On Wed, 6 May 2015, Hongyi Zhao wrote:
>
>> The `PROGRESS METER' of curl also uses `K' and `M' for the data transfer
>> progess it observed.
>>
>> can this be controlled by options/switches so that I can always let
>> `PROGRESS METER' give precise results upto bytes?
>
>
> No, there's no such option. And actually, it would be a bit tricky to
> support too since we're carefully not using more than 79 columns to fit in
> most terminals and if we'd show every byte we could end up with really large
> numbers...
>
> You can get the exact number with the progress callback from libcurl, but
> that of course then requires you to use a libcurl binding.

Do you mean compiling the curl with libcurl support? Plese see my
compiling info of curl listed as follows:

$ curl -V
curl 7.43.0-DEV (x86_64-unknown-linux-gnu) libcurl/7.43.0-DEV
OpenSSL/1.0.1e zlib/1.2.7 c-ares/1.9.1 libidn/1.25 libssh2/1.4.2
librtmp/2.3
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps
pop3 pop3s rtmp rtsp scp sftp smb smbs smtp smtps telnet tftp
Features: AsynchDNS IDN IPv6 Largefile GSS-API Kerberos SPNEGO NTLM
NTLM_WB SSL libz TLS-SRP UnixSockets Metalink

Can I get the exact number with the progress callback from libcurl
with the above curl version complied by me?

I'm not familiar with libcurl, could you please give some more hints
for the above job?

Regards
>
> --
>
> / daniel.haxx.se
> -------------------------------------------------------------------
> List admin: http://cool.haxx.se/list/listinfo/curl-users
> FAQ: http://curl.haxx.se/docs/faq.html
> Etiquette: http://curl.haxx.se/mail/etiquette.html

-- 
Hongyi Zhao <hongyi.zhao_at_gmail.com>
Xinjiang Technical Institute of Physics and Chemistry
Chinese Academy of Sciences
GnuPG DSA: 0xD108493
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ:        http://curl.haxx.se/docs/faq.html
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2015-05-07