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 Summary: mod_mem_cache: signal Floating point exception (8) Product: Apache httpd-2 Version: 2.2.2 Platform: Other OS/Version: All Status: NEW Severity: normal Priority: P2 Component: mod_cache AssignedTo: [email protected] ReportedBy: [EMAIL PROTECTED] When caching zero byte file with GDSF removal algorithm and 0 MCacheMinObjectSize in mod_mem_cache, Apache will get [notice] child pid 2230 exit signal Floating point exception (8). Solutions could be 1. 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:12:56.594483296 +0800 @@ -199,7 +199,7 @@ cache_object_t *obj = (cache_object_t *)a; mem_cache_object_t *mobj = obj->vobj; - if (mobj->priority == 0) + if (mobj->priority == 0 && mobj->m_len != 0) mobj->priority = queue_clock - (long)(mobj->total_refs*1000 / mobj->m_len); 2. Or set MCacheMinObjectSize greater than 0 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; return NULL; } static const char Which one is better? Any comments? -- 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]
