in reply to Re^3: Error binmode() on unopened filehandle
in thread Error binmode() on unopened filehandle

Works just fine!

That will only read until the first 0A byte. You need local $/;