commit 03f3899874a5e4a92c7682f94435775fbaf5c7ab
parent be05fd6600917c65bc649411f5f7a6068599d49f
Author: Dan Baker <dbaker@mozilla.com>
Date: Mon, 27 Oct 2025 17:31:45 -0600
Bug 1995393 - Vendor libwebrtc from bc7452c444
Upstream commit: https://webrtc.googlesource.com/src/+/bc7452c444245f7999be5711b1802e900f25540b
[M141] Do not hide inbound-rtp if media is received.
This condition neglected the fact that if Insertable Streams API is used
we can have frames or samples despite packets never being received.
This CL fixes this unintended regression.
# Ignore unrelated compile issues on ios webrtc bots
NOTRY=True
(cherry picked from commit c15949eda5a00122e2f3b5a643e15781049b9927)
Bug: chromium:444048024, chromium:444384230
Change-Id: Ie6e17a3bc96701476787f5898446f3f706715d15
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/408884
Commit-Queue: Guido Urdaneta <guidou@webrtc.org>
Reviewed-by: Guido Urdaneta <guidou@webrtc.org>
Auto-Submit: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Henrik Boström <hbos@webrtc.org>
Cr-Original-Commit-Position: refs/heads/main@{#45616}
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/409020
Cr-Commit-Position: refs/branch-heads/7390@{#2}
Cr-Branched-From: 2f553bf8d573c90176d51559b76dfc836996c8f5-refs/heads/main@{#45520}
Diffstat:
2 files changed, 10 insertions(+), 4 deletions(-)
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-27T23:29:05.612817+00:00.
+libwebrtc updated from /Users/danielbaker/elm/.moz-fast-forward/moz-libwebrtc commit mozpatches on 2025-10-27T23:31:33.809715+00:00.
# base of lastest vendoring
-71dfd3bde9
+bc7452c444
diff --git a/third_party/libwebrtc/pc/rtc_stats_collector.cc b/third_party/libwebrtc/pc/rtc_stats_collector.cc
@@ -1754,7 +1754,10 @@ void RTCStatsCollector::ProduceAudioRTPStreamStats_n(
if (!voice_receiver_info.connected()) {
continue; // The SSRC is not known yet.
}
- if (spec_lifetime && voice_receiver_info.packets_received == 0) {
+ // Check both packets received and samples received to handle the Insertable
+ // Streams use case of receiving media without receiving packets.
+ if (spec_lifetime && voice_receiver_info.packets_received == 0 &&
+ voice_receiver_info.total_samples_received == 0) {
// The SSRC is known despite not receiving any packets. This happens if
// SSRC is signalled in the SDP which we should not rely on for getStats.
continue;
@@ -1868,7 +1871,10 @@ void RTCStatsCollector::ProduceVideoRTPStreamStats_n(
if (!video_receiver_info.connected()) {
continue; // The SSRC is not known yet.
}
- if (spec_lifetime && video_receiver_info.packets_received == 0) {
+ // Check both packets received and frames received to handle the Insertable
+ // Streams use case of receiving media without receiving packets.
+ if (spec_lifetime && video_receiver_info.packets_received == 0 &&
+ video_receiver_info.frames_received == 0) {
// The SSRC is known despite not receiving any packets. This happens if
// SSRC is signalled in the SDP which we should not rely on for getStats.
continue;