Bug 39351

Summary: Continue early if bucket length is zero
Product: Apache httpd-2 Reporter: Davi Arnaut <davi>
Component: mod_cache_disk / mod_disk_cacheAssignee: Apache HTTPD Bugs Mailing List <bugs>
Status: RESOLVED FIXED    
Severity: trivial Keywords: FixedInTrunk, PatchAvailable
Priority: P2    
Version: 2.5-HEAD   
Target Milestone: ---   
Hardware: Other   
OS: other   
Attachments: Continue early if bucket length is zero

Description Davi Arnaut 2006-04-19 14:39:36 UTC
Continue early if bucket length is zero, skipping a few instructions in the code
path.
Comment 1 Davi Arnaut 2006-04-19 14:40:12 UTC
Created attachment 18134 [details]
Continue early if bucket length is zero
Comment 2 Christophe JAILLET 2013-02-02 07:22:17 UTC
This is actually in trunk, in mod_cache_disk which replaced mod_disk_cache in 2.4.x.

This was done in r1002832.


@@ -1131,6 +1122,33 @@
             return rv;
         }
+        /* don't write empty buckets to the cache */
+        if (!length) {
+            continue;
+        }


So closing this report.