]> git.hungrycats.org Git - linux/commitdiff
[PATCH] UDF oops on inode read failure
authorBen Fennema <bfennema@falcon.csc.calpoly.edu>
Wed, 1 Oct 2003 15:44:15 +0000 (08:44 -0700)
committerLinus Torvalds <torvalds@home.osdl.org>
Wed, 1 Oct 2003 15:44:15 +0000 (08:44 -0700)
This fixes an oops with failed inode reads on UDF

fs/udf/inode.c

index d892081d73abd39e85e5c9074025bf895556b1aa..80fc39b35f52621904edf6228550ac18e138f94c 100644 (file)
@@ -126,7 +126,8 @@ no_delete:
 
 void udf_clear_inode(struct inode *inode)
 {
-       kfree(UDF_I_DATA(inode));
+       if (!is_bad_inode(inode))
+               kfree(UDF_I_DATA(inode));
 }
 
 void udf_discard_prealloc(struct inode * inode)