summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
Diffstat (limited to 'util')
-rw-r--r--util/nvmutil/nvmutil.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/util/nvmutil/nvmutil.c b/util/nvmutil/nvmutil.c
index ade8f431..ee1656ab 100644
--- a/util/nvmutil/nvmutil.c
+++ b/util/nvmutil/nvmutil.c
@@ -1321,12 +1321,14 @@ close_files(void)
if (gbe_fd > -1) {
if (close(gbe_fd) == -1)
err(-1, "%s: close failed", fname);
+ gbe_fd = -1;
}
#ifndef NVMUTIL_ARC4RANDOM_BUF
if (urandom_fd > -1) {
if (close(urandom_fd) == -1)
err(-1, "%s: close failed", rname);
+ urandom_fd = -1;
}
#endif
}