httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Richards <p.richa...@elsevier.co.uk>
Subject cvs commit: apache/src mod_proxy.c (fwd)
Date Wed, 03 Jul 1996 14:47:30 GMT
Ben Laurie writes:
 > > 
 > >   --- mod_proxy.c	1996/07/03 03:47:03	1.31
 > >   ***************
 > >   *** 1246,1252 ****
 > >         const char *p, *q;
 > >     
 > >         q = get_time();
 > >   !     p = strerror(errno);
 > >     
 > >         if (err != NULL)
 > >         {
 > >   --- 1246,1252 ----
 > >         const char *p, *q;
 > >     
 > >         q = get_time();
 > >   !     (char *)p = strerror(errno);
 > 
 > This is ridiculous. What warning does this fix?
 > 
 > I do object to fixing invalid warnings (and I find it hard to believe that this
 > one is valid) in the mainline code.

The code is wrong, p should not be a "const char *", it's only used to
pick up the error string from strerror and strerror returns a "char *".

The compiler warning is correct since the variable is not the same type
as the return parameter.


Mime
View raw message