[swift] Transfer connection settings to defaults.xml
Related to commit d0cb2f on fgdata
This commit is contained in:
parent
54f660764e
commit
265d721bab
2 changed files with 2 additions and 8 deletions
|
@ -660,12 +660,6 @@ int fgInitConfig ( int argc, char **argv, bool reinit )
|
||||||
|
|
||||||
static SimLogFileLine simLogFileLine;
|
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
|
// Read global defaults from $FG_ROOT/defaults
|
||||||
SG_LOG(SG_GENERAL, SG_DEBUG, "Reading global defaults");
|
SG_LOG(SG_GENERAL, SG_DEBUG, "Reading global defaults");
|
||||||
SGPath defaultsXML = globals->get_fg_root() / "defaults.xml";
|
SGPath defaultsXML = globals->get_fg_root() / "defaults.xml";
|
||||||
|
|
|
@ -59,8 +59,8 @@ void CPlugin::startServer()
|
||||||
m_traffic.reset(new CTraffic());
|
m_traffic.reset(new CTraffic());
|
||||||
m_dbusP2PServer.reset(new CDBusServer());
|
m_dbusP2PServer.reset(new CDBusServer());
|
||||||
|
|
||||||
std::string ip = fgGetString("/sim/swift/adress");
|
std::string ip = fgGetString("/sim/swift/adress", "127.0.0.1");
|
||||||
std::string port = fgGetString("/sim/swift/port");
|
std::string port = fgGetString("/sim/swift/port", "45003");
|
||||||
std::string listenAddress = "tcp:host=" + ip + ",port=" + port;
|
std::string listenAddress = "tcp:host=" + ip + ",port=" + port;
|
||||||
if (! m_dbusP2PServer->listen(listenAddress))
|
if (! m_dbusP2PServer->listen(listenAddress))
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Reference in a new issue