summaryrefslogtreecommitdiff
path: root/src/net/ea/loginhandler.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-06-06 23:34:34 +0300
committerAndrei Karas <akaras@inbox.ru>2017-06-07 19:23:40 +0300
commit36ba43d6ea38062b17f7e63ef659962bfc51c64d (patch)
tree190156cb88b13a38a6d13c69ee0742cc078065a1 /src/net/ea/loginhandler.cpp
parentf1518dd8476c968a43fa57cfb06198e290a4f77a (diff)
downloadplus-36ba43d6ea38062b17f7e63ef659962bfc51c64d.tar.gz
plus-36ba43d6ea38062b17f7e63ef659962bfc51c64d.tar.bz2
plus-36ba43d6ea38062b17f7e63ef659962bfc51c64d.tar.xz
plus-36ba43d6ea38062b17f7e63ef659962bfc51c64d.zip
Fix clang-tidy check readability-implicit-bool-cast.
Diffstat (limited to 'src/net/ea/loginhandler.cpp')
-rw-r--r--src/net/ea/loginhandler.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/net/ea/loginhandler.cpp b/src/net/ea/loginhandler.cpp
index 68b45ecc8..0596e9952 100644
--- a/src/net/ea/loginhandler.cpp
+++ b/src/net/ea/loginhandler.cpp
@@ -66,7 +66,7 @@ void LoginHandler::getRegistrationDetails() const
void LoginHandler::loginAccount(LoginData *const loginData1) const
{
- if (loginData1)
+ if (loginData1 != nullptr)
{
loginData1->resetCharacterSlots();
sendLoginRegister(loginData1->username, loginData1->password, "");
@@ -77,13 +77,13 @@ void LoginHandler::chooseServer(const unsigned int server,
const bool persistentIp) const
{
if (CAST_SIZE(server) >= LoginRecv::mWorlds.size() ||
- !LoginRecv::mWorlds[server])
+ (LoginRecv::mWorlds[server] == nullptr))
{
return;
}
ServerInfo *const charServer = getCharServer();
- if (charServer)
+ if (charServer != nullptr)
{
if (config.getBoolValue("usePersistentIP") || persistentIp)
{
@@ -102,7 +102,7 @@ void LoginHandler::chooseServer(const unsigned int server,
void LoginHandler::registerAccount(const LoginData *const loginData1) const
{
- if (!loginData1)
+ if (loginData1 == nullptr)
return;
std::string username = loginData1->username;
@@ -138,7 +138,7 @@ void LoginHandler::clearWorlds() const
void LoginHandler::loginOrRegister(LoginData *const data) const
{
- if (!data)
+ if (data == nullptr)
return;
logger->log("Username is %s", data->username.c_str());