in reply to Re: Creating Unix Friendly files in win32
in thread Creating Unix Friendly files in win32

Just curious: why use \x0A instead of \n? Does the latter get converted even if binmode is set on the filehandle?

Flavio
perl -ple'$_=reverse' <<<ti.xittelop@oivalf

Don't fool yourself.

Replies are listed 'Best First'.
Re^3: Creating Unix Friendly files in win32
by holli (Abbot) on Sep 26, 2005 at 10:43 UTC
    Ugh. No. \n and binmode works just fine. But \x0A gets converted to \x0D\x0A if binmode is not present.

    That's a pitfall and I must have mixed it up in my memory.


    holli, /regexed monk/
      But \x0A gets converted to \x0D\x0A if binmode is not present.
      Seriously? By who? I'm not doubting you (as I have no Windows machine handy to test it out on), but that seems a little odd...

      thor

      Feel the white light, the light within
      Be your own disciple, fan the sparks of will
      For all of us waiting, your kingdom will come