Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] sh bug
- Date: Thu, 20 Feb 2003 10:40:28 +0900 (JST)
- From: "J. David Beutel" <jdb@example.com>
- Subject: Re: [tlug] sh bug
> $ cat >a > a > b > x > $ sh -c 'while read a; do if [ $a = "b" ]; then exit 1; fi; echo $a; done < a; echo done' > a > done > $ ksh -c 'while read a; do if [ $a = "b" ]; then exit 1; fi; echo $a; done < a; echo done' > a What is the bug? The exit only ends the while loop? Or the parser is susceptible to obfuscation? I'm no shell wizard, but this looks obfuscated. Using "a" as the name of the file, the contents of the first line of the file, the name of the variable, and the echoed output is obfuscatory. So is using "done" as the last echo string, since it is the same as the end of the while loop. Finally, putting it all on one line doesn't make it any easier. So, I wonder what the root problem is. 11011011
- Follow-Ups:
- Re: [tlug] sh bug
- From: Matt Doughty
- Re: [tlug] sh bug
- From: Viktor Pavlenko
- References:
- [tlug] sh bug
- From: Viktor Pavlenko
Home | Main Index | Thread Index
- Prev by Date: [tlug] Training Classes
- Next by Date: Re: [tlug] Training Classes
- Previous by thread: [tlug] sh bug
- Next by thread: Re: [tlug] sh bug
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links