in reply to Re: Crypt() usage
in thread Crypt() usage

.. and, related to that, I wonder if the different line-endings (in Linux and Windows) might result in a different crypt result. I only have Windows here at work, so I cannot test this hypothesis right now.

Alex / talexb / Toronto

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

Replies are listed 'Best First'.
Re^3: Crypt() usage
by BillKSmith (Monsignor) on Jul 29, 2016 at 12:39 UTC
    Line endings should only be an issue in I/O. By default perl strings use a single newline character as a record separator. PerlIO translates between this and whatever your OS requires. When processing files from another OS, specify the required translation on the open statement.
    Bill

      ...or use File::Edit::Portable which does the translations automatically for you, cross-platform, so you don't have to figure out which ending to use yourself ;)

      use File::Edit::Portable; my $rw = File::Edit::Portable->new; my $fh = $rw->read('file.txt');

      Disclaimer: author of said module here