Source code

Revision control

Copy as Markdown

Other Tools

From: Nico Grunbaum <na-g@nostrum.com>
Date: Thu, 23 May 2024 17:28:00 +0000
Subject: Bug 1897459 - P2 - for BSD reference null socket server
instead;r=mjf,webrtc-reviewers
---
rtc_base/internal/default_socket_server.cc | 4 ++--
rtc_base/virtual_socket_server.cc | 2 ++
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/rtc_base/internal/default_socket_server.cc b/rtc_base/internal/default_socket_server.cc
index 5632b989fc..cb7b81978a 100644
--- a/rtc_base/internal/default_socket_server.cc
+++ b/rtc_base/internal/default_socket_server.cc
@@ -14,7 +14,7 @@
#include "rtc_base/socket_server.h"
-#if defined(__native_client__)
+#if defined(__native_client__) || defined(WEBRTC_BSD)
#include "rtc_base/null_socket_server.h"
#else
#include "rtc_base/physical_socket_server.h"
@@ -23,7 +23,7 @@
namespace rtc {
std::unique_ptr<SocketServer> CreateDefaultSocketServer() {
-#if defined(__native_client__)
+#if defined(__native_client__) || defined(WEBRTC_BSD)
return std::unique_ptr<SocketServer>(new rtc::NullSocketServer);
#else
return std::unique_ptr<SocketServer>(new rtc::PhysicalSocketServer);
diff --git a/rtc_base/virtual_socket_server.cc b/rtc_base/virtual_socket_server.cc
index dd02281c93..37ec3e6a92 100644
--- a/rtc_base/virtual_socket_server.cc
+++ b/rtc_base/virtual_socket_server.cc
@@ -24,7 +24,9 @@
#include "rtc_base/event.h"
#include "rtc_base/fake_clock.h"
#include "rtc_base/logging.h"
+#if !defined(WEBRTC_BSD)
#include "rtc_base/physical_socket_server.h"
+#endif
#include "rtc_base/socket_address_pair.h"
#include "rtc_base/thread.h"
#include "rtc_base/time_utils.h"