open throws now an exception when it fails intead if writing to stdout.