From 52363b43277aa250498d9f86e035fa070a917b67 Mon Sep 17 00:00:00 2001 From: Aaron Griffin Date: Tue, 24 Oct 2006 04:46:07 +0000 Subject: Attempted fix for x86_64 - switched some unsigned char variables to ints, and prefixed sync_fnm with the length when outputting - waiting for verification --- src/pacman/download.c | 6 +++--- src/pacman/download.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/pacman/download.c b/src/pacman/download.c index 2b0ad096..1b28cccf 100644 --- a/src/pacman/download.c +++ b/src/pacman/download.c @@ -45,7 +45,7 @@ int offset; struct timeval t0, t; float rate; int xfered1; -unsigned char eta_h, eta_m, eta_s; +unsigned int eta_h, eta_m, eta_s; /* pacman options */ extern config_t *config; @@ -105,9 +105,9 @@ int log_progress(netbuf *ctl, int xfered, void *arg) } if(rate > 1000) { - printf("%s %6dK %6.0fK/s %02d:%02d:%02d [", sync_fnm, ((xfered+offset) / 1024), rate, eta_h, eta_m, eta_s); + printf("%*s %6dK %6.0fK/s %02d:%02d:%02d [", PM_DLFNM_LEN, sync_fnm, ((xfered+offset) / 1024), rate, eta_h, eta_m, eta_s); } else { - printf("%s %6dK %6.1fK/s %02d:%02d:%02d [", sync_fnm, ((xfered+offset) / 1024), rate, eta_h, eta_m, eta_s); + printf("%*s %6dK %6.1fK/s %02d:%02d:%02d [", PM_DLFNM_LEN, sync_fnm, ((xfered+offset) / 1024), rate, eta_h, eta_m, eta_s); } cur = (int)((maxcols-57)*pct/100); for(i = 0; i < maxcols-57; i++) { diff --git a/src/pacman/download.h b/src/pacman/download.h index fb65a4c0..80364f9c 100644 --- a/src/pacman/download.h +++ b/src/pacman/download.h @@ -26,7 +26,7 @@ extern int offset; extern struct timeval t0, t; extern float rate; extern int xfered1; -extern unsigned char eta_h, eta_m, eta_s; +extern unsigned int eta_h, eta_m, eta_s; #ifdef __FTPLIB_H int log_progress(netbuf *ctl, int xfered, void *arg); -- cgit v1.2.3-24-g4f1b