Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!cs.utexas.edu!uunet!mcvax!hp4nl!botter!star.cs.vu.nl!maart From: maart@cs.vu.nl (Maarten Litmaath) Newsgroups: comp.unix.wizards Subject: Re: sed command behavior suspect Message-ID: <2846@kappl.cs.vu.nl> Date: 8 Jul 89 06:06:20 GMT References: <376@proexam.UUCP> Organization: V.U. Informatica, Amsterdam, the Netherlands Lines: 15 glen@proexam.UUCP (Glen Brydon) writes: \... sed 's/.*/&/p;d' \ \). The bsd version does print all the lines as expected, but the system V \one does not. Also, the latest bsd version on our sun os does not either. I say it should print every line indeed; apparently the System V version of sed merely sets a flag "this line is to be printed later", which gets cleared by the `d' operation. The following does work as expected: sed 's/.*/&/w foo d' -- "... a lap-top Cray-2 with builtin |Maarten Litmaath @ VU Amsterdam: cold fusion power supply" (Colin Dente) |maart@cs.vu.nl, mcvax!botter!maart