httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c...@apache.org
Subject svn commit: r240297 - /httpd/httpd/trunk/support/htcacheclean.c
Date Fri, 26 Aug 2005 17:54:20 GMT
Author: colm
Date: Fri Aug 26 10:54:18 2005
New Revision: 240297

URL: http://svn.apache.org/viewcvs?rev=240297&view=rev
Log:

Allow htcacheclean to deal in gigabytes.


Modified:
    httpd/httpd/trunk/support/htcacheclean.c

Modified: httpd/httpd/trunk/support/htcacheclean.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/support/htcacheclean.c?rev=240297&r1=240296&r2=240297&view=diff
==============================================================================
--- httpd/httpd/trunk/support/htcacheclean.c (original)
+++ httpd/httpd/trunk/support/htcacheclean.c Fri Aug 26 10:54:18 2005
@@ -63,6 +63,7 @@
 #define SECS_PER_MIN  60
 #define KBYTE         1024
 #define MBYTE         1048576
+#define GBYTE         1073741824
 
 #define DIRINFO (APR_FINFO_MTIME|APR_FINFO_SIZE|APR_FINFO_TYPE|APR_FINFO_LINK)
 
@@ -873,6 +874,9 @@
                         }
                         else if ((*end == 'M' || *end == 'm') && !end[1]) {
                             max *= MBYTE;
+                        }
+                        else if ((*end == 'G' || *end == 'g') && !end[1]) {
+                            max *= GBYTE;
                         }
                         else if (*end &&        /* neither empty nor [Bb] */
                                  ((*end != 'B' && *end != 'b') || end[1])) {



Mime
View raw message