From 51817f6e59e420536901e3225091894ea6ad1b25 Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Sat, 11 Jul 2020 21:42:56 -0300 Subject: core/network: Add network abstraction This commit adds a network abstraction designed to implement bsd:s but at the same time work as a generic abstraction to implement any networking code we have to use from core. This is implemented on top of BSD sockets on Unix systems and winsock on Windows. The code is designed around winsocks having compatibility definitions to support both BSD and Windows sockets. --- src/core/core.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/core/core.cpp') diff --git a/src/core/core.cpp b/src/core/core.cpp index 69a1aa0a5..e598c0e2b 100644 --- a/src/core/core.cpp +++ b/src/core/core.cpp @@ -43,6 +43,7 @@ #include "core/loader/loader.h" #include "core/memory.h" #include "core/memory/cheat_engine.h" +#include "core/network/network.h" #include "core/perf_stats.h" #include "core/reporter.h" #include "core/settings.h" @@ -394,6 +395,9 @@ struct System::Impl { /// Telemetry session for this emulation session std::unique_ptr telemetry_session; + /// Network instance + Network::NetworkInstance network_instance; + ResultStatus status = ResultStatus::Success; std::string status_details = ""; -- cgit v1.2.3