From fd8e5366aa3c50b1049b9370984d04b46f950d20 Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Fri, 18 Jul 2008 08:16:40 +0000 Subject: [PATCH] * environ.cc (known): Remove "binmode" option. * fhandler.cc (binmode): Remove. (fhandler_base::set_flags): Accommodate binmode removal. * path.h (path_conv::set_binary): Remove. * pipe.cc (pipe): Create pipes always as binary pipes. * winsup.h (binmode): Remove declaration. --- winsup/cygwin/ChangeLog | 9 +++++++++ winsup/cygwin/environ.cc | 1 - winsup/cygwin/fhandler.cc | 5 +---- winsup/cygwin/path.h | 1 - winsup/cygwin/pipe.cc | 5 +---- winsup/cygwin/winsup.h | 1 - 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 360db15c3..4cc54cee1 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,12 @@ +2008-07-18 Corinna Vinschen + + * environ.cc (known): Remove "binmode" option. + * fhandler.cc (binmode): Remove. + (fhandler_base::set_flags): Accommodate binmode removal. + * path.h (path_conv::set_binary): Remove. + * pipe.cc (pipe): Create pipes always as binary pipes. + * winsup.h (binmode): Remove declaration. + 2008-07-17 Corinna Vinschen * mount.cc (mount_info::from_fstab_line): Default to binary mount. diff --git a/winsup/cygwin/environ.cc b/winsup/cygwin/environ.cc index 260d9e478..040a638e8 100644 --- a/winsup/cygwin/environ.cc +++ b/winsup/cygwin/environ.cc @@ -566,7 +566,6 @@ static struct parse_thing } values[2]; } known[] NO_COPY = { - {"binmode", {x: &binmode}, justset, NULL, {{O_TEXT}, {O_BINARY}}}, {"codepage", {func: &codepage_init}, isfunc, NULL, {{0}, {0}}}, {"dosfilewarning", {&dos_file_warning}, justset, NULL, {{false}, {true}}}, {"envcache", {&envcache}, justset, NULL, {{true}, {false}}}, diff --git a/winsup/cygwin/fhandler.cc b/winsup/cygwin/fhandler.cc index 168e4e49f..412686be9 100644 --- a/winsup/cygwin/fhandler.cc +++ b/winsup/cygwin/fhandler.cc @@ -34,8 +34,6 @@ static NO_COPY const int CHUNK_SIZE = 1024; /* Used for crlf conversions */ struct __cygwin_perfile *perfile_table; -DWORD binmode; - inline fhandler_base& fhandler_base::operator =(fhandler_base& x) { @@ -197,8 +195,7 @@ fhandler_base::set_flags (int flags, int supplied_bin) else if (supplied_bin) bin = supplied_bin; else - bin = wbinary () || rbinary () || (binmode != O_TEXT) - ? O_BINARY : O_TEXT; + bin = wbinary () || rbinary () ? O_BINARY : O_TEXT; openflags = flags | bin; diff --git a/winsup/cygwin/path.h b/winsup/cygwin/path.h index a567e1e07..32c46a537 100644 --- a/winsup/cygwin/path.h +++ b/winsup/cygwin/path.h @@ -193,7 +193,6 @@ class path_conv return dont_know_if_executable; } - void set_binary () {path_flags |= PATH_BINARY;} void set_symlink (DWORD n) {path_flags |= PATH_SYMLINK; symlink_length = n;} void set_has_symlinks () {path_flags |= PATH_HAS_SYMLINKS;} void set_exec (int x = 1) {path_flags |= x ? PATH_EXEC : PATH_NOTEXEC;} diff --git a/winsup/cygwin/pipe.cc b/winsup/cygwin/pipe.cc index edd901160..2cad3fe26 100644 --- a/winsup/cygwin/pipe.cc +++ b/winsup/cygwin/pipe.cc @@ -495,11 +495,8 @@ fhandler_pipe::fstatvfs (struct statvfs *sfs) extern "C" int pipe (int filedes[2]) { - extern DWORD binmode; fhandler_pipe *fhs[2]; - int res = fhandler_pipe::create (fhs, DEFAULT_PIPEBUFSIZE, - (!binmode || binmode == O_BINARY) - ? O_BINARY : O_TEXT); + int res = fhandler_pipe::create (fhs, DEFAULT_PIPEBUFSIZE, O_BINARY); if (res == 0) { cygheap_fdnew fdin; diff --git a/winsup/cygwin/winsup.h b/winsup/cygwin/winsup.h index e3156f7de..79ae39aec 100644 --- a/winsup/cygwin/winsup.h +++ b/winsup/cygwin/winsup.h @@ -337,7 +337,6 @@ int cygwin_select (int , fd_set *, fd_set *, fd_set *, struct timeval *to); int cygwin_gethostname (char *__name, size_t __len); -extern DWORD binmode; extern char _data_start__, _data_end__, _bss_start__, _bss_end__; extern void (*__CTOR_LIST__) (void); extern void (*__DTOR_LIST__) (void);