@Gaelan Based on a quick reading of the source, the V6 shell took the brute force approach of dup()'ing any script on the command line to fd 0, so it could always just read from fd 0 (it carefully turned off printing the prompt if it was running a script). Then goto and exit manipulated fd 0, which the shell passed to them. Presumably people learned to not run programs in shell scripts that also tried to read stdin on their own.