resolves #500 write to specified outfile even when input is stdin