commit 2f6dc5e233d7510d17d8d1e813b34e72b9067a0a
parent 0b872e5a809bb775ae2dee055c3729bb3c7fd430
Author: Dan Baker <dbaker@mozilla.com>
Date: Wed, 22 Oct 2025 14:35:09 -0600
Bug 1995393 - Vendor libwebrtc from cc2da72676
Upstream commit: https://webrtc.googlesource.com/src/+/cc2da7267653fabb9205b884091fcaff248b3e48
Move clang-tidy rules to dotfile
as a more centralized/canonical way of handling the rules.
Also run it again and find a tiny fix courtesy of
modernize-use-override
that regressed recently.
Bug: webrtc:424706384
Change-Id: I524b18e917e52a908a7e0596d7b4177c60954021
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/403401
Reviewed-by: Jeremy Leconte <jleconte@google.com>
Commit-Queue: Philipp Hancke <phancke@meta.com>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#45301}
Diffstat:
4 files changed, 16 insertions(+), 17 deletions(-)
diff --git a/third_party/libwebrtc/.clang-tidy b/third_party/libwebrtc/.clang-tidy
@@ -0,0 +1,9 @@
+---
+---
+ Checks: '-*,
+ llvm-namespace-comment,
+ modernize-use-override,
+ readability-static-definition-in-anonymous-namespace,
+ readability-redundant-smartptr-get,
+ readability-redundant-declaration'
+...
diff --git a/third_party/libwebrtc/README.mozilla.last-vendor b/third_party/libwebrtc/README.mozilla.last-vendor
@@ -1,4 +1,4 @@
# ./mach python dom/media/webrtc/third_party_build/vendor-libwebrtc.py --from-local /Users/danielbaker/elm/.moz-fast-forward/moz-libwebrtc --commit mozpatches libwebrtc
-libwebrtc updated from /Users/danielbaker/elm/.moz-fast-forward/moz-libwebrtc commit mozpatches on 2025-10-22T20:32:35.183575+00:00.
+libwebrtc updated from /Users/danielbaker/elm/.moz-fast-forward/moz-libwebrtc commit mozpatches on 2025-10-22T20:34:52.176808+00:00.
# base of lastest vendoring
-2de79989f5
+cc2da72676
diff --git a/third_party/libwebrtc/api/test/metrics/stdout_metrics_exporter_test.cc b/third_party/libwebrtc/api/test/metrics/stdout_metrics_exporter_test.cc
@@ -75,7 +75,7 @@ class StdoutMetricsExporterTest : public ::testing::Test {
.stats = Metric::Stats{
.mean = 30.0, .stddev = 10.0, .min = 20.0, .max = 40.0}};
}
- ~StdoutMetricsExporterTest() {
+ ~StdoutMetricsExporterTest() override {
absl::SetFlag(&FLAGS_isolated_script_test_perf_output,
original_isolated_script_test_perf_output_);
}
diff --git a/third_party/libwebrtc/tools_webrtc/apply_clang_tidy.py b/third_party/libwebrtc/tools_webrtc/apply_clang_tidy.py
@@ -9,6 +9,9 @@
# be found in the AUTHORS file in the root of the source tree.
#
# Run clang-tidy in the webrtc source directory.
+# The list of checks that is getting applied is in the toplevel
+# .clang-tidy file. To add a new check, add it to that file and run
+# the script.
#
# clang-tidy needs to be added to the .gclient file:
# Example .gclient file:
@@ -43,18 +46,6 @@ _TIDY_RUNNER = _LLVM + "clang-tools-extra/clang-tidy/tool/run-clang-tidy.py"
_TIDY_BINARY = _LLVM + "build/bin/clang-tidy"
_REPLACEMENTS_BINARY = _LLVM + "build/bin/clang-apply-replacements"
-# The list of checks that is getting applied.
-# TODO: bugs.webrtc.org/424706384 - move to .clang-tidy file.
-_CHECKS = [
- "-*", # disable all checks by default.
- "llvm-namespace-comment",
- # conflicts with IWYU.
- #"modernize-deprecated-headers",
- "readability-static-definition-in-anonymous-namespace",
- "readability-redundant-smartptr-get",
-]
-
-
def _valid_dir(path: str) -> pathlib.Path:
"""Checks if the given path is an existing dir
relative to the current working directory.
@@ -108,8 +99,7 @@ def _run_clang_tidy(work_dir: pathlib.Path) -> None:
clang_tidy_cmd = (work_dir / _TIDY_RUNNER, "-p", work_dir,
"-clang-tidy-binary", work_dir / _TIDY_BINARY,
"-clang-apply-replacements-binary",
- work_dir / _REPLACEMENTS_BINARY,
- "-checks=" + ",".join(_CHECKS), "-fix")
+ work_dir / _REPLACEMENTS_BINARY, "-fix")
subprocess.run(clang_tidy_cmd,
capture_output=False,
text=True,