Sorry, my bad.  I shouldn't be in such a hurry.  I'll fix it right this
time.

Ryan

----------------------------------------------
Ryan Bloom                  [EMAIL PROTECTED]
645 Howard St.              [EMAIL PROTECTED]
San Francisco, CA 

> -----Original Message-----
> From: Cliff Woolley [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, February 26, 2002 4:44 PM
> To: [EMAIL PROTECTED]
> Subject: Re: cvs commit: httpd-2.0/modules/ssl mod_ssl.h
ssl_engine_log.c
> 
> On 27 Feb 2002 [EMAIL PROTECTED] wrote:
> 
> >        /*  determine whether newline should be written */
> >        if (add & SSL_NO_NEWLINE)
> >   -        nstr[0] = NUL;
> >   +        nstr = NUL;
> 
> How can that be right?
> 
> mod_ssl.h:#define NUL '\0'
> 
> So now nstr is a null pointer rather than an empty string (use NULL
not
> NUL, anyway) in this case.
> 
> >        else {
> >   -        nstr[0] = '\n';
> >   -        nstr[1] = NUL;
> >   +        nstr = APR_EOL_STR;
> >        }
> 
> And not a null pointer (a non-empty string) in the other case.
> 
> Won't you segfault in the null pointer case on the sprintf call later?
> 
> --Cliff
> 
> 
> --------------------------------------------------------------
>    Cliff Woolley
>    [EMAIL PROTECTED]
>    Charlottesville, VA
> 
> 


Reply via email to