mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-15 23:20:36 +01:00
Core/Vmaps: Minor cleanup in vmap4assembler - use unique_ptr to manage file handles
This commit is contained in:
@@ -49,16 +49,14 @@ int main(int argc, char* argv[])
|
||||
|
||||
std::cout << "using " << src << " as source directory and writing output to " << dest << std::endl;
|
||||
|
||||
VMAP::TileAssembler* ta = new VMAP::TileAssembler(src, dest);
|
||||
VMAP::TileAssembler ta(std::move(src), std::move(dest));
|
||||
|
||||
if (!ta->convertWorld2())
|
||||
if (!ta.convertWorld2())
|
||||
{
|
||||
std::cout << "exit with errors" << std::endl;
|
||||
delete ta;
|
||||
return 1;
|
||||
}
|
||||
|
||||
delete ta;
|
||||
std::cout << "Ok, all done" << std::endl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user