diff --git a/src/tools/map_replace_area.cpp b/src/tools/map_replace_area.cpp index 5be50c080..477a4b89f 100644 --- a/src/tools/map_replace_area.cpp +++ b/src/tools/map_replace_area.cpp @@ -102,13 +102,13 @@ bool OpenMaps(IStorage *pStorage, const char pMapNames[3][64], CDataFileReader I } } - if(!OutputMap.Open(pStorage, pMapNames[2], IStorage::TYPE_ABSOLUTE)) - { - dbg_msg("map_replace_area", "Error: unable to open map '%s'", pMapNames[2]); - return false; - } - - return true; + if(!OutputMap.Open(pStorage, pMapNames[2], IStorage::TYPE_ABSOLUTE)) + { + dbg_msg("map_replace_area", "Error: unable to open map '%s'", pMapNames[2]); + return false; + } + + return true; } bool CompareLayers(const char pMapNames[3][64], CDataFileReader InputMaps[2]) @@ -271,4 +271,4 @@ void SaveOutputMap(CDataFileReader InputMaps[2], CDataFileWriter& OutputMap) } OutputMap.Finish(); -} \ No newline at end of file +}