Re: [Patch] Fix build problem with system call in compile/compile.c

Chen Gang S
2015-01-09T21:53:44Z

On 1/10/15 04:59, Chen Gang S wrote:
> On 1/9/15 18:50, Chen Gang S wrote:
>> On 1/9/15 18:10, Pedro Alves wrote:
>>> On 01/09/2015 03:54 AM, Chen Gang S wrote:
>>>>
>>>> Excuse me, I guess, I can not check in, welcome any other members help to
>>>> check in for me.
>>> I was going to apply it as is, but I recalled that the return
>>> of "system" is really a 'wait' status:
>>>
>>>> + if (system (zap))
>>>> + warning (_("Could not remove temporary directory %s"), dir);
>>>
>>> so I tweaked the patch accordingly, and pushed it, as below.
>> [...]
>>> - system (zap);
>>> + wstat = system (zap);
>>> + if (wstat == -1 || !WIFEXITED (wstat) || WEXITSTATUS (wstat) != 0)
>>> + warning (_("Could not remove temporary directory %s"), dir);
>>
>> Oh, really it is. Thanks.
>>
>
> Excuse me, I am not quite familiar with the patch apply working flow for
> binutils/gdb, it seems each patch can only have one 'Signed-of-by' for
> it (do not like Linux kernel or QEMU, can have multiple 'Signed-of-by').
>
> For me, this patch need multiple 'Signed-of-by': I start the patch, and
> Pedro Alves give a very necessary improvement (or it will introduce a
> new bug, which is not recognized quite obviously by others).
>
> If what I said above is correct, one way maybe, apply my original patch
> firstly, then apply the fix patch by Pedro Alves. I am not quite sure
> whether this way is suitable or not, though.
>

Oh, the patch is already applied with 2 appliers :-)

Thanks.
--
Chen Gang

Open, share, and attitude like air, water, and life which God blessed