From b471c905a4db9261bb0c768d8f2ce4c9f6b14da2 Mon Sep 17 00:00:00 2001 From: Mirko Bonadei Date: Wed, 18 Jul 2018 14:11:27 +0200 Subject: [PATCH] Enabling clang::find_bad_constructs for modules/pacing. This CL removes //build/config/clang:find_bad_constructs from the suppressed_configs list, which means that clang:find_bad_constructs is now enabled on these translation units. Bug: webrtc:9251, webrtc:163 Change-Id: I118156a4f9b00d8c4c4f199a5af50c494e31c34a Reviewed-on: https://webrtc-review.googlesource.com/89343 Reviewed-by: Stefan Holmer Commit-Queue: Mirko Bonadei Cr-Commit-Position: refs/heads/master@{#24020} --- modules/pacing/BUILD.gn | 15 --------------- modules/pacing/bitrate_prober.cc | 2 ++ modules/pacing/bitrate_prober.h | 1 + modules/pacing/round_robin_packet_queue.cc | 1 + modules/pacing/round_robin_packet_queue.h | 1 + 5 files changed, 5 insertions(+), 15 deletions(-) diff --git a/modules/pacing/BUILD.gn b/modules/pacing/BUILD.gn index 3083b3f1e8..f035c7fff6 100644 --- a/modules/pacing/BUILD.gn +++ b/modules/pacing/BUILD.gn @@ -25,11 +25,6 @@ rtc_static_library("pacing") { "round_robin_packet_queue.h", ] - if (!build_with_chromium && is_clang) { - # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). - suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] - } - deps = [ ":interval_budget", "..:module_api", @@ -60,11 +55,6 @@ rtc_source_set("interval_budget") { "interval_budget.h", ] - if (!build_with_chromium && is_clang) { - # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). - suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] - } - deps = [ # "../../:typedefs", "../../:webrtc_common", @@ -99,11 +89,6 @@ if (rtc_include_tests) { "../rtp_rtcp:mock_rtp_rtcp", "../rtp_rtcp:rtp_rtcp_format", ] - - if (!build_with_chromium && is_clang) { - # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). - suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] - } } rtc_source_set("mock_paced_sender") { diff --git a/modules/pacing/bitrate_prober.cc b/modules/pacing/bitrate_prober.cc index 2ad4524640..cbf1d2b97e 100644 --- a/modules/pacing/bitrate_prober.cc +++ b/modules/pacing/bitrate_prober.cc @@ -47,6 +47,8 @@ constexpr int64_t kProbeClusterTimeoutMs = 5000; BitrateProber::BitrateProber() : BitrateProber(nullptr) {} +BitrateProber::~BitrateProber() = default; + BitrateProber::BitrateProber(RtcEventLog* event_log) : probing_state_(ProbingState::kDisabled), next_probe_time_ms_(-1), diff --git a/modules/pacing/bitrate_prober.h b/modules/pacing/bitrate_prober.h index abef732245..816eb0df19 100644 --- a/modules/pacing/bitrate_prober.h +++ b/modules/pacing/bitrate_prober.h @@ -25,6 +25,7 @@ class BitrateProber { public: BitrateProber(); explicit BitrateProber(RtcEventLog* event_log); + ~BitrateProber(); void SetEnabled(bool enable); diff --git a/modules/pacing/round_robin_packet_queue.cc b/modules/pacing/round_robin_packet_queue.cc index 80f9ea799c..2a16b4b50b 100644 --- a/modules/pacing/round_robin_packet_queue.cc +++ b/modules/pacing/round_robin_packet_queue.cc @@ -18,6 +18,7 @@ namespace webrtc { RoundRobinPacketQueue::Stream::Stream() : bytes(0) {} +RoundRobinPacketQueue::Stream::Stream(const Stream& stream) = default; RoundRobinPacketQueue::Stream::~Stream() {} RoundRobinPacketQueue::RoundRobinPacketQueue(const Clock* clock) diff --git a/modules/pacing/round_robin_packet_queue.h b/modules/pacing/round_robin_packet_queue.h index 8351b8040e..5dd68cd0ec 100644 --- a/modules/pacing/round_robin_packet_queue.h +++ b/modules/pacing/round_robin_packet_queue.h @@ -59,6 +59,7 @@ class RoundRobinPacketQueue : public PacketQueueInterface { struct Stream { Stream(); + Stream(const Stream&); virtual ~Stream();