MdeModulePkg: loose VA_COPY with no matching VA_END on a return path
authorZenith432 <zenith432@users.sourceforge.net>
Sat, 9 Dec 2017 17:04:38 +0000 (01:04 +0800)
committerStar Zeng <star.zeng@intel.com>
Mon, 11 Dec 2017 01:07:40 +0000 (09:07 +0800)
In CheckRemainingSpaceForConsistencyInternal, one of the return paths leaves a loose
VA_COPY with no matching VA_END.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Zenith432 <zenith432@users.sourceforge.net>
Reviewed-by: Star Zeng <star.zeng@intel.com>
MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c

index f39be6b..969df95 100644 (file)
@@ -1765,6 +1765,7 @@ CheckRemainingSpaceForConsistencyInternal (
       //\r
       // No enough space for Variable[Index].\r
       //\r
+      VA_END (Args);\r
       return FALSE;\r
     }\r
     //\r