Files
ports/sysutils/lnav/patches/patch-src_command_executor_cc
sthen 43f9c6b70c sysutils/lnav tweaks:
- fix printf format strings and add casts for 64-bit time_t, ok tb
- fix sscanf for 64-bit time_t, following a suggestion from tb
- set word size/byte-order for sparc64, possibly unbreaking build there
2025-01-29 16:00:27 +00:00

17 lines
793 B
Plaintext

Index: src/command_executor.cc
--- src/command_executor.cc.orig
+++ src/command_executor.cc
@@ -509,10 +509,10 @@ execute_sql(exec_context& ec, const std::string& sql,
snprintf(row_count_buf,
sizeof(row_count_buf),
ANSI_BOLD("%'d") " row%s matched in " ANSI_BOLD(
- "%ld.%03ld") " seconds",
+ "%lld.%03ld") " seconds",
row_count,
row_count == 1 ? "" : "s",
- diff_tv.tv_sec,
+ (long long)diff_tv.tv_sec,
std::max((long) diff_tv.tv_usec / 1000, 1L));
retval = row_count_buf;
if (dls.has_log_time_column()) {