X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fcommon%2Ftime.h;h=8588cf554c487912875253cd81f1631529bda38a;hp=4cfdf856c521d155fe55dd7580d5180605097119;hb=a8b66566890a353cc3a89836281541195ad69d73;hpb=a70ac2f49aa47a30abc2b50ec57b582eab4b1028 diff --git a/src/common/time.h b/src/common/time.h index 4cfdf856c..8588cf554 100644 --- a/src/common/time.h +++ b/src/common/time.h @@ -38,6 +38,7 @@ #define USEC_PER_HOURS (USEC_PER_MINUTE * MINUTE_PER_HOUR) #define ISO8601_STR_LEN sizeof("YYYYmmddTHHMMSS+HHMM") +#define DATETIME_STR_LEN sizeof("YYYYmmdd-HHMMSS") LTTNG_HIDDEN bool locale_supports_utf8(void); @@ -74,4 +75,7 @@ struct timespec timespec_abs_diff(struct timespec ts_a, struct timespec ts_b); LTTNG_HIDDEN int time_to_iso8601_str(time_t time, char *str, size_t len); +LTTNG_HIDDEN +int time_to_datetime_str(time_t time, char *str, size_t len); + #endif /* LTTNG_TIME_H */