[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: CVS commit: src/sys/coda
christos%zoulas.com@localhost (Christos Zoulas) wrote:
> On Nov 23, 6:14pm, rmind%netbsd.org@localhost (Mindaugas Rasiukevicius)
> -- Subject: Re: CVS commit: src/sys/coda
> | Although this is correct, TAILQ_END(&mountlist) *suggests* access of
> | mountlist. If it would be true, it would be unlocked and buggy access.
> | Why not just "return mp;" ?
> | It seems to me that TAILQ_END() makes the code more missleading without
> | doing any good. What was the rationale behind adding and using it?
> I think it was provided so that the macros look the same across different
> ADT's. Don't shoot the messenger, I did not add it. But I will fix the
> locking non-issue...
Revision 1.54 of queue.h shows you. Thanks for improving it, but I still
do not see the benefit of:
mp = mp == TAILQ_END(&mountlist) ? NULL : mp;
Everybody understood NULL, so why obfuscate the code?
Main Index |
Thread Index |