Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(735)

Unified Diff: ui/gfx/range/range.cc

Issue 1948283002: Fix gfx::Range::ToString() to use the correct format specifier. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add sstream header. Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ui/gfx/range/range_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/range/range.cc
diff --git a/ui/gfx/range/range.cc b/ui/gfx/range/range.cc
index a6475cba2ec8a01ea144bf1c425772ad2420491b..230403aa292bdfc23605090ed9a4567781e28675 100644
--- a/ui/gfx/range/range.cc
+++ b/ui/gfx/range/range.cc
@@ -4,6 +4,8 @@
#include "ui/gfx/range/range.h"
+#include <inttypes.h>
+
#include <algorithm>
#include <limits>
@@ -77,7 +79,7 @@ Range Range::Intersect(const Range& range) const {
}
std::string Range::ToString() const {
- return base::StringPrintf("{%d,%d}", start(), end());
+ return base::StringPrintf("{%" PRIu32 ",%" PRIu32 "}", start(), end());
}
std::ostream& operator<<(std::ostream& os, const Range& range) {
« no previous file with comments | « no previous file | ui/gfx/range/range_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698