]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/blob - src/patches/suse-2.6.27.31/patches.fixes/ocfs2-Let-inode-be-really-deleted-when-ocfs2_mknod_.patch
Reenabled linux-xen, added patches for Xen Kernel Version 2.6.27.31,
[people/teissler/ipfire-2.x.git] / src / patches / suse-2.6.27.31 / patches.fixes / ocfs2-Let-inode-be-really-deleted-when-ocfs2_mknod_.patch
1 From: Jan Kara <jack@suse.cz>
2 Date: Mon, 20 Oct 2008 19:23:54 +0200
3 Subject: ocfs2: Let inode be really deleted when ocfs2_mknod_locked() fails
4
5 We forgot to set i_nlink to 0 when returning due to error from ocfs2_mknod_locked()
6 and thus inode was not properly released via ocfs2_delete_inode() (e.g. claimed
7 space was not released). Fix it.
8
9 Signed-off-by: Jan Kara <jack@suse.cz>
10 Signed-off-by: Joel Becker <joel.becker@oracle.com>
11 Signed-off-by: Mark Fasheh <mfasheh@suse.com>
12 ---
13 fs/ocfs2/namei.c | 4 +++-
14 1 files changed, 3 insertions(+), 1 deletions(-)
15
16 Index: linux-2.6.27-ocfs2/fs/ocfs2/namei.c
17 ===================================================================
18 --- linux-2.6.27-ocfs2.orig/fs/ocfs2/namei.c
19 +++ linux-2.6.27-ocfs2/fs/ocfs2/namei.c
20 @@ -491,8 +491,10 @@ leave:
21 brelse(*new_fe_bh);
22 *new_fe_bh = NULL;
23 }
24 - if (inode)
25 + if (inode) {
26 + clear_nlink(inode);
27 iput(inode);
28 + }
29 }
30
31 mlog_exit(status);