X-Git-Url: https://git.camperquake.de/gitweb.cgi?a=blobdiff_plain;ds=sidebyside;f=lib%2Flibefi%2Frdwr_efi.c;h=2af0c4e2e472f0122532bfecf5f18e8ba9242598;hb=df554c148ecfdfb7e597f8ab7eee71388b24a19d;hp=da71e3486c2270886a3621403cd9ddb17b4ba29b;hpb=d603ed6c278f9c25b17ba8e75e9bce6e5d715ac0;p=zfs.git diff --git a/lib/libefi/rdwr_efi.c b/lib/libefi/rdwr_efi.c index da71e34..2af0c4e 100644 --- a/lib/libefi/rdwr_efi.c +++ b/lib/libefi/rdwr_efi.c @@ -269,19 +269,12 @@ efi_alloc_and_init(int fd, uint32_t nparts, struct dk_gpt **vtoc) struct uuid uuid; struct dk_cinfo dki_info; - if (read_disk_info(fd, &capacity, &lbsize) != 0) { - if (efi_debug) - (void) fprintf(stderr, - "couldn't read disk information\n"); + if (read_disk_info(fd, &capacity, &lbsize) != 0) return (-1); - } + #if defined(__linux__) - if (efi_get_info(fd, &dki_info) != 0) { - if (efi_debug) - (void) fprintf(stderr, - "couldn't read disk information\n"); + if (efi_get_info(fd, &dki_info) != 0) return (-1); - } if (dki_info.dki_partition != 0) return (-1);