From 7a9a42b43162a6aa4bb9c5182743ab0c08779269 Mon Sep 17 00:00:00 2001 From: akr Date: Mon, 25 Aug 2008 16:30:43 +0000 Subject: * io.c: force CRLF handling if RUBY_TEST_CRLF_ENVIRONMENT is defined. This is only for testing. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@18854 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ io.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index cf4a6d543..bd1bf17e6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Tue Aug 26 01:29:26 2008 Tanaka Akira + + * io.c: force CRLF handling if RUBY_TEST_CRLF_ENVIRONMENT is defined. + This is only for testing. + Tue Aug 26 01:26:31 2008 Tanaka Akira * transcode.c (str_transcode0): disable newline conversion for ASCII diff --git a/io.c b/io.c index b06016d09..2fba88e08 100644 --- a/io.c +++ b/io.c @@ -674,7 +674,7 @@ rb_io_wait_writable(int f) } /* xxx: better way to determine the newline of the platform? */ -#if defined(O_BINARY) && O_BINARY != 0 +#if defined(RUBY_TEST_CRLF_ENVIRONMENT) || defined(O_BINARY) && O_BINARY != 0 /* Windows */ # define NEED_NEWLINE_DECODER(fptr) (!(fptr->mode & FMODE_BINMODE)) # define NEED_NEWLINE_ENCODER(fptr) (!(fptr->mode & FMODE_BINMODE)) -- cgit