This is a note to let you know that I've just added the patch titled

    ocfs2: fix NULL pointer dereference in __ocfs2_change_file_space()

to the 3.4-stable tree which can be found at:
    
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     ocfs2-fix-null-pointer-dereference-in-__ocfs2_change_file_space.patch
and it can be found in the queue-3.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.


>From a4e08d001f2e50bb8b3c4eebadcf08e5535f02ee Mon Sep 17 00:00:00 2001
From: Luis Henriques <[email protected]>
Date: Wed, 11 Jul 2012 14:02:10 -0700
Subject: ocfs2: fix NULL pointer dereference in __ocfs2_change_file_space()

From: Luis Henriques <[email protected]>

commit a4e08d001f2e50bb8b3c4eebadcf08e5535f02ee upstream.

As ocfs2_fallocate() will invoke __ocfs2_change_file_space() with a NULL
as the first parameter (file), it may trigger a NULL pointer dereferrence
due to a missing check.

Addresses http://bugs.launchpad.net/bugs/1006012

Signed-off-by: Luis Henriques <[email protected]>
Reported-by: Bret Towe <[email protected]>
Tested-by: Bret Towe <[email protected]>
Cc: Sunil Mushran <[email protected]>
Acked-by: Joel Becker <[email protected]>
Acked-by: Mark Fasheh <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>

---
 fs/ocfs2/file.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/fs/ocfs2/file.c
+++ b/fs/ocfs2/file.c
@@ -1950,7 +1950,7 @@ static int __ocfs2_change_file_space(str
        if (ret < 0)
                mlog_errno(ret);
 
-       if (file->f_flags & O_SYNC)
+       if (file && (file->f_flags & O_SYNC))
                handle->h_sync = 1;
 
        ocfs2_commit_trans(osb, handle);


Patches currently in stable-queue which might be from 
[email protected] are

queue-3.4/ocfs2-fix-null-pointer-dereference-in-__ocfs2_change_file_space.patch
queue-3.4/alsa-hda-fix-power-map-regression-for-hp-dv6-co.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to