From 15e7f5c48e4e2747223d04445902fc13f23bd956 Mon Sep 17 00:00:00 2001 From: yinsimei Date: Sat, 1 Jul 2017 22:01:47 +0200 Subject: SLUDGE: fix unmatched delete [] --- engines/sludge/objtypes.cpp | 4 ++-- engines/sludge/sludger.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'engines/sludge') diff --git a/engines/sludge/objtypes.cpp b/engines/sludge/objtypes.cpp index ffd2c83a8b..8b660fc593 100644 --- a/engines/sludge/objtypes.cpp +++ b/engines/sludge/objtypes.cpp @@ -166,8 +166,8 @@ void removeObjectType(objectType *oT) { // fclose (debuggy2); *huntRegion = oT->next; - delete oT->allCombis; - delete oT->screenName; + delete []oT->allCombis; + delete []oT->screenName; delete oT; return; } else { diff --git a/engines/sludge/sludger.cpp b/engines/sludge/sludger.cpp index cc30de2031..c9005e3ff6 100644 --- a/engines/sludge/sludger.cpp +++ b/engines/sludge/sludger.cpp @@ -546,7 +546,7 @@ bool initSludge(const char *filename) { if (chdir(dataFolder)) return fatal("This game's data folder is inaccessible!\nI can't access the following directory (maybe there's a file with the same name, or maybe it's read-protected):", dataFolder); #endif - delete dataFolder; + delete []dataFolder; } positionStatus(10, winHeight - 15); -- cgit v1.2.3