From: Renaud Lottiaux Date: Tue, 30 Jun 2009 18:41:34 +0000 (-0700) Subject: bsdacct: fix access to invalid filp in acct_on() X-Git-Tag: v2.6.27.26~2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=339d06aaa1aff1ac0d73987ec4f90836aac62d76;p=pandora-kernel.git bsdacct: fix access to invalid filp in acct_on() commit df279ca8966c3de83105428e3391ab17690802a9 upstream. The file opened in acct_on and freshly stored in the ns->bacct struct can be closed in acct_file_reopen by a concurrent call after we release acct_lock and before we call mntput(file->f_path.mnt). Record file->f_path.mnt in a local variable and use this variable only. Signed-off-by: Renaud Lottiaux Signed-off-by: Louis Rilling Cc: Al Viro Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed