From bd21d504d29099c021a0262f99079b5f9845a761 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 23 Mar 2016 21:28:58 +0300 Subject: Remove some extra checks from mapreader. --- src/resources/mapreader.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/resources/mapreader.cpp b/src/resources/mapreader.cpp index 73317fcba..482ba032c 100644 --- a/src/resources/mapreader.cpp +++ b/src/resources/mapreader.cpp @@ -478,7 +478,7 @@ void MapReader::readProperties(const XmlNodePtrConst node, Properties *const props) { BLOCK_START("MapReader::readProperties") - if (!node || !props) + if (!node) { BLOCK_END("MapReader::readProperties") return; @@ -933,7 +933,7 @@ Tileset *MapReader::readTileset(XmlNodePtr node, Map *const map) { BLOCK_START("MapReader::readTileset") - if (!map || !node) + if (!node) { BLOCK_END("MapReader::readTileset") return nullptr; @@ -1126,8 +1126,6 @@ Map *MapReader::createEmptyMap(const std::string &restrict filename, void MapReader::updateMusic(Map *const map) { - if (!map) - return; std::string name = map->getProperty("shortName"); const size_t p = name.rfind("."); if (p != std::string::npos) -- cgit v1.2.3-70-g09d2