summaryrefslogtreecommitdiffhomepage
path: root/StarsEx/ShipDesign.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'StarsEx/ShipDesign.cpp')
-rw-r--r--StarsEx/ShipDesign.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/StarsEx/ShipDesign.cpp b/StarsEx/ShipDesign.cpp
index 9b4be4c..3fb11f3 100644
--- a/StarsEx/ShipDesign.cpp
+++ b/StarsEx/ShipDesign.cpp
@@ -264,7 +264,7 @@ bolt_hit_sound_resource(0), beam_hit_sound_resource(0), lod_levels(0)
return;
}
- Parser parser(new BlockReader((const char*) block, blocklen));
+ Parser parser({reinterpret_cast<const char*>(block), blocklen});
Term* term = parser.ParseTerm();
if (!term) {
@@ -527,7 +527,7 @@ void AddModCatalogEntry(const char* design_name, const char* design_path)
return;
}
- Parser parser(new BlockReader((const char*) block, blocklen));
+ Parser parser({reinterpret_cast<const char*>(block), blocklen});
Term* term = parser.ParseTerm();
if (!term) {
@@ -665,7 +665,7 @@ ShipDesign::LoadCatalog(const char* path, const char* fname, bool mod)
BYTE* block;
int blocklen = loader->LoadBuffer(filename, block, true);
- Parser parser(new BlockReader((const char*) block, blocklen));
+ Parser parser({reinterpret_cast<const char*>(block), blocklen});
Term* term = parser.ParseTerm();
if (!term) {
@@ -771,7 +771,7 @@ ShipDesign::LoadSkins(const char* path, int source)
continue;
}
- Parser parser(new BlockReader((const char*) block, blocklen));
+ Parser parser({reinterpret_cast<const char*>(block), blocklen});
Term* term = parser.ParseTerm();
ShipDesign* design = 0;