newlib/winsup/cygwin/include/sys
Corinna Vinschen 367c1ae161 Cygwin: mount: define binary mount as default
Commit c1023ee353 changed the way
path_conv::binmode() works.  Rather than returning three states,
O_BINARY, O_TEXT, 0, it only returned 2 states, O_BINARY, O_TEXT.  Since
mounts are only binary if they are explicitely mounted binary by setting
the MOUNT_BINARY flag, textmode is default.

This introduced a new bug.  When inheriting stdio HANDLEs from native
Windows processes, the fhandler and its path_conv are created from a
device struct only.  None of the path or mount flags get set this way.
So the mount flags are 0 and path_conv::binmode() returned 0.

After the path_conv::binmode() change it returned O_TEXT since, as
explained above, the default mount mode is textmode.

Rather than just enforcing binary mode for path_conv's created from
device structs, this patch changes the default mount mode to binary:

Replace MOUNT_BINARY flag with MOUNT_TEXT flag with opposite meaning.
Drop all explicit setting of MOUNT_BINARY.  Drop local set_flags
function, it doesn't add any value.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2019-02-18 10:26:53 +01:00
..
_pthreadtypes.h
acl.h
copying.dj
cygwin.h Cygwin: kill(1): introduce a -W option 2019-02-02 21:02:00 +01:00
dirent.h Move common <sys/dirent.h> content to <dirent.h> 2018-10-11 08:29:16 +02:00
file.h ansification: remove _PARAMS 2018-01-17 11:47:13 -06:00
ioctl.h
ipc.h
kd.h
lock.h
mman.h
mount.h Cygwin: mount: define binary mount as default 2019-02-18 10:26:53 +01:00
msg.h
mtio.h
param.h
poll.h
procfs.h
quota.h
random.h
resource.h
sem.h
shm.h
signalfd.h Cygwin: signal: implement signalfd 2019-01-13 23:13:33 +01:00
smallprint.h
socket.h Cygwin: fix socketpair prototype 2018-03-09 14:17:39 +01:00
soundcard.h
statfs.h
statvfs.h
stdio.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
strace.h
sysinfo.h
syslimits.h
syslog.h Cygwin: delete /dev/kmsg and thus fhandler_mailslot without substitution 2018-03-25 12:38:14 +02:00
sysmacros.h
sysproto.h
termio.h
termios.h
timerfd.h Cygwin: timers: implement timerfd 2019-01-15 22:02:33 +01:00
ttychars.h
ucontext.h
uio.h
un.h Cygwin: cleanup header including within network-releated files 2018-02-28 18:56:13 +01:00
utime.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
utmp.h
utsname.h Cygwin: uname: Raise size of utsname fields and revamp uname(2) output 2019-01-26 18:37:25 +01:00
vfs.h
wait.h Cygwin: Remove union wait 2018-08-24 20:57:47 +02:00
xattr.h