summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--super-intel.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/super-intel.c b/super-intel.c
index 2e85b6b..ca15703 100644
--- a/super-intel.c
+++ b/super-intel.c
@@ -4353,7 +4353,7 @@ static int get_super_block(struct intel_super **super_list, int devnum, char *de
} else {
if (s)
free(s);
- if (dfd)
+ if (dfd >= 0)
close(dfd);
}
if ((dfd >= 0) && (!keep_fd))