apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Greg Stein <gst...@lyra.org>
Subject Re: [PATCH] bucket debugging.
Date Wed, 13 Aug 2003 08:53:43 GMT
On Wed, Aug 13, 2003 at 02:08:57AM -0400, Cliff Woolley wrote:
> On Tue, 12 Aug 2003, Greg Stein wrote:
> 
> > > +    while (curr) {
> > > +        if (node == curr) {
> > > +            return 0;
> > > +        }
> > > +        curr = curr->next;
> > > +    }
> > > +    return 1;
> >
> > Forget the return code. Just stick an abort() in here.
> 
> return 0 to pop the assert, abort, same difference.  :)  But sure, I'll do
> it that way, why not.

Sure, six of one, half-dozen of another. But the way I saw it was that the
return code was superfluous since the only caller was your macro. Thus, you
can just shift all the [abort] logic into the function rather than split
between the func and the macro.

But in any case, having a consistency check on those buggers is Goodness.

Cheers,
-g

-- 
Greg Stein, http://www.lyra.org/

Mime
View raw message