From 069ef2445ddf4f8ab1392f8e559ef258b315e92d Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 22 May 2018 19:18:19 +0300 Subject: Add configure option for enable/disable accepting password from command line. --- src/progs/manaplus/client.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/progs') diff --git a/src/progs/manaplus/client.cpp b/src/progs/manaplus/client.cpp index 1ee563bac..22d2bc483 100644 --- a/src/progs/manaplus/client.cpp +++ b/src/progs/manaplus/client.cpp @@ -301,6 +301,14 @@ void Client::gameInit() Dirs::initRootDir(); Dirs::initHomeDir(); +#ifndef ENABLE_COMMANDLINEPASSWORD + if (!settings.options.password.empty()) + { + settings.options.password = std::string(); + logger->log("Command line password parameter disabled."); + } +#endif + // Configure logger if (!settings.options.logFileName.empty()) { -- cgit v1.2.3-70-g09d2