From: Michael Halcrow Date: Thu, 20 Mar 2008 00:00:58 +0000 (-0700) Subject: eCryptfs: Swap dput() and mntput() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5366dc9fd1cb74023790a8edf29e4fe42c886dcf;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git eCryptfs: Swap dput() and mntput() ecryptfs_d_release() is doing a mntput before doing the dput. This patch moves the dput before the mntput. Thanks to Rajouri Jammu for reporting this. Signed-off-by: Michael Halcrow Cc: Rajouri Jammu Cc: Eric Sandeen Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/fs/ecryptfs/dentry.c b/fs/ecryptfs/dentry.c index 841a032050a7..5e596583946c 100644 --- a/fs/ecryptfs/dentry.c +++ b/fs/ecryptfs/dentry.c @@ -80,8 +80,8 @@ static void ecryptfs_d_release(struct dentry *dentry) { if (ecryptfs_dentry_to_private(dentry)) { if (ecryptfs_dentry_to_lower(dentry)) { - mntput(ecryptfs_dentry_to_lower_mnt(dentry)); dput(ecryptfs_dentry_to_lower(dentry)); + mntput(ecryptfs_dentry_to_lower_mnt(dentry)); } kmem_cache_free(ecryptfs_dentry_info_cache, ecryptfs_dentry_to_private(dentry));