diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2001-12-11 14:33:14 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-12-11 14:33:14 +0000 |
commit | 6ce75a778d390cfc1b903c40f2566d0e560efcd8 (patch) | |
tree | 852095faac15bf2d497b71c3f3e0f8056eb91709 /doio.c | |
parent | d2492938eb072e03ead75c841f11237d3b984c72 (diff) | |
download | perl-6ce75a778d390cfc1b903c40f2566d0e560efcd8.tar.gz |
Try to handle platforms that have O_TEXT != O_BINARY but
which are not DOSish, BeOS being one of such platforms.
Ideally this should be a Configure test, not a hardwired
cpp symbol test...
p4raw-id: //depot/perl@13621
Diffstat (limited to 'doio.c')
-rw-r--r-- | doio.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -1107,7 +1107,11 @@ Perl_do_binmode(pTHX_ PerlIO *fp, int iotype, int mode) /* The old body of this is now in non-LAYER part of perlio.c * This is a stub for any XS code which might have been calling it. */ - char *name = (O_BINARY != O_TEXT && !(mode & O_BINARY)) ? ":crlf" : ":raw"; + char *name = ":raw"; +#ifdef PERLIO_CRLF + if (!(mode & O_BINARY))) + name = ":crlf"; +#endif return PerlIO_binmode(aTHX_ fp, iotype, mode, name); } |