diff options
Diffstat (limited to 'bitmap.c')
-rw-r--r-- | bitmap.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -227,9 +227,13 @@ bitmap_info_t *bitmap_file_read(char *filename, int brief, struct supertype **st if (!st) { /* just look at device... */ lseek(fd, 0, 0); - } else { + } else if (!st->ss->locate_bitmap) { + fprintf(stderr, Name ": No bitmap possible with %s metadata\n", + st->ss->name); + return NULL; + } else st->ss->locate_bitmap(st, fd); - } + ioctl(fd, BLKFLSBUF, 0); /* make sure we read current data */ *stp = st; } else { |