aboutsummaryrefslogtreecommitdiff
path: root/utils/bonnie++/patches/101-fix-wrong-printf-off_t-format.patch
blob: a912089518edcabb9d3142752ce2d52fd6f00467 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
From 4f4d854b7758da89ced4dc800fcbec11667d61c8 Mon Sep 17 00:00:00 2001
From: Rosen Penev <rosenp@gmail.com>
Date: Mon, 22 Feb 2021 16:05:54 -0800
Subject: [PATCH] fix wrong printf off_t format

It's long vs. long long. There's a macro for this.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
 port.h | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

--- a/port.h
+++ b/port.h
@@ -3,14 +3,13 @@
 
 #include "conf.h"
 
-
-
+#include <inttypes.h>
 
 #ifndef _LARGEFILE64_SOURCE
 #define _LARGEFILE64_SOURCE
 #endif
 #ifdef _LARGEFILE64_SOURCE
-#define OFF_T_PRINTF "%lld"
+#define OFF_T_PRINTF "%" PRId64
 #else
 #define OFF_T_PRINTF "%d"
 #endif