[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bug in nodemgmt.c?



On Wed, 2004-10-06 at 17:52 +0200, Ferenc Havasi wrote:
> Dear All,
> 
> During the final testing of my model-based-patch I think I found a bug 
> in fs/jffs2/nodemgmt.c
> 
> In function jffs2_mark_node_obsolete() at the part of "Merge with the 
> next node in the physical list, if there is one and if it's also 
> obsolete" there is a comment: "we don't need to check jeb->last_node".
> 
> Is it right? Because I think we should deal with jeb->last_node here, or 
> should not use "D1(ACCT_PARANOIA_CHECK(jeb));" statement any more, but 
> now it is used by also this function.
> 
> ACCT_PARANOIA_CHECK walk throught the nodes (using next_phys) and if at 
> the end of the list is not equals to jeb->last_node than halts. 
> Unfortunatelly with simple "NULL pointer dereference" without any 
> usefull messages.
> 
> Just say I'm right and I fix this problem in the CVS (a single
> "if (jeb->last_node == n) jeb->last_node=ref;" line into nodemgmt.c and 
> better message in ACCT_PARANOIA_CHECK).

I think you're probably right. √ėyvind, didn't we come across this
already? Did you commit an older version of your patch?

-- 
dwmw2


To unsubscribe from this list: send the line "unsubscribe jffs-dev" in
the body of a message to majordomo@xxxxxxx.com