]> git.proxmox.com Git - mirror_edk2.git/commit
MdeModulePkg/EbcDebugger: Add ASSERT to ensure FieldBuffer is not NULL
authorHao Wu <hao.a.wu@intel.com>
Thu, 24 Nov 2016 02:43:33 +0000 (10:43 +0800)
committerHao Wu <hao.a.wu@intel.com>
Fri, 25 Nov 2016 05:34:24 +0000 (13:34 +0800)
commiteebfb7b2a52629f7c7268a9f5417ea86477c38eb
tree4acb43c1872841efbfe54332a4e65138f1154381
parenta8a624d0a45d506f3ac1eab883226cb1cfa71bf6
MdeModulePkg/EbcDebugger: Add ASSERT to ensure FieldBuffer is not NULL

In function EdbLoadCodBySymbolByIec(), AsciiStrGetNewTokenField() at line
1589 will return NULL if the first character in 'LineBuffer' is '\0'. But
the previous if statement at line 1576 ensures the above case will not
happen.

This commit adds ASSERT as warnings for the case that will not happen.

Cc: Jiewen Yao <jiewen.yao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Hao Wu <hao.a.wu@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbSymbol.c