[lss] fix format string for time offset

This commit is contained in:
Timothy Stack 2021-04-02 09:05:03 -07:00
parent 0658b9ef57
commit 73a4df61e3
2 changed files with 6 additions and 6 deletions

View File

@ -58,7 +58,7 @@
#include "ghc/filesystem.hpp"
#if SIZEOF_OFF_T == 8
#define FORMAT_OFF_T "%qd"
#define FORMAT_OFF_T "%lld"
#elif SIZEOF_OFF_T == 4
#define FORMAT_OFF_T "%ld"
#else

View File

@ -830,11 +830,11 @@ size_t duration2str(int64_t millis, std::string &value_out)
const char *format;
const char *symbol;
} intervals[] = {
{ 1000, "%03qd%s", "" },
{ 60, "%qd%s", "s" },
{ 60, "%qd%s", "m" },
{ 24, "%qd%s", "h" },
{ 0, "%qd%s", "d" },
{ 1000, "%03lld%s", "" },
{ 60, "%lld%s", "s" },
{ 60, "%lld%s", "m" },
{ 24, "%lld%s", "h" },
{ 0, "%lld%s", "d" },
};
struct rel_interval *curr_interval = intervals;