* fhandler_disk_file.cc (fhandler_disk_file::fstat): Always call fstat_by_name
if fd is not opened to allow fstat_by_name to properly set errno. * fhandler.cc (binmode): Default to binmode when mode is not known.
This commit is contained in:
@ -434,7 +434,7 @@ fhandler_base::open (path_conv *pc, int flags, mode_t mode)
|
||||
else if (fmode & O_TEXT)
|
||||
bin = O_TEXT;
|
||||
else if (get_device () == FH_DISK)
|
||||
bin = get_w_binary () || get_r_binary ();
|
||||
bin = get_w_binary () || get_r_binary () || O_BINARY;
|
||||
else
|
||||
bin = (binmode == O_BINARY) || get_w_binary () || get_r_binary ();
|
||||
|
||||
|
Reference in New Issue
Block a user