------------------------------------------------------------------------------- Csh has a major logical fault with the breaksw statment. If breaksw appears on a line as a command any commands before it on the line will NOT be executed. switch( $HOST ) case kurango: cat /etc/motd; breaksw endsw will NOT print the message of the day file, while switch( $HOST ) case kurango: cat /etc/motd breaksw endsw will work as expected. ( Standard csh on a Sun4 Sparc Server running SunOs 4.1.3 ) ------------------------------------------------------------------------------- Csh Question (to a compiler class) Did you know that typing !xxx%s%s%s%s%s%s%s%s to any C-shell will cause it to crash immediately? Do you know why? Questions to think about: * What does the shell do when you type "!xxx" ? * What must it be doing with your input when you type "!xxx%s%s%s%s%s%s%s%s"? * Why does this crash the shell? * How could you (rather easily) rewrite the offending part of the shell so as not to have this problem? MOST IMPORTANTLY: * Does it seem reasonable that you (yes you!) can bring what may be the Future Operating System of the World to its knees in 21 keystokes? -------------------------------------------------------------------------------