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

Unified Diff: third_party/tcmalloc/chromium/src/deep-heap-profile.cc

Issue 129683002: Fix a couple of gcc 4.8 warnings in tcmalloc. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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
Index: third_party/tcmalloc/chromium/src/deep-heap-profile.cc
diff --git a/third_party/tcmalloc/chromium/src/deep-heap-profile.cc b/third_party/tcmalloc/chromium/src/deep-heap-profile.cc
index b27f1aa68bee7cd795db7ea0f36aa4db3a5c1abc..5a1392acdc4eeae1fb509d7bcd82d397b32a1478 100644
--- a/third_party/tcmalloc/chromium/src/deep-heap-profile.cc
+++ b/third_party/tcmalloc/chromium/src/deep-heap-profile.cc
@@ -127,8 +127,7 @@ void DeepHeapProfile::MemoryInfoGetterLinux::Initialize() {
RAW_CHECK(pagemap_fd_ != -1, "Failed to open /proc/self/pagemap");
if (pageframe_type_ == DUMP_PAGECOUNT) {
- snprintf(filename, sizeof(filename), "/proc/kpagecount",
- static_cast<int>(getpid()));
jar (doing other things) 2014/01/29 02:33:12 This looks like a bug. How about fixing it with a
Dai Mikurube (NOT FULLTIME) 2014/01/29 03:24:13 Ah, yes. It's my bug. Thanks for working on it, Sa
+ snprintf(filename, sizeof(filename), "/proc/kpagecount");
kpagecount_fd_ = open(filename, O_RDONLY);
if (kpagecount_fd_ == -1)
RAW_LOG(0, "Failed to open /proc/kpagecount");

Powered by Google App Engine
This is Rietveld 408576698