1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-27 22:49:25 +02:00

Fixed gcc/clang warnings

This commit is contained in:
Ivan Savenko
2015-12-04 01:06:02 +02:00
parent c2f4991e99
commit faa7cbff18
13 changed files with 41 additions and 33 deletions

View File

@@ -20,7 +20,7 @@ std::unique_ptr<CMap> CMapService::loadMap(const std::string & name)
getMapPatcher(name)->patchMapHeader(header);
header.release();
return std::move(map);
return map;
}
std::unique_ptr<CMapHeader> CMapService::loadMapHeader(const std::string & name)
@@ -28,7 +28,7 @@ std::unique_ptr<CMapHeader> CMapService::loadMapHeader(const std::string & name)
auto stream = getStreamFromFS(name);
std::unique_ptr<CMapHeader> header = getMapLoader(stream)->loadMapHeader();
getMapPatcher(name)->patchMapHeader(header);
return std::move(header);
return header;
}
std::unique_ptr<CMap> CMapService::loadMap(const ui8 * buffer, int size, const std::string & name)
@@ -40,7 +40,7 @@ std::unique_ptr<CMap> CMapService::loadMap(const ui8 * buffer, int size, const s
getMapPatcher(name)->patchMapHeader(header);
header.release();
return std::move(map);
return map;
}
std::unique_ptr<CMapHeader> CMapService::loadMapHeader(const ui8 * buffer, int size, const std::string & name)
@@ -48,7 +48,7 @@ std::unique_ptr<CMapHeader> CMapService::loadMapHeader(const ui8 * buffer, int s
auto stream = getStreamFromMem(buffer, size);
std::unique_ptr<CMapHeader> header = getMapLoader(stream)->loadMapHeader();
getMapPatcher(name)->patchMapHeader(header);
return std::move(header);
return header;
}
std::unique_ptr<CInputStream> CMapService::getStreamFromFS(const std::string & name)