]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
libfdisk: (gpt) check string_to_guid()
authorKarel Zak <kzak@redhat.com>
Wed, 17 Sep 2014 11:10:14 +0000 (13:10 +0200)
committerKarel Zak <kzak@redhat.com>
Tue, 7 Oct 2014 12:55:32 +0000 (14:55 +0200)
Signed-off-by: Karel Zak <kzak@redhat.com>
libfdisk/src/gpt.c

index 469e36e15476a97ad690db45e27febee67c60bbc..58f27962b396bfa0becf08f043de3a8cd1a48b64 100644 (file)
@@ -1465,7 +1465,9 @@ static int gpt_set_partition(struct fdisk_context *cxt, size_t n,
        if (pa->type && pa->type->typestr) {
                struct gpt_guid typeid;
 
-               string_to_guid( pa->type->typestr, &typeid);
+               rc = string_to_guid(pa->type->typestr, &typeid);
+               if (rc)
+                       return rc;
                gpt_entry_set_type(e, &typeid);
        }