From 919fa1c88bcfc2db16410afb084b338540e91c4f Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Sun, 7 Aug 2011 20:17:50 -0400 Subject: use proper suffixes for package sizes --- expac.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/expac.c b/expac.c index b14124a..09053e7 100644 --- a/expac.c +++ b/expac.c @@ -28,7 +28,7 @@ #include #include #include -#include +/* #include */ #include #include #include @@ -42,6 +42,10 @@ #define FORMAT_TOKENS_SYNC "fk" #define ESCAPE_TOKENS "\"\\abefnrtv" +#ifndef PATH_MAX +#define PATH_MAX 4096 +#endif + static char const digits[] = "0123456789"; static char const printf_flags[] = "'-+ #0I"; @@ -435,10 +439,10 @@ static int print_pkg(pmpkg_t *pkg, const char *format) { /* sizes */ case 'k': /* download size */ - out += printf("%.2f K", (float)alpm_pkg_get_size(pkg) / 1024.0); + out += printf("%.2f KiB", (float)alpm_pkg_get_size(pkg) / 1024.0); break; case 'm': /* install size */ - out += printf("%.2f K", (float)alpm_pkg_get_isize(pkg) / 1024.0); + out += printf("%.2f KiB", (float)alpm_pkg_get_isize(pkg) / 1024.0); break; /* lists */ -- cgit v1.2.3-70-g09d2