You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by Cliff Woolley <cl...@yahoo.com> on 2001/05/19 21:21:07 UTC
Re: cvs commit: apr/memory/unix apr_sms.c
On 19 May 2001 ben@apache.org wrote:
> --- apr_sms.c 2001/05/19 13:53:06 1.3
> +++ apr_sms.c 2001/05/19 15:35:45 1.4
> @@ -193,7 +193,7 @@
> mem_sys->accounting_mem_sys = mem_sys;
>
> if (parent_mem_sys != NULL){
> - if (mem_sys->sibling_mem_sys = parent_mem_sys->child_mem_sys){
> + if ((mem_sys->sibling_mem_sys = parent_mem_sys->child_mem_sys)){
> mem_sys->sibling_mem_sys->ref_mem_sys = &mem_sys->sibling_mem_sys;
> }
> mem_sys->ref_mem_sys = &parent_mem_sys->child_mem_sys;
Just to verify (haven't looked at this section of the code itself yet),
assignment IS what's intended here, right? If so, a ((foo = bar) != NULL)
might make that more clear.
--Cliff
--------------------------------------------------------------
Cliff Woolley
cliffwoolley@yahoo.com
Charlottesville, VA
Re: cvs commit: apr/memory/unix apr_sms.c
Posted by Cliff Woolley <cl...@yahoo.com>.
On Sat, 19 May 2001, Ben Laurie wrote:
> > Just to verify (haven't looked at this section of the code itself yet),
> > assignment IS what's intended here, right? If so, a ((foo = bar) != NULL)
> > might make that more clear.
>
> Good point. I foolishly assumed the assignment was intentional - it
> still looks like it is, but confirmation from someone who knows would be
> good. I agree with != NULL if it is so.
Looking closer, I agree. Confirmation would still be nice, but I
agree that it looks intentional. So I'll go ahead and throw a !=NULL in
there.
--Cliff
--------------------------------------------------------------
Cliff Woolley
cliffwoolley@yahoo.com
Charlottesville, VA
Re: cvs commit: apr/memory/unix apr_sms.c
Posted by Ben Laurie <be...@algroup.co.uk>.
Cliff Woolley wrote:
>
> On 19 May 2001 ben@apache.org wrote:
>
> > --- apr_sms.c 2001/05/19 13:53:06 1.3
> > +++ apr_sms.c 2001/05/19 15:35:45 1.4
> > @@ -193,7 +193,7 @@
> > mem_sys->accounting_mem_sys = mem_sys;
> >
> > if (parent_mem_sys != NULL){
> > - if (mem_sys->sibling_mem_sys = parent_mem_sys->child_mem_sys){
> > + if ((mem_sys->sibling_mem_sys = parent_mem_sys->child_mem_sys)){
> > mem_sys->sibling_mem_sys->ref_mem_sys = &mem_sys->sibling_mem_sys;
> > }
> > mem_sys->ref_mem_sys = &parent_mem_sys->child_mem_sys;
>
> Just to verify (haven't looked at this section of the code itself yet),
> assignment IS what's intended here, right? If so, a ((foo = bar) != NULL)
> might make that more clear.
Good point. I foolishly assumed the assignment was intentional - it
still looks like it is, but confirmation from someone who knows would be
good. I agree with != NULL if it is so.
Cheers,
Ben.
--
http://www.apache-ssl.org/ben.html
"There is no limit to what a man can do or how far he can go if he
doesn't mind who gets the credit." - Robert Woodruff