[parted-devel] [PATCH 1/7] parted: add resizepart command

Brian C. Lane bcl at redhat.com
Wed Jun 11 19:00:57 UTC 2014


On Sun, May 25, 2014 at 05:11:27PM -0400, Phillip Susi wrote:
> +        ped_constraint_destroy (constraint);
> +        if (range_end != NULL)
> +                ped_geometry_destroy (range_end);
> +
> +        if ((*dev)->type != PED_DEVICE_FILE)
> +                disk_is_modified = 1;
> +
> +        return 1;
> +
> +error_destroy_constraint:
> +        ped_constraint_destroy (constraint);
> +error:
> +        if (range_end != NULL)
> +                ped_geometry_destroy (range_end);
> +        return 0;
> +}

I think this should be re-arranged to use a return rc value so that the
exit code isn't duplicated in two places.


-- 
Brian C. Lane | Anaconda Team | IRC: bcl #anaconda | Port Orchard, WA (PST8PDT)



More information about the parted-devel mailing list