Always specify --server-password so that empty password can disable private server
This commit is contained in:
parent
93298023b4
commit
767651124a
@ -258,8 +258,8 @@ void CreateServerScreen::createServer()
|
||||
return;
|
||||
}
|
||||
|
||||
const bool private_server = !password.empty();
|
||||
ServerConfig::m_private_server_password = password;
|
||||
if (!password.empty())
|
||||
password = std::string(" --server-password=") + password;
|
||||
|
||||
TransportAddress server_address(0x7f000001,
|
||||
@ -268,7 +268,7 @@ void CreateServerScreen::createServer()
|
||||
auto server = std::make_shared<Server>(0/*server_id*/, name,
|
||||
max_players, /*current_player*/0, (RaceManager::Difficulty)
|
||||
difficulty_widget->getSelection(PLAYER_ID_GAME_MASTER),
|
||||
0, server_address, !password.empty(), false);
|
||||
0, server_address, private_server, false);
|
||||
|
||||
#undef USE_GRAPHICS_SERVER
|
||||
#ifdef USE_GRAPHICS_SERVER
|
||||
|
Loading…
Reference in New Issue
Block a user