Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-14 Thread Gao, Liming
Reviewed-by: Liming Gao >-Original Message- >From: Zhu, Yonghong >Sent: Monday, August 07, 2017 12:00 PM >To: edk2-devel@lists.01.org >Cc: Gao, Liming ; Kinney, Michael D >; Andrew Fish >Subject:

Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-11 Thread Andrew Fish
; >} > >return RETURN_SUCCESS; > } >} > > Thanks > Liming >> -Original Message- >> From: af...@apple.com [mailto:af...@apple.com] >> Sent: Friday, August 11, 2017 1:08 PM >> To: Gao, Liming <liming....@in

Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-10 Thread Gao, Liming
m: af...@apple.com [mailto:af...@apple.com] >Sent: Friday, August 11, 2017 1:08 PM >To: Gao, Liming <liming@intel.com> >Cc: Kinney, Michael D <michael.d.kin...@intel.com>; edk2- >de...@lists.01.org >Subject: Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when buil

Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-10 Thread Andrew Fish
59 AM > To: Gao, Liming <liming@intel.com> > Cc: Zhu, Yonghong <yonghong@intel.com>; Kinney, Michael D > <michael.d.kin...@intel.com>; edk2-devel@lists.01.org > Subject: Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build > AppPkg with XC

Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-10 Thread Gao, Liming
sts.01.org Subject: Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5 On Aug 10, 2017, at 3:38 AM, Gao, Liming <liming@intel.com<mailto:liming@intel.com>> wrote: Andrew: If this is a mtoc bug, I suggest to update GenFw to always correct

Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-10 Thread Andrew Fish
> On Aug 10, 2017, at 3:38 AM, Gao, Liming wrote: > > Andrew: > If this is a mtoc bug, I suggest to update GenFw to always correct it in the > generated EFI image. If so, the EFI image is always correct. There is no > change requirement in PeCoff library in MdePkg. >

Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-10 Thread Gao, Liming
Andrew: If this is a mtoc bug, I suggest to update GenFw to always correct it in the generated EFI image. If so, the EFI image is always correct. There is no change requirement in PeCoff library in MdePkg. Thanks Liming From: af...@apple.com [mailto:af...@apple.com] Sent: Tuesday, August 8,

Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-07 Thread Zhu, Yonghong
When push this GenFw fix, I will update the Agreement to 1.1. I also help to send out PeCoff lib 's patch. Best Regards, Zhu Yonghong From: af...@apple.com [mailto:af...@apple.com] Sent: Tuesday, August 8, 2017 12:26 AM To: Zhu, Yonghong Cc: edk2-devel@lists.01.org; Gao,

Re: [edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-07 Thread Andrew Fish
Should that be: Contributed-under: TianoCore Contribution Agreement 1.1 I also noticed the PeCoff lib is going to loop and reload the .debug suction due to this mtoc bug, so it would be good to harden that code too. git diff MdePkg/Library/BasePeCoffLib/BasePeCoff.c diff --git

[edk2] [Patch] BaseTools: Fix Segmentation fault: 11 when build AppPkg with XCODE5

2017-08-06 Thread Yonghong Zhu
it is a bug in mtoc setting the size of the debug directory entry to the size of the .debug section, not the size of the EFI_IMAGE_DEBUG_DIRECTORY_ENTRY. It was causing a loop to iterate and get bogus EFI_IMAGE_DEBUG_DIRECTORY_ENTRY data and pass that to memset() and boom. Cc: Liming Gao