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

Side by Side Diff: chrome/browser/metrics/leak_detector/leak_detector_controller.h

Issue 2159013002: Read Chrome build ID and store it in leak reports (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Replace GNUBuildIDReader class with namespace Created 4 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_METRICS_LEAK_DETECTOR_LEAK_DETECTOR_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_METRICS_LEAK_DETECTOR_LEAK_DETECTOR_CONTROLLER_H_
6 #define CHROME_BROWSER_METRICS_LEAK_DETECTOR_LEAK_DETECTOR_CONTROLLER_H_ 6 #define CHROME_BROWSER_METRICS_LEAK_DETECTOR_LEAK_DETECTOR_CONTROLLER_H_
7 7
8 #include <stdint.h>
9
8 #include <vector> 10 #include <vector>
9 11
10 #include "base/macros.h" 12 #include "base/macros.h"
11 #include "base/threading/thread_checker.h" 13 #include "base/threading/thread_checker.h"
12 #include "components/metrics/leak_detector/leak_detector.h" 14 #include "components/metrics/leak_detector/leak_detector.h"
13 #include "components/metrics/proto/memory_leak_report.pb.h" 15 #include "components/metrics/proto/memory_leak_report.pb.h"
14 16
15 namespace metrics { 17 namespace metrics {
16 18
17 // This class initializes the LeakDetector on the browser process and registers 19 // This class initializes the LeakDetector on the browser process and registers
(...skipping 13 matching lines...) Expand all
31 33
32 private: 34 private:
33 // All leak reports received through OnLeakFound() are stored in protobuf 35 // All leak reports received through OnLeakFound() are stored in protobuf
34 // format. 36 // format.
35 std::vector<MemoryLeakReportProto> stored_reports_; 37 std::vector<MemoryLeakReportProto> stored_reports_;
36 38
37 // Contains all the parameters passed to LeakDetector. Store them in a single 39 // Contains all the parameters passed to LeakDetector. Store them in a single
38 // protobuf message instead of in separate member variables. 40 // protobuf message instead of in separate member variables.
39 const MemoryLeakReportProto::Params params_; 41 const MemoryLeakReportProto::Params params_;
40 42
43 // The build ID of the current Chrome binary.
44 std::vector<uint8_t> build_id_;
45
41 // For thread safety. 46 // For thread safety.
42 base::ThreadChecker thread_checker_; 47 base::ThreadChecker thread_checker_;
43 48
44 DISALLOW_COPY_AND_ASSIGN(LeakDetectorController); 49 DISALLOW_COPY_AND_ASSIGN(LeakDetectorController);
45 }; 50 };
46 51
47 } // namespace metrics 52 } // namespace metrics
48 53
49 #endif // CHROME_BROWSER_METRICS_LEAK_DETECTOR_LEAK_DETECTOR_CONTROLLER_H_ 54 #endif // CHROME_BROWSER_METRICS_LEAK_DETECTOR_LEAK_DETECTOR_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698