]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/C/VfrCompile/VfrError.cpp
BaseTools/VfrCompile: Explicitly state format string for DebugMsg()
[mirror_edk2.git] / BaseTools / Source / C / VfrCompile / VfrError.cpp
index ffed732a4171274773fc8ba5c7cedbf554d9f2be..285e175fa60fc2bc26c637b949ea6078a37c5dee 100644 (file)
@@ -2,7 +2,7 @@
   \r
   VfrCompiler error handler.\r
 \r
-Copyright (c) 2004 - 2013, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2004 - 2016, 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
@@ -52,6 +52,8 @@ static SVFR_ERROR_HANDLE VFR_ERROR_HANDLE_TABLE [] = {
 static SVFR_WARNING_HANDLE VFR_WARNING_HANDLE_TABLE [] = {\r
   { VFR_WARNING_DEFAULT_VALUE_REDEFINED, ": default value re-defined with different value"},\r
   { VFR_WARNING_STRING_TO_UINT_OVERFLOW, ": String to UINT* Overflow"},\r
+  { VFR_WARNING_ACTION_WITH_TEXT_TWO, ": Action opcode should not have TextTwo part"},\r
+  { VFR_WARNING_OBSOLETED_FRAMEWORK_OPCODE, ": Not recommend to use obsoleted framework opcode"},\r
   { VFR_WARNING_CODEUNDEFINED, ": undefined Warning Code" }\r
 };\r
 \r
@@ -143,7 +145,7 @@ SVfrFileScopeRecord::~SVfrFileScopeRecord (
   )\r
 {\r
   if (mFileName != NULL) {\r
-    delete mFileName;\r
+    delete[] mFileName;\r
   }\r
 }\r
 \r
@@ -278,7 +280,7 @@ CVfrErrorHandle::HandleWarning (
   GetFileNameLineNum (LineNum, &FileName, &FileLine);\r
 \r
   if (mWarningAsError) {\r
-    Error (FileName, FileLine, 0x2220, "warning treated as error", NULL);\r
+    Error (FileName, FileLine, 0x2220, (CHAR8 *) "warning treated as error", NULL);\r
   }\r
 \r
   for (Index = 0; mVfrWarningHandleTable[Index].mWarningCode != VFR_WARNING_CODEUNDEFINED; Index++) {\r