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

Chen Gang S
2015-01-09T10:46:25Z

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.

Thanks.
--
Chen Gang

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