[squid-dev] [PATCH] Http::ProtocolVersion update

Kinkie gkinkie at gmail.com
Sun Dec 7 13:00:49 UTC 2014


There are a few changes due to spacing differences, but i'm OK with it. +1.

On Sun, Dec 7, 2014 at 7:56 AM, Amos Jeffries <squid3 at treenet.co.nz> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> As mentioned by Alex in the FTP server addition the
> Http::ProtocolVersion(*) does not work sufficiently well as a class
> hierarchy and should be re-implemented as global functions.
>
> This patch does that re-implementation.
>
> Convert Http::ProtocolVersion to two functions:
>
> * Http::ProtocolVersion() providing the default Squid HTTP version
> level, and
>
> * Http::ProtocolVersion(unsigned, unsigned) providing the HTTP version
> details for the given level.
>
> NP: using two overloaded functions instead of one with default
> parameter values because with HTTP/0.x and HTTP/2.x we cannot safely
> default just the minor value. ie. using two functions prevents
> mistakenly using HTTP/2.1, HTTP/0.1 or HTTP/1.0 if the second
> parameter is omitted.
>
> All variables must now be of type AnyP::ProtocolVersion, and should be
> constructed from an appropriate Foo::ProtocolVersion() function.
>
> Amos
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v2.0.22 (MingW32)
>
> iQEcBAEBAgAGBQJUg/oWAAoJELJo5wb/XPRjWkIIALNtUpyqnQohpye5vzZvTdaK
> Vib1f0kas2YBURCrtYvLmwt5KIRVsKiwcyofIL0M2l2OEr2ptJhq5Gw2oHAcNZTb
> WSN9CmZ+WVR+NBLcSKbKN+tppFTlN9VAgMlRiz1qcFjG4y+mHSBsZiXj9obmp4BJ
> avffJHy/5H9tU78c2jTEe487rsIY+jVUcO6yk5FmhjIQ9oi3nEb4SgHs6gTYdTT5
> dsQTqaBaMr6wmWGF1FVWiOAvJktEtOyUqFjaVRq3V0Y++XfZH9eWJedpGxtMNvUQ
> gOrw5FwcGSTPKTGJlb9hXl2YqmnrXNNlBHcsbD5vC2bnB7xnZ7M7Hm5oeU9Kg/o=
> =J2dr
> -----END PGP SIGNATURE-----
>
> _______________________________________________
> squid-dev mailing list
> squid-dev at lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-dev
>



-- 
    Francesco


More information about the squid-dev mailing list