Blame 0004-cgtop-use-PRIu64-to-print-uint64_t-5544.patch
|
Michal Sekletar |
f5f073 |
From fe9d0ba1f8e60fbea433f75319d0487e5b58c79b Mon Sep 17 00:00:00 2001
|
|
Michal Sekletar |
f5f073 |
From: "Thomas H. P. Andersen" <phomes@gmail.com>
|
|
Michal Sekletar |
f5f073 |
Date: Tue, 7 Mar 2017 07:47:18 +0100
|
|
Michal Sekletar |
f5f073 |
Subject: [PATCH] cgtop: use PRIu64 to print uint64_t (#5544)
|
|
Michal Sekletar |
f5f073 |
|
|
Michal Sekletar |
f5f073 |
Commit 59f448cf replaced usage of off_t with uint64_t. Change the
|
|
Michal Sekletar |
f5f073 |
format string to use PRIu64 to match it.
|
|
Michal Sekletar |
f5f073 |
(cherry picked from commit 557e36934d21b08acafbe2baf6ebfde761fbae25)
|
|
Michal Sekletar |
f5f073 |
---
|
|
Michal Sekletar |
f5f073 |
src/cgtop/cgtop.c | 2 +-
|
|
Michal Sekletar |
f5f073 |
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
Michal Sekletar |
f5f073 |
|
|
Michal Sekletar |
f5f073 |
diff --git a/src/cgtop/cgtop.c b/src/cgtop/cgtop.c
|
|
Michal Sekletar |
f5f073 |
index a1c0f48..67f3a99 100644
|
|
Michal Sekletar |
f5f073 |
--- a/src/cgtop/cgtop.c
|
|
Michal Sekletar |
f5f073 |
+++ b/src/cgtop/cgtop.c
|
|
Michal Sekletar |
f5f073 |
@@ -118,7 +118,7 @@ static const char *maybe_format_bytes(char *buf, size_t l, bool is_valid, uint64
|
|
Michal Sekletar |
f5f073 |
if (!is_valid)
|
|
Michal Sekletar |
f5f073 |
return "-";
|
|
Michal Sekletar |
f5f073 |
if (arg_raw) {
|
|
Michal Sekletar |
f5f073 |
- snprintf(buf, l, "%jd", t);
|
|
Michal Sekletar |
f5f073 |
+ snprintf(buf, l, "%" PRIu64, t);
|
|
Michal Sekletar |
f5f073 |
return buf;
|
|
Michal Sekletar |
f5f073 |
}
|
|
Michal Sekletar |
f5f073 |
return format_bytes(buf, l, t);
|
|
Michal Sekletar |
f5f073 |
--
|
|
Michal Sekletar |
f5f073 |
2.9.3
|
|
Michal Sekletar |
f5f073 |
|