chiark / gitweb /
udev: fix a few issues detected by the llvm static analyzer
[elogind.git] / src / udev / udev-builtin-blkid.c
index 174e20e..fdc68d0 100644 (file)
@@ -115,7 +115,6 @@ static int probe_superblocks(blkid_probe pr)
 
 static int builtin_blkid(struct udev_device *dev, int argc, char *argv[], bool test)
 {
-        struct udev *udev = udev_device_get_udev(dev);
         int64_t offset = 0;
         bool noraid = false;
         int fd = -1;
@@ -151,10 +150,8 @@ static int builtin_blkid(struct udev_device *dev, int argc, char *argv[], bool t
         }
 
         pr = blkid_new_probe();
-        if (!pr) {
-                err = -ENOMEM;
+        if (!pr)
                 return EXIT_FAILURE;
-        }
 
         blkid_probe_set_superblocks_flags(pr,
                 BLKID_SUBLKS_LABEL | BLKID_SUBLKS_UUID |