mirror of
https://git.savannah.gnu.org/git/grub.git
synced 2026-10-25 00:29:23 +00:00
fix several bugs.
This commit is contained in:
1 parent
a3d2f9bee9
commit
c95941d65d
19 files changed
+137
-21
No files matched your search
@@ -296,6 +296,7 @@ distclean-generic:
|
||||
-rm -f config.cache config.log stamp-h stamp-h[0-9]*
|
||||
|
||||
maintainer-clean-generic:
|
||||
-rm -f Makefile.in
|
||||
mostlyclean-am: mostlyclean-sbinPROGRAMS mostlyclean-compile \
|
||||
mostlyclean-tags mostlyclean-depend mostlyclean-generic
|
||||
|
||||
|
||||
+7
-1
@@ -513,7 +513,7 @@ check_device (const char *device)
|
||||
/* Error opening the device. */
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
/* Attempt to read the first sector. */
|
||||
if (fread (buf, 1, 512, fp) != 512)
|
||||
{
|
||||
@@ -957,6 +957,12 @@ get_diskinfo (int drive, struct geometry *geometry)
|
||||
if (disks[drive].flags == -1)
|
||||
return -1;
|
||||
|
||||
#ifdef __linux__
|
||||
/* In Linux, invalidate the buffer cache, so that left overs
|
||||
from other program in the cache are flushed and seen by us */
|
||||
ioctl (disks[drive].flags, BLKFLSBUF, 0);
|
||||
#endif
|
||||
|
||||
*geometry = disks[drive];
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user