diff options
author | Daniel Stenberg <daniel@haxx.se> | 2013-07-31 00:17:56 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2013-07-31 13:41:00 +0200 |
commit | 1691a31cab33ef1d6a186bd08e5f8cf7661e34c1 (patch) | |
tree | e4cf1d89822270eacfe7dca38a88c4b7664bf961 /src/tool_cb_prg.h | |
parent | 9dedcbf9ec47b436a43c1e4744921b9e620e5fe2 (diff) | |
download | curl-1691a31cab33ef1d6a186bd08e5f8cf7661e34c1.tar.gz |
curl: make --progress-bar update the line less frequently
Also, use memset() instead of a lame loop.
The previous logic that tried to avoid too many updates were very
ineffective for really fast transfers, as then it could easily end up
doing hundreds of updates per second that would make a significant
impact in transfer performance!
Bug: http://curl.haxx.se/mail/archive-2013-07/0031.html
Reported-by: Marc Doughty
Diffstat (limited to 'src/tool_cb_prg.h')
-rw-r--r-- | src/tool_cb_prg.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/tool_cb_prg.h b/src/tool_cb_prg.h index 81915b2d5..ceb85980c 100644 --- a/src/tool_cb_prg.h +++ b/src/tool_cb_prg.h @@ -7,7 +7,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2012, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2013, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -29,6 +29,7 @@ struct ProgressData { int calls; curl_off_t prev; + time_t prevtime; int width; FILE *out; /* where to write everything to */ curl_off_t initial_size; |