summaryrefslogtreecommitdiffstats
path: root/fs/ext2/namei.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ext2/namei.c')
-rw-r--r--fs/ext2/namei.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/ext2/namei.c b/fs/ext2/namei.c
index 59d3ef492..2ecd748e9 100644
--- a/fs/ext2/namei.c
+++ b/fs/ext2/namei.c
@@ -235,6 +235,7 @@ int ext2_add_entry (struct inode * dir, const char * name, int namelen,
return retval;
if (dir->i_size <= offset) {
if (dir->i_size == 0) {
+ brelse(bh);
return -ENOENT;
}