Date: Tue, 2 Oct 2001 22:01:52 +0100 From: David Taylor <davidt@yadt.co.uk> To: Alfred Perlstein <bright@mu.org> Cc: Peter Pentchev <roam@ringlet.net>, freebsd-hackers@FreeBSD.org Subject: Re: Doubt of system(3) Message-ID: <20011002220152.A3056@gattaca.yadt.co.uk> In-Reply-To: <20011002112707.C59854@elvis.mu.org>; from bright@mu.org on Tue, Oct 02, 2001 at 11:27:07 -0500 References: <200109291527.f8TFRrU76727.toshi@jp.FreeBSD.org> <20010929153433.U59854@elvis.mu.org> <20010929214338.A57903@gattaca.yadt.co.uk> <20010929221658.B57903@gattaca.yadt.co.uk> <20010929170332.Y59854@elvis.mu.org> <20010929232839.A91153@gattaca.yadt.co.uk> <20011002130942.C704@ringworld.oblivion.bg> <20011002112707.C59854@elvis.mu.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 02 Oct 2001, Alfred Perlstein wrote: > * Peter Pentchev <roam@ringlet.net> [011002 05:21] wrote: > > On Sat, Sep 29, 2001 at 11:28:39PM +0100, David Taylor wrote: > > [snip] > > > IMO, the below patch is probably the best solution. > > > > Yep, it also fixes the fact that the return value from wait4() needs > > to be preserved, at least for the return statement of __system(). > > Aaaaaaaaaaah! Forgot about it, I'm going to upgrade my workstation > now and commit it if it works, probably tonight. > > If someone else can test it earlier, by all means commit it. Just to say that as I did a make world today, I took the opportunity to test the patch, and it does fix the bug. (Old behaviour: davidt@gattaca:~/C/system-bug$ ./test Parent: Child A pid = 26271 Calling system... Child A: exiting Child B running - pid 26273 Child B: Sending parent (26270) SIGFPE to interrupt wait... System has returned Child B entering busy loop... Child B still running... Parent exiting - child b should have also exited... davidt@gattaca:~/C/system-bug$ Child B still running... killall test2 Terminated New behaviour: davidt@gattaca:~/C/system-bug$ ./test Parent: Child A pid = 27944 Calling system... Child A: exiting Child B running - pid 27946 Child B: Sending parent (27943) SIGFPE to interrupt wait... Child B entering busy loop... Child B still running... Child B still running... Child B still running... ^Z [1]+ Stopped ./test davidt@gattaca:~/C/system-bug$ bg [1]+ ./test & davidt@gattaca:~/C/system-bug$ Child B still running... kill 27946 Terminated System has returned Parent exiting - child b should have also exited... davidt@gattaca:~/C/system-bug$ ) However, I won't be able to commit it, since I'm not a committer :) -- David Taylor davidt@yadt.co.uk To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011002220152.A3056>