Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!umich!samsung!usc!cs.utexas.edu!tut.cis.ohio-state.edu!usenet.ins.cwru.edu!cwns1!chet From: chet@cwns1.CWRU.EDU (Chet Ramey) Newsgroups: gnu.bash.bug Subject: Re: Stuff running in subshells can be annoying Message-ID: <1990Jan10.191651.6471@usenet.ins.cwru.edu> Date: 10 Jan 90 19:16:51 GMT References: Organization: Case Western Reserve Univ. Cleveland, Ohio, (USA) Lines: 29 In article andrewt@watnow.waterloo.edu (Andrew Thomas) writes: >It seems now that stuff in `` or $() >gets run in a subshell in 1.04 where there aren't really any jobs. Is >this fixable? It's fixed now; it was broken in 1.03. First of all, stuff in `` or $() always was run in a subshell. I discovered that some bugs we were finding were caused by the fact that subshells retained the same `jobs' structure as their parent. Consider the following case: foo() { more $* } history | foo will always hang because the subshell started to process `foo' is not the parent of the jobs in the job list it inherited from its parent, and it will never get the SIGCHLD signals necessary to flush them out. It was best to simply delete the jobs that were no longer children of the subshell. Chet Ramey -- Chet Ramey Network Services Group "Help! Help! I'm being Case Western Reserve University repressed!" chet@ins.CWRU.Edu