]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/blobdiff - src/patches/suse-2.6.27.31/patches.fixes/ocfs2-Don-t-return-EFAULT-from-a-corrupt-xattr-ent.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-Don-t-return-EFAULT-from-a-corrupt-xattr-ent.patch
diff --git a/src/patches/suse-2.6.27.31/patches.fixes/ocfs2-Don-t-return-EFAULT-from-a-corrupt-xattr-ent.patch b/src/patches/suse-2.6.27.31/patches.fixes/ocfs2-Don-t-return-EFAULT-from-a-corrupt-xattr-ent.patch
new file mode 100644 (file)
index 0000000..f146954
--- /dev/null
@@ -0,0 +1,25 @@
+From: Joel Becker <joel.becker@oracle.com>
+Date: Mon, 20 Oct 2008 18:24:03 -0700
+Subject: ocfs2: Don't return -EFAULT from a corrupt xattr entry.
+
+If the xattr disk structures are corrupt, return -EIO, not -EFAULT.
+
+Signed-off-by: Joel Becker <joel.becker@oracle.com>
+Signed-off-by: Mark Fasheh <mfasheh@suse.com>
+---
+ fs/ocfs2/xattr.c |    2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
+Index: linux-2.6.27-ocfs2/fs/ocfs2/xattr.c
+===================================================================
+--- linux-2.6.27-ocfs2.orig/fs/ocfs2/xattr.c
++++ linux-2.6.27-ocfs2/fs/ocfs2/xattr.c
+@@ -1239,7 +1239,7 @@ static int ocfs2_xattr_set_entry(struct
+       free = min_offs - ((void *)last - xs->base) - sizeof(__u32);
+       if (free < 0)
+-              return -EFAULT;
++              return -EIO;
+       if (!xs->not_found) {
+               size_t size = 0;