diff --git a/src/Main/fg_init.cxx b/src/Main/fg_init.cxx index c662f6285..f9e2ed2ba 100644 --- a/src/Main/fg_init.cxx +++ b/src/Main/fg_init.cxx @@ -660,12 +660,6 @@ int fgInitConfig ( int argc, char **argv, bool reinit ) static SimLogFileLine simLogFileLine; -#ifdef ENABLE_SWIFT - //Set standard settings for swift connection - fgSetString("/sim/swift/adress","127.0.0.1"); - fgSetString("/sim/swift/port","45003"); -#endif - // Read global defaults from $FG_ROOT/defaults SG_LOG(SG_GENERAL, SG_DEBUG, "Reading global defaults"); SGPath defaultsXML = globals->get_fg_root() / "defaults.xml"; diff --git a/src/Network/Swift/plugin.cpp b/src/Network/Swift/plugin.cpp index 15a8ec6be..c87db6258 100644 --- a/src/Network/Swift/plugin.cpp +++ b/src/Network/Swift/plugin.cpp @@ -59,8 +59,8 @@ void CPlugin::startServer() m_traffic.reset(new CTraffic()); m_dbusP2PServer.reset(new CDBusServer()); - std::string ip = fgGetString("/sim/swift/adress"); - std::string port = fgGetString("/sim/swift/port"); + std::string ip = fgGetString("/sim/swift/adress", "127.0.0.1"); + std::string port = fgGetString("/sim/swift/port", "45003"); std::string listenAddress = "tcp:host=" + ip + ",port=" + port; if (! m_dbusP2PServer->listen(listenAddress)) {