On Mon, Apr 23, 2007 at 04:31:53PM +0200, Thomas Schmitt wrote: > I got an antiquity online (some SuSE 6.x): > $ uname -a > Linux * 2.2.13 #1 Mon Nov 8 15:51:29 CET 1999 i686 unknown > $ for i in ; do echo $i ; done > bash: syntax error near unexpected token `;' > $ for i in > bash: syntax error near unexpected token `in' > $ for i in 1 > > do echo $i > > done > 1 > $
Which version of bash is that? I can't reproduce that result at all. svr1:~$ cat /etc/redhat-release Red Hat Linux release 5.2 (Apollo) svr1:~$ echo $BASH_VERSION 1.14.7(1) svr1:~$ for x in > do > echo > done svr1:~$ for i in ; do echo $i ; done svr1:~$ I'm not saying that the syntax is valid -- just that I can't find ANY system that can reproduce this error. I understand all about writing portable scripts with autoconf, but without a way to TEST various things, writing portable code becomes a whole lot harder. My oldest bash (1.14.7) and dash (0.5.2) both accept it as valid. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]