Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Unified Diff: webrtc/base/physicalsocketserver.cc

Issue 1891293002: Adds clearer function to create rtc::Thread without Physical SocketServer (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/base/nullsocketserver.cc ('k') | webrtc/base/socketserver.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/physicalsocketserver.cc
diff --git a/webrtc/base/physicalsocketserver.cc b/webrtc/base/physicalsocketserver.cc
index 708499df531f076af2210137c0eb2ed4795c6bab..e2a0b6f14048b4007126ce9a13838f1858fbc1f8 100644
--- a/webrtc/base/physicalsocketserver.cc
+++ b/webrtc/base/physicalsocketserver.cc
@@ -46,6 +46,7 @@
#include "webrtc/base/common.h"
#include "webrtc/base/logging.h"
#include "webrtc/base/networkmonitor.h"
+#include "webrtc/base/nullsocketserver.h"
#include "webrtc/base/timeutils.h"
#include "webrtc/base/winping.h"
#include "webrtc/base/win32socketinit.h"
@@ -62,6 +63,14 @@ typedef char* SockOptArg;
namespace rtc {
+std::unique_ptr<SocketServer> SocketServer::CreateDefault() {
+#if defined(__native_client__)
+ return std::unique_ptr<SocketServer>(new rtc::NullSocketServer);
+#else
+ return std::unique_ptr<SocketServer>(new rtc::PhysicalSocketServer);
+#endif
+}
+
#if defined(WEBRTC_WIN)
// Standard MTUs, from RFC 1191
const uint16_t PACKET_MAXIMUMS[] = {
« no previous file with comments | « webrtc/base/nullsocketserver.cc ('k') | webrtc/base/socketserver.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698