Comment's added and fixed.
Pointer's checked for NULL before access and after memory allocations. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11499 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@ -489,7 +489,8 @@ Returns:
|
||||
//
|
||||
// now everything is ready , you can set the new file name to filebuffer
|
||||
//
|
||||
if (BufferTypeBackup != FileTypeFileBuffer || StringNoCaseCompare (&FileName, &HFileImage.FileName) != 0) {
|
||||
if ((BufferTypeBackup != FileTypeFileBuffer && FileName != NULL) ||
|
||||
(FileName != NULL && HFileImage.FileName != NULL && StringNoCaseCompare (&FileName, &HFileImage.FileName) != 0)){
|
||||
//
|
||||
// not the same
|
||||
//
|
||||
|
Reference in New Issue
Block a user