mtd/fs/jffs2 nodelist.h,1.119,1.120
havasi at infradead.org
havasi at infradead.org
Thu Oct 7 11:11:57 EDT 2004
Update of /home/cvs/mtd/fs/jffs2
In directory phoenix.infradead.org:/home/havasi/mtd/fs/jffs2
Modified Files:
nodelist.h
Log Message:
modify ACCT_PARANOIA_CHECK to handle if the jeb->last_node
not right whithout kernel "NULL pointer dereference"
Index: nodelist.h
===================================================================
RCS file: /home/cvs/mtd/fs/jffs2/nodelist.h,v
retrieving revision 1.119
retrieving revision 1.120
diff -u -r1.119 -r1.120
--- nodelist.h 26 May 2004 12:28:12 -0000 1.119
+++ nodelist.h 7 Oct 2004 15:11:54 -0000 1.120
@@ -281,9 +281,14 @@
else if (!ref_obsolete(ref2)) \
my_used_size += ref_totlen(c, jeb, ref2); \
if (unlikely((!ref2->next_phys) != (ref2 == jeb->last_node))) { \
- printk("ref for node at %p (phys %08x) has next_phys->%p (%08x), last_node->%p (phys %08x)\n", \
- ref2, ref_offset(ref2), ref2->next_phys, ref_offset(ref2->next_phys), \
- jeb->last_node, ref_offset(jeb->last_node)); \
+ if (!ref2->next_phys) \
+ printk("ref for node at %p (phys %08x) has next_phys->%p (----), last_node->%p (phys %08x)\n", \
+ ref2, ref_offset(ref2), ref2->next_phys, \
+ jeb->last_node, ref_offset(jeb->last_node)); \
+ else \
+ printk("ref for node at %p (phys %08x) has next_phys->%p (%08x), last_node->%p (phys %08x)\n", \
+ ref2, ref_offset(ref2), ref2->next_phys, ref_offset(ref2->next_phys), \
+ jeb->last_node, ref_offset(jeb->last_node)); \
paranoia_failed_dump(jeb); \
BUG(); \
} \
More information about the linux-mtd-cvs
mailing list