httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ben Laurie <...@algroup.co.uk>
Subject Re: cvs commit: apache-1.3/src/ap ap_strtol.c
Date Tue, 18 Jun 2002 22:47:28 GMT
jim@apache.org wrote:
> jim         2002/06/17 19:07:00
> 
>   Modified:    src/ap   ap_strtol.c
>   Log:
>   Just in case, handle LONG_* if limits doesn't have 'em
>   
>   Revision  Changes    Path
>   1.4       +6 -0      apache-1.3/src/ap/ap_strtol.c
>   
>   Index: ap_strtol.c
>   ===================================================================
>   RCS file: /home/cvs/apache-1.3/src/ap/ap_strtol.c,v
>   retrieving revision 1.3
>   retrieving revision 1.4
>   diff -u -r1.3 -r1.4
>   --- ap_strtol.c	18 Jun 2002 01:19:46 -0000	1.3
>   +++ ap_strtol.c	18 Jun 2002 02:07:00 -0000	1.4
>   @@ -94,6 +94,12 @@
>    #include <stdlib.h>
>    #include "ap_ctype.h"
>    
>   +#ifndef LONG_MAX
>   +#define LONG_MAX  2147483647
>   +#endif
>   +#ifndef LONG_MIN
>   +#define LONG_MIN  (-2147483647-1)
>   +#endif

They're so much more readable in hex:

#ifndef LONG_MAX
#define LONG_MAX  0x7fffffffL
#endif
#ifndef LONG_MIN
#define LONG_MIN  0x80000000L
#endif

Cheers,

Ben.

-- 
http://www.apache-ssl.org/ben.html       http://www.thebunker.net/

"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


Mime
View raw message