From 7af9f795609db767ee6bc9f3862a87f6a6a6f8f6 Mon Sep 17 00:00:00 2001 From: eban Date: Sun, 12 Jan 2003 09:24:28 +0000 Subject: [PATCH] * io.c (next_argv): inherit binmode from $defout. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3332 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 4 ++++ io.c | 7 +++++++ version.h | 6 +++--- 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 5bf46ae7cb..5c98c2bc7a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Sun Jan 12 16:07:17 2003 WATANABE Hirofumi + + * io.c (next_argv): inherit binmode from $defout. + Sat Jan 11 22:50:47 2003 WATANABE Hirofumi * ext/dl/lib/dl/win32.rb: compatibility improvement. diff --git a/io.c b/io.c index 737776d915..7381fe1c92 100644 --- a/io.c +++ b/io.c @@ -2885,6 +2885,12 @@ next_argv() { extern VALUE rb_argv; char *fn; + OpenFile *fptr; + int defout_binmode = 0; + + GetOpenFile(rb_defout, fptr); + if (fptr->mode | FMODE_BINMODE) + defout_binmode = 1; if (init_p == 0) { if (RARRAY(rb_argv)->len > 0) { @@ -2977,6 +2983,7 @@ next_argv() prep_path(current_file, fn); } if (binmode) rb_io_binmode(current_file); + if (defout_binmode) rb_io_binmode(rb_defout); } else { init_p = 0; diff --git a/version.h b/version.h index 8fc5d9ea0f..b795149076 100644 --- a/version.h +++ b/version.h @@ -1,11 +1,11 @@ #define RUBY_VERSION "1.8.0" -#define RUBY_RELEASE_DATE "2003-01-11" +#define RUBY_RELEASE_DATE "2003-01-12" #define RUBY_VERSION_CODE 180 -#define RUBY_RELEASE_CODE 20030111 +#define RUBY_RELEASE_CODE 20030112 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 8 #define RUBY_VERSION_TEENY 0 #define RUBY_RELEASE_YEAR 2003 #define RUBY_RELEASE_MONTH 01 -#define RUBY_RELEASE_DAY 11 +#define RUBY_RELEASE_DAY 12