open($fh, "<:crlf", "foo.txt") or die "failed to open 'foo.txt':$!";