On Tue, 16 Mar 2021 11:20:12 +0100
Petr Machata [off-list ref] wrote:
quoted hunk ↗ jump to hunk
Add a helper to dump a timeval. Print by first converting to double and
then dispatching to print_color_float().
Signed-off-by: Petr Machata <petrm@nvidia.com>
---
include/json_print.h | 1 +
lib/json_print.c | 13 +++++++++++++
2 files changed, 14 insertions(+)
diff --git a/include/json_print.h b/include/json_print.h
index 6fcf9fd910ec..63eee3823fe4 100644
--- a/include/json_print.h
+++ b/include/json_print.h
@@ -81,6 +81,7 @@ _PRINT_FUNC(0xhex, unsigned long long)
_PRINT_FUNC(luint, unsigned long)
_PRINT_FUNC(lluint, unsigned long long)
_PRINT_FUNC(float, double)
+_PRINT_FUNC(tv, struct timeval *)
This
Make it const please?