bb: approve

+1. Sane, and correct, and also matches what Squid-2 is doing.

Hmm.. wonder how that got lost in Squid-3. The change in squid-2 is very
old (3 may 2000). Investigating. Right, got lost in refactoring
(revision 5998). The comment from when this was fixed in Squid-2 is even
left just not visible in your patch, but is there a couple of lines
before where you moved back the tlv composing.

Regards
Henrik

ons 2009-09-02 klockan 00:05 -0600 skrev Alex Rousskov:
> Fixed entry size calculation for the max-size cache_dir selection
> algorithms.
> 
> There were two sides of this bug:
> 
> In src/store_swapout.cc, we must create metadata earlier because
> storeCreate() needs swap_hdr_sz. With swap_hdr_sz unknown at the time of
> storeCreate(), the SwapDir selection algorithms may select SwapDirs that
> should not really take the entry as the real storage size (with the
> metadata swap_hdr_sz) would exceed the store slot size.
> 
> In src/store_dir.cc, we must add the metadata size before looking for
> cache_dirs that accept objsize. Only the "new"
> storeDirSelectSwapDirRoundRobin selection scheme was affected.
> 
> HTH,
> 
> Alex.
> P.S. I do not have a version of this patch generated against trunk, but
> I hope it applies easily.
> 

Reply via email to