Whamcloud - gitweb
git://git.whamcloud.com
/
tools
/
e2fsprogs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
06a276e
)
e2fsck: fix fd leak in reserve_stdio_fds
author
Theodore Ts'o
<tytso@mit.edu>
Sun, 12 Aug 2018 00:47:08 +0000
(20:47 -0400)
committer
Theodore Ts'o
<tytso@mit.edu>
Tue, 14 Aug 2018 01:32:55 +0000
(21:32 -0400)
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Reviewed-by: Lukas Czerner <lczerner@redhat.com>
e2fsck/unix.c
patch
|
blob
|
history
diff --git
a/e2fsck/unix.c
b/e2fsck/unix.c
index
90065b3
..
2df22b1
100644
(file)
--- a/
e2fsck/unix.c
+++ b/
e2fsck/unix.c
@@
-617,9
+617,10
@@
static void reserve_stdio_fds(void)
fprintf(stderr, _("ERROR: Couldn't open "
"/dev/null (%s)\n"),
strerror(errno));
-
break
;
+
return
;
}
}
+ (void) close(fd);
}
#ifdef HAVE_SIGNAL_H