When I type the command “cat” to my program, it just hangs. Whats wrong?
When the “cat” command is called with no arguments, it copies standard input to standard output. Since you don’t use getOutputStream() to pass data to the standard input of a process, it will just sit there forever waiting for input. The assignment specifically says that you don’t have to deal with the standard input of the processes you create. Thus this behavior is not a bug but a “feature”! Similarly, “more” (or “less”) will not do anything useful.
Related Questions
- I just saw someone examine a room closely, but when I type EXAMINE ROOM I only get the same result as if I used the LOOK command. What is wrong?
- My Deferred or DeferredList never fires, so my program just mysteriously hangs! Whats wrong?
- When I type the command "cat" to my program, it just hangs. Whats wrong?