Index: base/trace_event/process_memory_totals_dump_provider.h |
diff --git a/base/trace_event/process_memory_totals_dump_provider.h b/base/trace_event/process_memory_totals_dump_provider.h |
index 66d4f9956dd5b9144f2352f55209a249e8742017..b443010a49a0903356d4a02c4d4b563ec3f244d5 100644 |
--- a/base/trace_event/process_memory_totals_dump_provider.h |
+++ b/base/trace_event/process_memory_totals_dump_provider.h |
@@ -5,6 +5,7 @@ |
#ifndef BASE_TRACE_EVENT_PROCESS_MEMORY_TOTALS_DUMP_PROVIDER_H_ |
#define BASE_TRACE_EVENT_PROCESS_MEMORY_TOTALS_DUMP_PROVIDER_H_ |
+#include "base/files/scoped_file.h" |
#include "base/gtest_prod_util.h" |
#include "base/memory/scoped_ptr.h" |
#include "base/memory/singleton.h" |
@@ -25,6 +26,11 @@ class BASE_EXPORT ProcessMemoryTotalsDumpProvider : public MemoryDumpProvider { |
bool OnMemoryDump(const MemoryDumpArgs& args, |
ProcessMemoryDump* pmd) override; |
+#if defined(OS_LINUX) |
+ void set_proc_status_fd(int fd) { proc_status_fd_.reset(fd); } |
+ void reset_proc_status_fd() { proc_status_fd_.reset(); } |
+#endif |
+ |
private: |
friend struct DefaultSingletonTraits<ProcessMemoryTotalsDumpProvider>; |
FRIEND_TEST_ALL_PREFIXES(ProcessMemoryTotalsDumpProviderTest, DumpRSS); |
@@ -36,6 +42,10 @@ class BASE_EXPORT ProcessMemoryTotalsDumpProvider : public MemoryDumpProvider { |
scoped_ptr<ProcessMetrics> process_metrics_; |
+#if defined(OS_LINUX) |
+ ScopedFD proc_status_fd_; |
+#endif |
+ |
DISALLOW_COPY_AND_ASSIGN(ProcessMemoryTotalsDumpProvider); |
}; |