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:
b41fb00
)
debugfs: Close the file handle and return in case of errors
author
Manish Katiyar
<mkatiyar@gmail.com>
Sat, 23 Aug 2008 16:11:25 +0000
(21:41 +0530)
committer
Theodore Ts'o
<tytso@mit.edu>
Sun, 24 Aug 2008 21:29:33 +0000
(17:29 -0400)
Close the filehandle and return in case if we are unable to expand the
directory during write.
Signed-off-by: "Manish Katiyar" <mkatiyar@gmail.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
debugfs/debugfs.c
patch
|
blob
|
history
diff --git
a/debugfs/debugfs.c
b/debugfs/debugfs.c
index
7039340
..
ab40de8
100644
(file)
--- a/
debugfs/debugfs.c
+++ b/
debugfs/debugfs.c
@@
-1366,6
+1366,7
@@
void do_write(int argc, char *argv[])
retval = ext2fs_expand_dir(current_fs, cwd);
if (retval) {
com_err(argv[0], retval, "while expanding directory");
+ close(fd);
return;
}
retval = ext2fs_link(current_fs, cwd, argv[2], newfile,