[parted-devel] [PATCH 1/4] libparted: Fix handling of gpt partition types

Brian C. Lane bcl at redhat.com
Wed Aug 10 22:47:50 BST 2022


On Tue, Aug 09, 2022 at 10:09:14PM +0200, Håkon Løvdal wrote:
> On Tue, 9 Aug 2022 at 02:41, Brian C. Lane <bcl at redhat.com> wrote:
> > +/* is_skip_guid checks the guid against the list of guids that should not be
> > + * overridden by set_system. It returns a 1 if it is in the list.
> > +*/
> > +static bool
> > +is_skip_guid(efi_guid_t guid) {
> > +    int n = sizeof(skip_set_system_guids) / sizeof(skip_set_system_guids[0]);
> > +    for (int i = 0; i < n; ++i) {
> > +        if (guid_cmp(guid, skip_set_system_guids[i]) == 0) {
> > +            return 1;
> > +        }
> > +    }
> > +
> > +    return 0;
> > +}
> 
> I think a function with return type bool rather should return
> true/false than 1/0.

Thanks! You are correct. Fixed locally.

Brian

-- 
Brian C. Lane (PST8PDT) - weldr.io - lorax - parted - pykickstart




More information about the parted-devel mailing list