Before called by GetBufferForValue(), Value has already been called
function IsTypeInBuffer to make sure the value must be buffer type.
So GetBufferForValue can not return NULL.
This commit adds ASSERT to assume (GetBufferForValue (&Value) is not
NULL.
Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Hao A Wu <hao.a.wu@intel.com>
Signed-off-by: Shenglei Zhang <shenglei.zhang@intel.com>
Reviewed-by: Dandan Bi <dandan.bi@intel.com>
Result->Type = EFI_IFR_TYPE_UNDEFINED;\r
return EFI_SUCCESS;\r
}\r
+\r
+ ASSERT (GetBufferForValue (&Value) != NULL);\r
Result->Value.u64 = *(UINT64*) GetBufferForValue (&Value);\r
+\r
if (Value.Type == EFI_IFR_TYPE_BUFFER) {\r
FreePool (Value.Buffer);\r
}\r