From: Ian Jackson Date: Thu, 4 Jul 2024 11:36:58 +0000 (+0100) Subject: Make ptime take 64-bit value X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?a=commitdiff_plain;h=28cbedfa3b5e028cac975a586b16a6f1c36f5d80;p=chiark-utils.git Make ptime take 64-bit value No functional change just yet. Signed-off-by: Ian Jackson --- diff --git a/cprogs/summer.c b/cprogs/summer.c index 762b5d6..226fed1 100644 --- a/cprogs/summer.c +++ b/cprogs/summer.c @@ -33,6 +33,7 @@ #include #include #include +#include #include #include #include @@ -167,7 +168,7 @@ static void pu10(void) { printf(" %10s", "?"); } #define PTIME(stab, memb) ((stab) ? ptime((stab), (stab)->memb) : pu10()) -static void ptime(const struct stat *stab, unsigned long val) { +static void ptime(const struct stat *stab, uint64_t val) { const char *instead; if (!hidextime) goto justprint; @@ -178,7 +179,7 @@ static void ptime(const struct stat *stab, unsigned long val) { else if (S_ISFIFO(stab->st_mode)) instead= "pipe"; else { justprint: - printf(" %10lu", val); + printf(" %10" PRIu64 "", val); return; }