1 /* 2 * Copyright 2020 The WebRTC Project Authors. All rights reserved. 3 * 4 * Use of this source code is governed by a BSD-style license 5 * that can be found in the LICENSE file in the root of the source 6 * tree. An additional intellectual property rights grant can be found 7 * in the file PATENTS. All contributing project authors may 8 * be found in the AUTHORS file in the root of the source tree. 9 */ 10 11 #include "rtc_base/internal/default_socket_server.h" 12 13 #include <memory> 14 15 #include "rtc_base/socket_server.h" 16 17 #if defined(__native_client__) 18 #include "rtc_base/null_socket_server.h" 19 #else 20 #include "rtc_base/physical_socket_server.h" 21 #endif 22 23 namespace rtc { 24 CreateDefaultSocketServer()25std::unique_ptr<SocketServer> CreateDefaultSocketServer() { 26 #if defined(__native_client__) 27 return std::unique_ptr<SocketServer>(new rtc::NullSocketServer); 28 #else 29 return std::unique_ptr<SocketServer>(new rtc::PhysicalSocketServer); 30 #endif 31 } 32 33 } // namespace rtc 34