Date: Sun, 31 Jan 1999 02:26:21 -0800 (PST) From: Eddie Lawhead <eddie@silk.net> To: Oleg Kolobov <oleg@lib.tpu.ru> Cc: freebsd-questions@FreeBSD.ORG Subject: Re: a nice example Message-ID: <Pine.BSF.4.05.9901310224410.48174-100000@eddie.silk.net> In-Reply-To: <36B4381B.5F23418F@lib.tpu.ru>
next in thread | previous in thread | raw e-mail | index | archive | help
Holy Crap!!! I had to try it....:) This should solve your problem: #!/bin/sh # Antitest while : do if [ -d test ]; then cd test else cd .. if [ -d test ]; then rm -rf test; else exit 0 fi fi done Very Cool..:) On Sun, 31 Jan 1999, Oleg Kolobov wrote: > Hi, > there is a nice example in SMM 4.4BSD documents (D. Ritchie "On the > Security of UNIX) > #!/bin/sh > while : > do > mkdir test; cd test > done > I have been executing the script for 5 min. > I can't delete directory - test!!! > I use command "rm -r ./test". No result. > I use script > #!/bin/sh > while : > do > if [ -n "$GO" ]; then > rm -rf test > cd .. > else > if [ -d test ]; then > cd test > else > GO=yes > fi > fi > done > No result. > Is there a nice anti_example? > > Thanks! > -- > > Oleg. > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Eddie H. Lawhead FreeBSD: The Power To Serve Kelowna, BC, Canada http://www.FreeBSD.org eddie@silk.net http://www.Silk.net =-=-=-=-=-=-= Enriched, V-Card, HTML Messages > /dev/null =-=-=-=-=-=-= To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.05.9901310224410.48174-100000>