This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [Patch] Fix build problem with system call in compile/compile.c
- From: Chen Gang S <gang dot chen at sunrus dot com dot cn>
- To: Pedro Alves <palves at redhat dot com>, sellcey at imgtec dot com
- Cc: Jan Kratochvil <jan dot kratochvil at redhat dot com>, "Maciej W. Rozycki" <macro at linux-mips dot org>, Joel Brobecker <brobecker at adacore dot com>, gdb-patches at sourceware dot org, Yao Qi <yao at codesourcery dot com>
- Date: Sat, 10 Jan 2015 06:00:54 +0800
- Subject: Re: [Patch] Fix build problem with system call in compile/compile.c
- Authentication-results: sourceware.org; auth=none
- References: <c2ab3326-5227-43ff-a755-35cf75e209d8 at BAMAIL02 dot ba dot imgtec dot org> <20150106041615 dot GJ5445 at adacore dot com> <1420560255 dot 15691 dot 21 dot camel at ubuntu-sellcey> <20150107041351 dot GN5445 at adacore dot com> <1420655766 dot 15691 dot 44 dot camel at ubuntu-sellcey> <alpine dot LFD dot 2 dot 11 dot 1501071858580 dot 27020 at eddie dot linux-mips dot org> <54AD8A76 dot 9010702 at redhat dot com> <alpine dot LFD dot 2 dot 11 dot 1501072330430 dot 27020 at eddie dot linux-mips dot org> <20150108211229 dot GA5634 at host2 dot jankratochvil dot net> <1420755123 dot 2630 dot 21 dot camel at ubuntu-sellcey> <54AF1118 dot 2070707 at redhat dot com> <1420762209 dot 2630 dot 27 dot camel at ubuntu-sellcey> <54AF50E4 dot 3080901 at sunrus dot com dot cn> <54AFA92C dot 8010108 at redhat dot com> <54AFB275 dot 9060803 at sunrus dot com dot cn> <54B04125 dot 4050802 at sunrus dot com dot cn>
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