commit | a118863218ca3b986bea50e5ecbe09851a9f2bda | [log] [tgz] |
---|---|---|
author | Jean-Philippe Gravel <jpgravel@chromium.org> | Wed May 28 18:59:25 2025 |
committer | Chromium LUCI CQ <chromium-scoped@luci-project-accounts.iam.gserviceaccount.com> | Wed May 28 18:59:25 2025 |
tree | b6ae178ada68c60ec0ef4a82d20db594c9e1d54c | |
parent | 7c5e63c418cbdc6feacdd98509a13cb3fd521b77 [diff] |
Remove global kFeatureAndParams vector in hang_watcher_unittest.cc The Google C++ style guide forbids the use of complex (non-POD) global variables [1]. kFeatureAndParams should therefore not be declared in the global scope. kFeatureAndParams was doing two things: it was enabling the feature kEnableHangWatcher and it was setting ui_thread_log_level=2. This now the default log level when InitializeOnMainThread is called with emit_crashes=true. Thus, we don't need to set ui_thread_log_level in the unit test. We can now simply enable the feature from the test fixtures. [1] https://google.github.io/styleguide/cppguide.html#Static_and_Global_Variables Change-Id: I0b91e1f7b374a31aa0476bc59b2db5ab2c1f539d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6587071 Commit-Queue: Jean-Philippe Gravel <jpgravel@chromium.org> Reviewed-by: Olivier Li <olivierli@chromium.org> Cr-Commit-Position: refs/heads/main@{#1466640}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
To check out the source code locally, don't use git clone
! Instead, follow the instructions on how to get the code.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure.
For historical reasons, there are some small top level directories. Now the guidance is that new top level directories are for product (e.g. Chrome, Android WebView, Ash). Even if these products have multiple executables, the code should be in subdirectories of the product.
If you found a bug, please file it at https://crbug.com/new.