summaryrefslogtreecommitdiffstats
path: root/Utilities/cmcurl/progress.c
diff options
context:
space:
mode:
Diffstat (limited to 'Utilities/cmcurl/progress.c')
-rw-r--r--Utilities/cmcurl/progress.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/Utilities/cmcurl/progress.c b/Utilities/cmcurl/progress.c
index 36be56e..5ba829a 100644
--- a/Utilities/cmcurl/progress.c
+++ b/Utilities/cmcurl/progress.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2004, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2006, 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
@@ -139,10 +139,8 @@ void Curl_pgrsDone(struct connectdata *conn)
struct SessionHandle *data = conn->data;
data->progress.lastshow=0;
Curl_pgrsUpdate(conn); /* the final (forced) update */
- if(!(data->progress.flags & PGRS_HIDE) &&
- !data->progress.callback)
- /* only output if we don't use a progress callback and we're not hidden */
- fprintf(data->set.err, "\n");
+
+ data->progress.speeder_c = 0; /* reset the progress meter display */
}
/* reset all times except redirect */
@@ -254,11 +252,11 @@ int Curl_pgrsUpdate(struct connectdata *conn)
even when not displayed! */
else if(!(data->progress.flags & PGRS_HEADERS_OUT)) {
if (!data->progress.callback) {
- if(conn->resume_from)
+ if(data->reqdata.resume_from)
fprintf(data->set.err,
"** Resuming transfer from byte position %" FORMAT_OFF_T
"\n",
- conn->resume_from);
+ data->reqdata.resume_from);
fprintf(data->set.err,
" %% Total %% Received %% Xferd Average Speed Time Time Time Current\n"
" Dload Upload Total Spent Left Speed\n");
@@ -328,7 +326,7 @@ int Curl_pgrsUpdate(struct connectdata *conn)
curl_off_t amount = data->progress.speeder[nowindex]-
data->progress.speeder[checkindex];
- if(amount > 0xffffffff/1000)
+ if(amount > 4294967 /* 0xffffffff/1000 */)
/* the 'amount' value is bigger than would fit in 32 bits if
multiplied with 1000, so we use the double math for this */
data->progress.current_speed = (curl_off_t)