[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] fix grub-setup on kfreebsd by adding 0x10 to the sysctl ("ke
From: |
Felix Zielcke |
Subject: |
Re: [PATCH] fix grub-setup on kfreebsd by adding 0x10 to the sysctl ("kern.geom.debugflags") flags |
Date: |
Tue, 14 Apr 2009 09:01:55 +0200 |
Am Montag, den 13.04.2009, 21:11 +0200 schrieb Robert Millan:
> How about [__FreeBSD__ || __FreeBSD_kernel__] ?
Ok.
> > + if (sysctlbyname ("kern.geom.debugflags", &sysctl_oldflags,
> > &sysctl_size, NULL, 0))
> > + grub_util_error ("cannot get current flags of sysctl
> > kern.geom.debugflags");
>
> I'd just return grub_error instead. Otherwise we abort the program even if
> failure to read a drive is not critical (e.g. lvm.mod scannning all drives,
> grub-emu, etc).
Ok.
> > + if (! sysctl_oldflags & 0x10 && sysctlbyname ("kern.geom.debugflags",
> > NULL , 0, &sysctl_flags, sysctl_size))
> > + grub_util_error ("cannot set flags of sysctl kern.geom.debugflags");
>
> Just a matter of taste, I'd suggest nested ifs to make it more readable.
Changed too.
I commited this now.
--
Felix Zielcke