------------------------------------------------------------ revno: 12641 revision-id: squid3@treenet.co.nz-20131024153623-eg6r3fkvv5tttmlc parent: squid3@treenet.co.nz-20131024153508-ya93czmbpm43l00x author: Nathan Hoad committer: Amos Jeffries branch nick: 3.3 timestamp: Thu 2013-10-24 09:36:23 -0600 message: Append Connection:close to OPTIONS requests when icap_persistent_connections is off. This brings OPTIONS requests behavior inline with REQMOD and RESPMOD. ------------------------------------------------------------ # Bazaar merge directive format 2 (Bazaar 0.90) # revision_id: squid3@treenet.co.nz-20131024153623-eg6r3fkvv5tttmlc # target_branch: http://bzr.squid-cache.org/bzr/squid3/3.3 # testament_sha1: 8d1edb2491048123a69410b0467566f4b34b6474 # timestamp: 2013-10-24 15:46:59 +0000 # source_branch: http://bzr.squid-cache.org/bzr/squid3/3.3 # base_revision_id: squid3@treenet.co.nz-20131024153508-\ # ya93czmbpm43l00x # # Begin patch === modified file 'src/adaptation/icap/OptXact.cc' --- src/adaptation/icap/OptXact.cc 2012-08-31 16:57:39 +0000 +++ src/adaptation/icap/OptXact.cc 2013-10-24 15:36:23 +0000 @@ -51,6 +51,10 @@ buf.Printf("OPTIONS " SQUIDSTRINGPH " ICAP/1.0\r\n", SQUIDSTRINGPRINT(uri)); const String host = s.cfg().host; buf.Printf("Host: " SQUIDSTRINGPH ":%d\r\n", SQUIDSTRINGPRINT(host), s.cfg().port); + + if (!TheConfig.reuse_connections) + buf.Printf("Connection: close\r\n"); + if (TheConfig.allow206_enable) buf.Printf("Allow: 206\r\n"); buf.append(ICAP::crlf, 2);