DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=40576>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=40576





------- Additional Comments From [EMAIL PROTECTED]  2006-10-30 18:23 -------
(In reply to comment #2)
> From a first glance 2) seems to be more reasonable to me as I currently cannot
> see a reason to cache objects of size 0 :-). Regarding your check of the value
> set by MCacheMinObjectSize you should return an error is the value is invalid.

Thanks for comments. I also think 2) is more reasonable :-)
Based on your comments, I added the error return value. 

diff -ru httpd-2.2.2/modules/cache/mod_mem_cache.c httpd-
2.2.2.new/modules/cache/mod_mem_cache.c
--- httpd-2.2.2/modules/cache/mod_mem_cache.c   2006-04-22 09:53:06.000000000 
+0800
+++ httpd-2.2.2.new/modules/cache/mod_mem_cache.c       2006-09-01 
13:49:08.233344008 +0800
@@ -98,7 +98,7 @@
 static mem_cache_conf *sconf;

 #define DEFAULT_MAX_CACHE_SIZE 100*1024
-#define DEFAULT_MIN_CACHE_OBJECT_SIZE 0
+#define DEFAULT_MIN_CACHE_OBJECT_SIZE 1
 #define DEFAULT_MAX_CACHE_OBJECT_SIZE 10000
 #define DEFAULT_MAX_OBJECT_CNT 1009
 #define DEFAULT_MAX_STREAMING_BUFFER_SIZE 100000
@@ -964,7 +964,8 @@
     if (sscanf(arg, "%" APR_SIZE_T_FMT, &val) != 1) {
         return "MCacheMinObjectSize value must be an integer (bytes)";
     }
-    sconf->min_cache_object_size = val;
+    if (val > 0)
+       sconf->min_cache_object_size = val;
+    else
+       return  "MCacheMinObjectSize value must be an positive integer (bytes)";
     return NULL;
 }
 static const char


-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to