]> Sergey Matveev's repositories - public-inbox.git/commit
wwwstatic: set "Vary: Accept-Encoding" in static gzip response
authorEric Wong <e@yhbt.net>
Sun, 5 Apr 2020 01:28:49 +0000 (01:28 +0000)
committerEric Wong <e@yhbt.net>
Sun, 5 Apr 2020 07:25:07 +0000 (07:25 +0000)
commit6ebcec3add4d6aeff6e3b3eb019a404528c079ec
tree78ea06c68244b3e2be7e2407a6a59d9913c2b8ed
parentf5aa58801122863961bd9a11e9d9c7b691ffca38
wwwstatic: set "Vary: Accept-Encoding" in static gzip response

We don't want to confuse intermediate caches into serving
gzipped content to any clients which can't handle it.  It
probably doesn't matter in practice, though, since every HTTP
client seems to handle "Content-Encoding: gzip" regardless of
whether it was requested or not, though I could expect some
nc/socat/telnet/s_client users being annoyed.

This also matches the behavior of Plack::Middleware::Deflater
and other deflater implementations.
lib/PublicInbox/WwwStatic.pm