From b408fe77f792650ef569f9852165759f960fd52f Mon Sep 17 00:00:00 2001 From: Michael Lutz Date: Sun, 6 Dec 2020 21:11:50 +0100 Subject: Codechange: Use std::string in file scanners. --- src/ai/ai_scanner.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/ai') diff --git a/src/ai/ai_scanner.cpp b/src/ai/ai_scanner.cpp index 1431a2820..9b3613712 100644 --- a/src/ai/ai_scanner.cpp +++ b/src/ai/ai_scanner.cpp @@ -32,8 +32,7 @@ void AIScannerInfo::Initialize() ScriptAllocatorScope alloc_scope(this->engine); /* Create the dummy AI */ - free(this->main_script); - this->main_script = stredup("%_dummy"); + this->main_script = "%_dummy"; extern void Script_CreateDummyInfo(HSQUIRRELVM vm, const char *type, const char *dir); Script_CreateDummyInfo(this->engine->GetVM(), "AI", "ai"); } -- cgit v1.2.3-70-g09d2