in reply to Re: Perl binary file reading
in thread Perl binary file reading

If it's binary data, it might have a ^D, which indicates the end of a stream of data. That's on Linux .. and I think a ^Z is used for Windows.

Should be no problem with binmode.

Alexander

--
Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)

Replies are listed 'Best First'.
Re^3: Perl binary file reading
by talexb (Chancellor) on May 02, 2016 at 20:52 UTC

    Right -- that was my point. If they're using readline, they're subject to the rules of reading text (break the chunks into lines, stop at the 'end of file'). If they're using read, then they'll just get chunks of the file up to the file size.

    Alex / talexb / Toronto

    Thanks PJ. We owe you so much. Groklaw -- RIP -- 2003 to 2013.