> I found that sh and ksh return 1 on bad cd, but bash returns 0.
> So bash : cd /xxx && rm * - will remove everything in your current
Not true.
caleb.INS.CWRU.Edu(1)$ cd /xxx
-bash: cd: /xxx: No such file or directory
caleb.INS.CWRU.Edu(1)$ echo $?
1
You probably have a shell function for cd that returns success
unconditionally.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
( ``Discere est Dolere'' -- chet )
Live...Laugh...Love
Chet Ramey, ITS, CWRU chet@po.cwru.edu http://tiswww.tis.cwru.edu/~chet/