diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2005-09-30 10:54:45 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2005-09-30 10:54:45 +0000 |
commit | 8afc05fa903cb331003bc498b7c6b02e643871df (patch) | |
tree | 0aa3fa562dd95f978bd9689e83d065b6ff3866e9 | |
parent | 251436268e18dbfa2071eb824e55152977ef461c (diff) | |
download | newlib-8afc05fa903cb331003bc498b7c6b02e643871df.zip newlib-8afc05fa903cb331003bc498b7c6b02e643871df.tar.gz newlib-8afc05fa903cb331003bc498b7c6b02e643871df.tar.bz2 |
* fhandler_floppy.cc (fhandler_dev_floppy::get_drive_info): Use
fhandler method to access majoer device number. Add comment to
explain floppy weirdness.
-rw-r--r-- | winsup/cygwin/ChangeLog | 6 | ||||
-rw-r--r-- | winsup/cygwin/fhandler_floppy.cc | 5 |
2 files changed, 9 insertions, 2 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index b7dcf0a..d41f5df 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,5 +1,11 @@ 2005-09-30 Corinna Vinschen <corinna@vinschen.de> + * fhandler_floppy.cc (fhandler_dev_floppy::get_drive_info): Use + fhandler method to access majoer device number. Add comment to + explain floppy weirdness. + +2005-09-30 Corinna Vinschen <corinna@vinschen.de> + * fhandler_disk_file.cc (fhandler_base::fstat_by_handle): Also use attributes stored in this->pc if call to GetFileInformationByHandle failed. diff --git a/winsup/cygwin/fhandler_floppy.cc b/winsup/cygwin/fhandler_floppy.cc index 96f25b1..84d3d0f 100644 --- a/winsup/cygwin/fhandler_floppy.cc +++ b/winsup/cygwin/fhandler_floppy.cc @@ -46,8 +46,9 @@ fhandler_dev_floppy::get_drive_info (struct hd_geometry *geo) DWORD bytes_read = 0; /* Always try using the new EX ioctls first (>= XP). If not available, - fall back to trying the old non-EX ioctls. */ - if (wincap.has_disk_ex_ioctls () && pc.dev.major != DEV_FLOPPY_MAJOR) + fall back to trying the old non-EX ioctls. + Unfortunately the EX ioctls are not implemented in the floppy driver. */ + if (wincap.has_disk_ex_ioctls () && get_major () != DEV_FLOPPY_MAJOR) { if (!DeviceIoControl (get_handle (), IOCTL_DISK_GET_DRIVE_GEOMETRY_EX, NULL, 0, |