subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kot...@apache.org
Subject svn commit: r1804822 - /subversion/trunk/subversion/mod_dav_svn/repos.c
Date Fri, 11 Aug 2017 16:52:32 GMT
Author: kotkov
Date: Fri Aug 11 16:52:32 2017
New Revision: 1804822

URL: http://svn.apache.org/viewvc?rev=1804822&view=rev
Log:
Following up on r1803899, properly negotiate the svndiff version when a
client indicates the preference of svndiff2 format, but the compression
is disabled on the server.

In this case, the server configuration should override the client's
preference (and this is how Subversion 1.9 worked), so tweak the
negotiation scheme so that the server would always be use uncompressed
svndiff0 format with "SVNCompressionLevel 0".

* subversion/mod_dav_svn/repos.c
  (negotiate_encoding_prefs): Add special handling for compression level 0.

Modified:
    subversion/trunk/subversion/mod_dav_svn/repos.c

Modified: subversion/trunk/subversion/mod_dav_svn/repos.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/mod_dav_svn/repos.c?rev=1804822&r1=1804821&r2=1804822&view=diff
==============================================================================
--- subversion/trunk/subversion/mod_dav_svn/repos.c (original)
+++ subversion/trunk/subversion/mod_dav_svn/repos.c Fri Aug 11 16:52:32 2017
@@ -1791,7 +1791,13 @@ negotiate_encoding_prefs(request_rec *r,
         accepts_svndiff2 = TRUE;
     }
 
-  if (accepts_svndiff2 && dav_svn__get_compression_level(r) == 1)
+  if (dav_svn__get_compression_level(r) == 0)
+    {
+      /* If the compression is disabled on the server, use the uncompressed
+       * svndiff0 format, which we assume is always supported. */
+      *svndiff_version = 0;
+    }
+  else if (accepts_svndiff2 && dav_svn__get_compression_level(r) == 1)
     {
       /* Enable svndiff2 if the client can read it, and if the server-side
        * compression level is set to 1.  Svndiff2 offers better speed and



Mime
View raw message