Hi, The attached patch fixes grub-probe for NetBSD (the issue was introduced in commit 4068).
Grégoire
=== modified file 'ChangeLog' --- ChangeLog 2012-06-23 20:56:19 +0000 +++ ChangeLog 2012-06-24 11:10:41 +0000 @@ -1,3 +1,10 @@ +2012-06-24 Grégoire Sutre <gregoire.su...@gmail.com> + + Fix overflow. + + * grub-core/kern/emu/hostdisk.c (grub_util_get_fd_size) + [__NetBSD__]: Add explicit cast before bitshift. + 2012-06-23 Vladimir Serbinenko <phco...@gmail.com> * configure.ac: Bump to 2.00~rc1. === modified file 'grub-core/kern/emu/hostdisk.c' --- grub-core/kern/emu/hostdisk.c 2012-06-07 12:24:48 +0000 +++ grub-core/kern/emu/hostdisk.c 2012-06-24 11:07:23 +0000 @@ -309,7 +309,7 @@ # if defined (__APPLE__) return nr << log_sector_size; # elif defined(__NetBSD__) - return label.d_secperunit << log_sector_size; + return (grub_uint64_t)label.d_secperunit << log_sector_size; # elif defined (__sun__) return minfo.dki_capacity << log_sector_size; # else
_______________________________________________ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel