--------------------- PatchSet 5175 Date: 2007/08/07 06:32:10 Author: chtsanti Branch: squid3-largeobj Tag: (none) Log: Converting Config.quickAbort.min and Config.quickAbort.max back to accept by default values in kilobytes and keep values in kilobytes, using 64bit integers. Members: src/cache_cf.cc:1.79.4.4->1.79.4.5 src/cf.data.pre:1.117.2.4->1.117.2.5 src/store_client.cc:1.29.2.11->1.29.2.12 Index: squid3/src/cache_cf.cc =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/cache_cf.cc,v retrieving revision 1.79.4.4 retrieving revision 1.79.4.5 diff -u -r1.79.4.4 -r1.79.4.5 --- squid3/src/cache_cf.cc 22 Jul 2007 08:50:28 -0000 1.79.4.4 +++ squid3/src/cache_cf.cc 7 Aug 2007 06:32:10 -0000 1.79.4.5 @@ -1,6 +1,6 @@ /* - * $Id: cache_cf.cc,v 1.79.4.4 2007/07/22 08:50:28 chtsanti Exp $ + * $Id: cache_cf.cc,v 1.79.4.5 2007/08/07 06:32:10 chtsanti Exp $ * * DEBUG: section 3 Configuration File Parsing * AUTHOR: Harvest Derived @@ -2331,6 +2331,12 @@ } static void +dump_kb_int64_t(StoreEntry * entry, const char *name, int64_t var) +{ + storeAppendPrintf(entry, "%s %"PRId64" %s\n", name, var, B_KBYTES_STR); +} + +static void parse_size_t(size_t * var) { int i; @@ -2345,15 +2351,21 @@ } static void +parse_kb_size_t(size_t * var) +{ + parseBytesLine(var, B_KBYTES_STR); +} + +static void parse_b_int64_t(int64_t * var) { parseBytesLine64(var, B_BYTES_STR); } static void -parse_kb_size_t(size_t * var) +parse_kb_int64_t(int64_t * var) { - parseBytesLine(var, B_KBYTES_STR); + parseBytesLine64(var, B_KBYTES_STR); } static void @@ -2372,6 +2384,7 @@ #define free_kb_size_t free_size_t #define free_mb_size_t free_size_t #define free_gb_size_t free_size_t +#define free_kb_int64_t free_b_int64_t static void dump_ushort(StoreEntry * entry, const char *name, u_short var) Index: squid3/src/cf.data.pre =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/cf.data.pre,v retrieving revision 1.117.2.4 retrieving revision 1.117.2.5 diff -u -r1.117.2.4 -r1.117.2.5 --- squid3/src/cf.data.pre 1 Aug 2007 20:41:47 -0000 1.117.2.4 +++ squid3/src/cf.data.pre 7 Aug 2007 06:32:11 -0000 1.117.2.5 @@ -1,6 +1,6 @@ # -# $Id: cf.data.pre,v 1.117.2.4 2007/08/01 20:41:47 chtsanti Exp $ +# $Id: cf.data.pre,v 1.117.2.5 2007/08/07 06:32:11 chtsanti Exp $ # # SQUID Web Proxy Cache http://www.squid-cache.org/ # ---------------------------------------------------------- @@ -2212,15 +2212,15 @@ DOC_END NAME: quick_abort_min -COMMENT: (bytes) -TYPE: b_int64_t +COMMENT: (KB) +TYPE: kb_int64_t DEFAULT: 16 KB LOC: Config.quickAbort.min DOC_NONE NAME: quick_abort_max -COMMENT: (bytes) -TYPE: b_int64_t +COMMENT: (KB) +TYPE: kb_int64_t DEFAULT: 16 KB LOC: Config.quickAbort.max DOC_NONE Index: squid3/src/store_client.cc =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/store_client.cc,v retrieving revision 1.29.2.11 retrieving revision 1.29.2.12 diff -u -r1.29.2.11 -r1.29.2.12 --- squid3/src/store_client.cc 1 Aug 2007 20:41:47 -0000 1.29.2.11 +++ squid3/src/store_client.cc 7 Aug 2007 06:32:15 -0000 1.29.2.12 @@ -1,6 +1,6 @@ /* - * $Id: store_client.cc,v 1.29.2.11 2007/08/01 20:41:47 chtsanti Exp $ + * $Id: store_client.cc,v 1.29.2.12 2007/08/07 06:32:15 chtsanti Exp $ * * DEBUG: section 90 Storage Manager Client-Side Interface * AUTHOR: Duane Wessels @@ -783,12 +783,12 @@ return 1; } - if ((expectlen - curlen) < Config.quickAbort.min) { + if ((expectlen - curlen) < (Config.quickAbort.min << 10)) { debugs(90, 3, "CheckQuickAbort2: NO only little more left"); return 0; } - if ((expectlen - curlen) > Config.quickAbort.max) { + if ((expectlen - curlen) > (Config.quickAbort.max << 10)) { debugs(90, 3, "CheckQuickAbort2: YES too much left to go"); return 1; }