Better handling of standard input.