]> git.proxmox.com Git - mirror_edk2.git/commitdiff
BaseTools/GenFw: Update to handle PE image with .code section only
authorYonghong Zhu <yonghong.zhu@intel.com>
Thu, 14 Apr 2016 02:04:55 +0000 (10:04 +0800)
committerYonghong Zhu <yonghong.zhu@intel.com>
Fri, 15 Apr 2016 00:43:12 +0000 (08:43 +0800)
current GenFw rebase the image which only has .code section, but no other
section, the tool return error. this patch fix this bug to support it.

Cc: Liming Gao <liming.gao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
BaseTools/Source/C/GenFw/GenFw.c

index 9ddd18e294a0503523bd8aaa5ee8ac5f44c0057b..4a91df5d220e261ffbae2d950d36386b2f46715a 100644 (file)
@@ -893,13 +893,6 @@ Returns:
     }\r
   }\r
 \r
-  //\r
-  // No available section header is found.\r
-  //\r
-  if (Index == ImgHdr->Pe32.FileHeader.NumberOfSections) {\r
-    return EFI_NOT_FOUND;\r
-  }\r
-  \r
   //\r
   // BaseAddress is set to section header.\r
   //\r