]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/C/VfrCompile/VfrUtilityLib.cpp
BaseTool/VfrCompile: make delete[] match with new[]
[mirror_edk2.git] / BaseTools / Source / C / VfrCompile / VfrUtilityLib.cpp
index c536498d771ec9852ece0a74dbb505c8e9bc6db1..9bdc54462c0c8d24b4b905aaf8a518c7325672cf 100644 (file)
@@ -2,7 +2,7 @@
   \r
   Vfr common library functions.\r
 \r
-Copyright (c) 2004 - 2017, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>\r
 This program and the accompanying materials                          \r
 are licensed and made available under the terms and conditions of the BSD License         \r
 which accompanies this distribution.  The full text of the license may be found at        \r
@@ -360,7 +360,7 @@ CVfrBufferConfig::Write (
 \r
   case 'i' : // set info\r
     if (mItemListPos->mId != NULL) {\r
-      delete mItemListPos->mId;\r
+      delete[] mItemListPos->mId;\r
     }\r
     mItemListPos->mId = NULL;\r
     if (Id != NULL) {\r
@@ -1630,7 +1630,7 @@ SVfrVarStorageNode::~SVfrVarStorageNode (
   }\r
 \r
   if (mVarStoreType == EFI_VFR_VARSTORE_NAME) {\r
-    delete mStorageInfo.mNameSpace.mNameTable;\r
+    delete[] mStorageInfo.mNameSpace.mNameTable;\r
   }\r
 }\r
 \r
@@ -3489,7 +3489,7 @@ CVfrStringDB::CVfrStringDB ()
 CVfrStringDB::~CVfrStringDB ()\r
 {\r
   if (mStringFileName != NULL) {\r
-    delete mStringFileName;\r
+    delete[] mStringFileName;\r
   }\r
   mStringFileName = NULL;\r
 }\r