commit e14c3ecdd66cf32afa4b1848ac708cb0b744fa28 parent a8df7413aca37c2371b775f6c1d189bf4b6c44c3 Author: Michael Froman <mfroman@mozilla.com> Date: Thu, 9 Oct 2025 13:09:34 -0500 Bug 1993083 - Vendor libwebrtc from 4b2c2fc299 Upstream commit: https://webrtc.googlesource.com/src/+/4b2c2fc2996eea646fbc1adfac12580d2fa1e705 restore and fix async_tcp_socket_unittest which went missing at some point Bug: None Change-Id: I4d8b85e7a82cba0a7337da4f9cb4aecf929f7250 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/399700 Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> Commit-Queue: Philipp Hancke <phancke@meta.com> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#45132} Diffstat:
19 files changed, 58 insertions(+), 42 deletions(-)
diff --git a/third_party/libwebrtc/BUILD.gn b/third_party/libwebrtc/BUILD.gn @@ -721,6 +721,7 @@ if (rtc_include_tests && !build_with_chromium) { "call:fake_network_pipe_unittests", "rtc_base:async_dns_resolver_unittests", "rtc_base:async_packet_socket_unittest", + "rtc_base:async_tcp_socket_unittest", "rtc_base:async_udp_socket_unittest", "rtc_base:callback_list_unittests", "rtc_base:rtc_base_approved_unittests", 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 /home/mfroman/mozilla/elm/.moz-fast-forward/moz-libwebrtc --commit mozpatches libwebrtc -libwebrtc updated from /home/mfroman/mozilla/elm/.moz-fast-forward/moz-libwebrtc commit mozpatches on 2025-10-09T18:08:08.046225+00:00. +libwebrtc updated from /home/mfroman/mozilla/elm/.moz-fast-forward/moz-libwebrtc commit mozpatches on 2025-10-09T18:09:26.930693+00:00. # base of lastest vendoring -59489f589b +4b2c2fc299 diff --git a/third_party/libwebrtc/moz-patch-stack/s0001.patch b/third_party/libwebrtc/moz-patch-stack/s0001.patch @@ -1383,7 +1383,7 @@ index d5ce6105a3..8bfd24de2b 100644 const bool enable_svc_for_simulcast_; std::optional<SimulcastToSvcConverter> simulcast_to_svc_converter_; diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn -index 6e903964a6..97f4bb2289 100644 +index 00bda50b1b..a0bf02c014 100644 --- a/rtc_base/BUILD.gn +++ b/rtc_base/BUILD.gn @@ -450,6 +450,12 @@ rtc_library("logging") { diff --git a/third_party/libwebrtc/moz-patch-stack/s0027.patch b/third_party/libwebrtc/moz-patch-stack/s0027.patch @@ -116,7 +116,7 @@ index 1b112b34c0..18cf5d67f7 100644 # TODO(https://bugs.webrtc.org/14437): Remove this section if general # Chromium fix resolves the problem. diff --git a/BUILD.gn b/BUILD.gn -index a57c4e9497..de4c4b174c 100644 +index ef4a7d286f..b064aac57b 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -33,7 +33,7 @@ if (is_android) { @@ -1013,7 +1013,7 @@ index 39aa39a41c..b26e30e8bb 100644 "/config/external/nspr", "/nsprpub/lib/ds", diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn -index 97f4bb2289..e9240a6ba0 100644 +index a0bf02c014..4a24d15362 100644 --- a/rtc_base/BUILD.gn +++ b/rtc_base/BUILD.gn @@ -326,6 +326,7 @@ rtc_library("sample_counter") { @@ -1128,7 +1128,7 @@ index 97f4bb2289..e9240a6ba0 100644 if (rtc_include_tests) { rtc_library("async_packet_socket_unittest") { -@@ -1417,6 +1435,7 @@ rtc_library("data_rate_limiter") { +@@ -1429,6 +1447,7 @@ rtc_library("data_rate_limiter") { } rtc_library("unique_id_generator") { @@ -1136,7 +1136,7 @@ index 97f4bb2289..e9240a6ba0 100644 sources = [ "unique_id_generator.cc", "unique_id_generator.h", -@@ -1434,6 +1453,7 @@ rtc_library("unique_id_generator") { +@@ -1446,6 +1465,7 @@ rtc_library("unique_id_generator") { "//third_party/abseil-cpp/absl/strings:string_view", ] } @@ -1144,7 +1144,7 @@ index 97f4bb2289..e9240a6ba0 100644 rtc_library("crc32") { sources = [ -@@ -1465,6 +1485,7 @@ rtc_library("stream") { +@@ -1477,6 +1497,7 @@ rtc_library("stream") { } rtc_library("rtc_certificate_generator") { @@ -1152,7 +1152,7 @@ index 97f4bb2289..e9240a6ba0 100644 visibility = [ "*" ] sources = [ "rtc_certificate_generator.cc", -@@ -1479,6 +1500,7 @@ rtc_library("rtc_certificate_generator") { +@@ -1491,6 +1512,7 @@ rtc_library("rtc_certificate_generator") { "//third_party/abseil-cpp/absl/functional:any_invocable", ] } @@ -1160,7 +1160,7 @@ index 97f4bb2289..e9240a6ba0 100644 rtc_source_set("ssl_header") { visibility = [ "*" ] -@@ -1535,6 +1557,7 @@ rtc_library("crypto_random") { +@@ -1547,6 +1569,7 @@ rtc_library("crypto_random") { } rtc_library("ssl") { @@ -1168,7 +1168,7 @@ index 97f4bb2289..e9240a6ba0 100644 visibility = [ "*" ] sources = [ "openssl_key_pair.cc", -@@ -1607,6 +1630,7 @@ rtc_library("ssl") { +@@ -1619,6 +1642,7 @@ rtc_library("ssl") { deps += [ ":win32" ] } } @@ -1176,7 +1176,7 @@ index 97f4bb2289..e9240a6ba0 100644 rtc_library("ssl_adapter") { visibility = [ "*" ] -@@ -2329,7 +2353,7 @@ if (rtc_include_tests) { +@@ -2341,7 +2365,7 @@ if (rtc_include_tests) { } } diff --git a/third_party/libwebrtc/moz-patch-stack/s0034.patch b/third_party/libwebrtc/moz-patch-stack/s0034.patch @@ -20,7 +20,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/58f47eacaf10d12e2 11 files changed, 27 insertions(+), 27 deletions(-) diff --git a/BUILD.gn b/BUILD.gn -index de4c4b174c..c967019b11 100644 +index b064aac57b..37b07eca5d 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -440,12 +440,12 @@ config("common_config") { diff --git a/third_party/libwebrtc/moz-patch-stack/s0045.patch b/third_party/libwebrtc/moz-patch-stack/s0045.patch @@ -18,7 +18,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/0300b32b7de70fb89 5 files changed, 10 insertions(+), 3 deletions(-) diff --git a/BUILD.gn b/BUILD.gn -index c967019b11..bd66288681 100644 +index 37b07eca5d..e90dd95b23 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -224,6 +224,9 @@ config("common_inherited_config") { diff --git a/third_party/libwebrtc/moz-patch-stack/s0053.patch b/third_party/libwebrtc/moz-patch-stack/s0053.patch @@ -29,7 +29,7 @@ index 7db75d5fd3..d0feb5007c 100644 rtc_library("task_queue_test") { visibility = [ "*" ] diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn -index e9240a6ba0..14d4b43f5d 100644 +index 4a24d15362..dafb1ef7d9 100644 --- a/rtc_base/BUILD.gn +++ b/rtc_base/BUILD.gn @@ -665,10 +665,14 @@ if (is_mac || is_ios) { diff --git a/third_party/libwebrtc/moz-patch-stack/s0055.patch b/third_party/libwebrtc/moz-patch-stack/s0055.patch @@ -11,7 +11,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/b0658888969395dca 2 files changed, 10 insertions(+) diff --git a/BUILD.gn b/BUILD.gn -index bd66288681..3dca573133 100644 +index e90dd95b23..40063088f2 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -624,6 +624,10 @@ if (!build_with_chromium) { diff --git a/third_party/libwebrtc/moz-patch-stack/s0084.patch b/third_party/libwebrtc/moz-patch-stack/s0084.patch @@ -11,7 +11,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/2185cab977988fd4a 3 files changed, 16 insertions(+) diff --git a/BUILD.gn b/BUILD.gn -index 3dca573133..b3497c121e 100644 +index 40063088f2..30762563a5 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -609,6 +609,7 @@ if (!build_with_chromium) { diff --git a/third_party/libwebrtc/moz-patch-stack/s0091.patch b/third_party/libwebrtc/moz-patch-stack/s0091.patch @@ -13,7 +13,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/4e7b3c485e549e7e3 1 file changed, 6 insertions(+) diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn -index 14d4b43f5d..0f341c91e2 100644 +index dafb1ef7d9..3bb1a5e383 100644 --- a/rtc_base/BUILD.gn +++ b/rtc_base/BUILD.gn @@ -992,6 +992,12 @@ rtc_library("threading") { diff --git a/third_party/libwebrtc/moz-patch-stack/s0093.patch b/third_party/libwebrtc/moz-patch-stack/s0093.patch @@ -10,7 +10,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/b050c455caa1d24a0 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/BUILD.gn b/BUILD.gn -index b3497c121e..396f850586 100644 +index 30762563a5..cf7548754f 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -280,6 +280,7 @@ config("rtc_prod_config") { diff --git a/third_party/libwebrtc/moz-patch-stack/s0094.patch b/third_party/libwebrtc/moz-patch-stack/s0094.patch @@ -9,10 +9,10 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/ee2f06666bcc6d22c 1 file changed, 2 insertions(+) diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn -index 0f341c91e2..57818dce97 100644 +index 3bb1a5e383..17cfaad615 100644 --- a/rtc_base/BUILD.gn +++ b/rtc_base/BUILD.gn -@@ -1643,6 +1643,7 @@ if (!build_with_mozilla) { +@@ -1655,6 +1655,7 @@ if (!build_with_mozilla) { } rtc_library("ssl_adapter") { @@ -20,7 +20,7 @@ index 0f341c91e2..57818dce97 100644 visibility = [ "*" ] sources = [ "openssl_adapter.cc", -@@ -1691,6 +1692,7 @@ rtc_library("ssl_adapter") { +@@ -1703,6 +1704,7 @@ rtc_library("ssl_adapter") { configs += [ "..:external_ssl_library" ] } } diff --git a/third_party/libwebrtc/moz-patch-stack/s0103.patch b/third_party/libwebrtc/moz-patch-stack/s0103.patch @@ -75,7 +75,7 @@ index cdbd705ec2..4ee826ec58 100644 # The python interpreter to use by default. On Windows, this will look # for vpython3.exe and vpython3.bat. diff --git a/BUILD.gn b/BUILD.gn -index 396f850586..5f268214e8 100644 +index cf7548754f..2e0fd6721d 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -21,15 +21,15 @@ @@ -107,7 +107,7 @@ index 396f850586..5f268214e8 100644 defines = [] deps = [ -@@ -851,7 +851,7 @@ rtc_static_library("dcsctp") { +@@ -852,7 +852,7 @@ rtc_static_library("dcsctp") { visibility = [ "//:default" ] sources = [] complete_static_lib = true @@ -116,7 +116,7 @@ index 396f850586..5f268214e8 100644 defines = [] deps = [ "net/dcsctp/public:factory", -@@ -886,7 +886,7 @@ group("poison_software_video_codecs") { +@@ -887,7 +887,7 @@ group("poison_software_video_codecs") { if (!build_with_chromium) { # Write debug logs to gn_logs.txt. # This is also required for Siso builds. @@ -616,7 +616,7 @@ index 605b9bb84a..278e312c85 100644 if (rtc_build_libsrtp) { diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn -index 57818dce97..6a36625b00 100644 +index 17cfaad615..c41565c1b8 100644 --- a/rtc_base/BUILD.gn +++ b/rtc_base/BUILD.gn @@ -9,8 +9,8 @@ @@ -630,7 +630,7 @@ index 57818dce97..6a36625b00 100644 } rtc_source_set("protobuf_utils") { -@@ -1882,8 +1882,8 @@ if (!rtc_rusty_base64) { +@@ -1894,8 +1894,8 @@ if (!rtc_rusty_base64) { ] } } else { diff --git a/third_party/libwebrtc/moz-patch-stack/s0106.patch b/third_party/libwebrtc/moz-patch-stack/s0106.patch @@ -9,7 +9,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/90a33b06e51017d25 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/BUILD.gn b/BUILD.gn -index 5f268214e8..4e67c43d65 100644 +index 2e0fd6721d..1107653026 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -565,6 +565,7 @@ if (!build_with_chromium) { @@ -20,7 +20,7 @@ index 5f268214e8..4e67c43d65 100644 "logging:rtc_event_log_api", "media", "modules", -@@ -848,7 +849,7 @@ if (rtc_include_tests && !build_with_chromium) { +@@ -849,7 +850,7 @@ if (rtc_include_tests && !build_with_chromium) { # Build target for standalone dcsctp rtc_static_library("dcsctp") { # Only the root target should depend on this. diff --git a/third_party/libwebrtc/moz-patch-stack/s0108.patch b/third_party/libwebrtc/moz-patch-stack/s0108.patch @@ -16,7 +16,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/4527c41ef71d7683c 4 files changed, 24 insertions(+), 12 deletions(-) diff --git a/BUILD.gn b/BUILD.gn -index 4e67c43d65..c2866618aa 100644 +index 1107653026..2bc18e49cf 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -521,6 +521,9 @@ if (!rtc_build_ssl) { @@ -116,10 +116,10 @@ index 6f2dc22e00..e3ee0fe861 100644 public_configs = [] if (!build_with_chromium) { diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn -index 6a36625b00..a6fa96e1d5 100644 +index c41565c1b8..36908c4288 100644 --- a/rtc_base/BUILD.gn +++ b/rtc_base/BUILD.gn -@@ -1522,6 +1522,7 @@ rtc_source_set("ssl_header") { +@@ -1534,6 +1534,7 @@ rtc_source_set("ssl_header") { } rtc_library("digest") { @@ -127,7 +127,7 @@ index 6a36625b00..a6fa96e1d5 100644 visibility = [ "*" ] sources = [ "message_digest.cc", -@@ -1543,8 +1544,10 @@ rtc_library("digest") { +@@ -1555,8 +1556,10 @@ rtc_library("digest") { configs += [ "..:external_ssl_library" ] } } @@ -138,7 +138,7 @@ index 6a36625b00..a6fa96e1d5 100644 visibility = [ "*" ] sources = [ "crypto_random.cc", -@@ -1565,6 +1568,7 @@ rtc_library("crypto_random") { +@@ -1577,6 +1580,7 @@ rtc_library("crypto_random") { configs += [ "..:external_ssl_library" ] } } diff --git a/third_party/libwebrtc/moz-patch-stack/s0112.patch b/third_party/libwebrtc/moz-patch-stack/s0112.patch @@ -10,7 +10,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/27c29807e6f46562d 1 file changed, 1 insertion(+) diff --git a/BUILD.gn b/BUILD.gn -index c2866618aa..ddf7260445 100644 +index 2bc18e49cf..fefa6366b0 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -615,6 +615,7 @@ if (!build_with_chromium) { diff --git a/third_party/libwebrtc/moz-patch-stack/s0129.patch b/third_party/libwebrtc/moz-patch-stack/s0129.patch @@ -9,7 +9,7 @@ Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/43de54a6e52daf0a0 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/BUILD.gn b/BUILD.gn -index ddf7260445..4a96ff7ae1 100644 +index fefa6366b0..df35ecc6f5 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -315,6 +315,17 @@ config("common_config") { diff --git a/third_party/libwebrtc/rtc_base/BUILD.gn b/third_party/libwebrtc/rtc_base/BUILD.gn @@ -1376,7 +1376,6 @@ if (!build_with_mozilla) { if (rtc_include_tests) { rtc_library("async_packet_socket_unittest") { testonly = true - visibility = [ "*" ] sources = [ "async_packet_socket_unittest.cc" ] deps = [ ":async_packet_socket", @@ -1391,7 +1390,6 @@ if (rtc_include_tests) { rtc_library("async_udp_socket_unittest") { testonly = true - visibility = [ "*" ] sources = [ "async_udp_socket_unittest.cc" ] deps = [ ":async_packet_socket", @@ -1406,6 +1404,20 @@ if (rtc_include_tests) { "//third_party/abseil-cpp/absl/memory", ] } + rtc_library("async_tcp_socket_unittest") { + testonly = true + sources = [ "async_tcp_socket_unittest.cc" ] + deps = [ + ":async_packet_socket", + ":async_tcp_socket", + ":gunit_helpers", + ":net_helpers", + ":rtc_base_tests_utils", + ":socket", + "../test:test_support", + "third_party/sigslot", + ] + } } rtc_library("mdns_responder_interface") { diff --git a/third_party/libwebrtc/rtc_base/async_tcp_socket_unittest.cc b/third_party/libwebrtc/rtc_base/async_tcp_socket_unittest.cc @@ -11,10 +11,13 @@ #include "rtc_base/async_tcp_socket.h" #include <memory> -#include <string> -#include "rtc_base/gunit.h" +#include "rtc_base/async_packet_socket.h" +#include "rtc_base/net_helpers.h" +#include "rtc_base/socket.h" +#include "rtc_base/third_party/sigslot/sigslot.h" #include "rtc_base/virtual_socket_server.h" +#include "test/gtest.h" namespace webrtc { @@ -22,8 +25,8 @@ class AsyncTCPSocketTest : public ::testing::Test, public sigslot::has_slots<> { public: AsyncTCPSocketTest() : vss_(new VirtualSocketServer()), - socket_(vss_->CreateSocket(SOCK_STREAM)), - tcp_socket_(new AsyncTCPSocket(socket_, true)), + socket_(vss_->CreateSocket(AF_INET, SOCK_STREAM)), + tcp_socket_(new AsyncTCPSocket(socket_)), ready_to_send_(false) { tcp_socket_->SignalReadyToSend.connect(this, &AsyncTCPSocketTest::OnReadyToSend);