fix a bug in lib/device.c.
This commit is contained in:
parent
af670e41f3
commit
aa4e796168
2 changed files with 9 additions and 1 deletions
|
@ -1,3 +1,11 @@
|
||||||
|
2000-09-07 OKUJI Yoshinori <okuji@gnu.org>
|
||||||
|
|
||||||
|
From Hal Snyder <hal@vailsys.com>:
|
||||||
|
* lib/device.c (get_drive_geometry) [__FreeBSD__ || __NetBSD__
|
||||||
|
|| __OpenBSD__]: Call ioctl for FD instead of
|
||||||
|
DISKS[DRIVE].FLAGS. This was a mistake when I segregated this
|
||||||
|
function from asmstub.c.
|
||||||
|
|
||||||
2000-09-07 Alessandro Rubini <rubini@gnu.org>
|
2000-09-07 Alessandro Rubini <rubini@gnu.org>
|
||||||
|
|
||||||
* docs/tutorial.texi: Fixed a few typos and minor imprecisions.
|
* docs/tutorial.texi: Fixed a few typos and minor imprecisions.
|
||||||
|
|
|
@ -99,7 +99,7 @@ get_drive_geometry (struct geometry *geom, char **map, int drive)
|
||||||
/* FreeBSD, NetBSD or OpenBSD */
|
/* FreeBSD, NetBSD or OpenBSD */
|
||||||
{
|
{
|
||||||
struct disklabel hdg;
|
struct disklabel hdg;
|
||||||
if (ioctl (disks[drive].flags, DIOCGDINFO, &hdg))
|
if (ioctl (fd, DIOCGDINFO, &hdg))
|
||||||
goto fail;
|
goto fail;
|
||||||
|
|
||||||
geom->cylinders = hdg.d_ncylinders;
|
geom->cylinders = hdg.d_ncylinders;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue