From 22f8095cb0a9b746a023d514bec21b03a53f809b Mon Sep 17 00:00:00 2001 From: Benau Date: Fri, 6 Apr 2018 18:03:33 +0800 Subject: [PATCH] Remove compiler warnings --- src/network/game_setup.hpp | 2 +- src/network/protocols/client_lobby.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/network/game_setup.hpp b/src/network/game_setup.hpp index f22ccf211..6fdab5ba6 100644 --- a/src/network/game_setup.hpp +++ b/src/network/game_setup.hpp @@ -150,7 +150,7 @@ public: bool isSoccerGoalTarget() const { assert(hasExtraSeverInfo()); - return (bool)m_extra_server_info; + return m_extra_server_info != 0; } // ------------------------------------------------------------------------ const std::vector& getAllTracks() const { return m_tracks; } diff --git a/src/network/protocols/client_lobby.cpp b/src/network/protocols/client_lobby.cpp index 0dc1494fd..12be5fccb 100644 --- a/src/network/protocols/client_lobby.cpp +++ b/src/network/protocols/client_lobby.cpp @@ -485,7 +485,7 @@ void ClientLobby::connectionAccepted(Event* event) core::stringw tl = _("Time limit"); core::stringw gl = _("Goals limit"); core::stringw sgt = u_data == 0 ? tl : gl; - m_game_setup->setSoccerGoalTarget((bool)u_data); + m_game_setup->setSoccerGoalTarget(u_data != 0); //I18N: In the networking lobby each_line = _("Soccer game type: %s", sgt); NetworkingLobby::getInstance()->addMoreServerInfo(each_line);