From 055ac37e8a0153514ae1a014b7bf8cecd3344473 Mon Sep 17 00:00:00 2001 From: Thulinma Date: Mon, 29 Apr 2019 09:58:02 +0200 Subject: [PATCH] Added PRETTY_PRINT_MSTIME and PRETTY_ARG_MSTIME for printing millisecond-based time information --- lib/defines.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/defines.h b/lib/defines.h index a59c7266..194dc821 100644 --- a/lib/defines.h +++ b/lib/defines.h @@ -16,6 +16,8 @@ #define DLVL_DONTEVEN 10 // All messages enabled, even pointless ones. #define PRETTY_PRINT_TIME "%ud%uh%um%us" #define PRETTY_ARG_TIME(t) (int)(t)/86400, ((int)(t)%86400)/3600, ((int)(t)%3600)/60, (int)(t)%60 +#define PRETTY_PRINT_MSTIME "%ud%.2uh%.2um%.2us.%.3u" +#define PRETTY_ARG_MSTIME(t) PRETTY_ARG_TIME(t/1000), (int)(t%1000) #if DEBUG > -1 #define __STDC_FORMAT_MACROS 1