Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!rutgers!sunybcs!boulder!hao!oddjob!mimsy!chris From: chris@mimsy.UUCP (Chris Torek) Newsgroups: comp.unix.questions Subject: Re: C-shell idiosyncracy ?? Message-ID: <9316@mimsy.UUCP> Date: Thu, 12-Nov-87 02:38:38 EST Article-I.D.: mimsy.9316 Posted: Thu Nov 12 02:38:38 1987 Date-Received: Sat, 14-Nov-87 16:00:09 EST References: <33414@sun.uucp> Organization: U of Maryland, Dept. of Computer Science, Coll. Pk., MD 20742 Lines: 22 In article <33414@sun.uucp> vipin%samsun@Sun.COM (Vipin Samar) writes: >{samsun} jobs >[1] + Stopped emacs foo >{samsun} jobs > bar >{samsun} cat bar >[1] + Stopped emacs foo >{samsun} jobs | more >{samsun} > >So, for some reasons I just cannot pipe the output of "jobs". To see why this happens, consider how pipes are implemented. After creating a pipe, it is necessary to fork. A fork is not the parent of any of its parent's processes, hence a forked sub-C-shell must forget all its parent's jobs. Hence, `jobs | cat' or `(jobs)' or anything similar produces no output. `alias | cat' works fine since a subshell need not forget about the parent's aliases. -- In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7690) Domain: chris@mimsy.umd.edu Path: uunet!mimsy!chris