libblkid: remove unnecessary condition [lgtm scan]

Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
Karel Zak 2019-09-20 15:52:34 +02:00
parent a6a24f18e6
commit 351de28ae6
1 changed files with 1 additions and 2 deletions

View File

@ -217,8 +217,7 @@ blkid_probe blkid_new_probe_from_filename(const char *filename)
pr->flags |= BLKID_FL_PRIVATE_FD;
return pr;
err:
if (fd >= 0)
close(fd);
close(fd);
blkid_free_probe(pr);
return NULL;
}