subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From phi...@apache.org
Subject svn commit: r1609499 - in /subversion/trunk/subversion: libsvn_ra/ra_loader.c libsvn_ra_serf/serf.c
Date Thu, 10 Jul 2014 16:48:44 GMT
Author: philip
Date: Thu Jul 10 16:48:44 2014
New Revision: 1609499

URL: http://svn.apache.org/r1609499
Log:
Move the setting of SVN_AUTH_PARAM_SERVER_GROUP from libsvn_ra_serf
to libsvn_ra so that it applies to all RA layers.  This fixes issue
4512: config server groups should work with the svn:// protocol.

* subversion/libsvn_ra/ra_loader.c
  (svn_ra_open4): Set SVN_AUTH_PARAM_SERVER_GROUP.

* subversion/libsvn_ra_serf/serf.c
  (load_config): No need to find group or set SVN_AUTH_PARAM_SERVER_GROUP.

Modified:
    subversion/trunk/subversion/libsvn_ra/ra_loader.c
    subversion/trunk/subversion/libsvn_ra_serf/serf.c

Modified: subversion/trunk/subversion/libsvn_ra/ra_loader.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_ra/ra_loader.c?rev=1609499&r1=1609498&r2=1609499&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_ra/ra_loader.c (original)
+++ subversion/trunk/subversion/libsvn_ra/ra_loader.c Thu Jul 10 16:48:44 2014
@@ -264,7 +264,7 @@ svn_error_t *svn_ra_open4(svn_ra_session
   const struct ra_lib_defn *defn;
   const svn_ra__vtable_t *vtable = NULL;
   svn_config_t *servers = NULL;
-  const char *server_group;
+  const char *server_group = NULL;
   apr_uri_t repos_URI;
   apr_status_t apr_err;
   svn_error_t *err;
@@ -428,6 +428,10 @@ svn_error_t *svn_ra_open4(svn_ra_session
       if (! store_auth_creds)
         svn_auth_set_parameter(callbacks->auth_baton,
                                SVN_AUTH_PARAM_NO_AUTH_CACHE, "");
+
+      if (server_group)
+        svn_auth_set_parameter(callbacks->auth_baton,
+                               SVN_AUTH_PARAM_SERVER_GROUP, server_group);
     }
 
   /* Find the library. */

Modified: subversion/trunk/subversion/libsvn_ra_serf/serf.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_ra_serf/serf.c?rev=1609499&r1=1609498&r2=1609499&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_ra_serf/serf.c (original)
+++ subversion/trunk/subversion/libsvn_ra_serf/serf.c Thu Jul 10 16:48:44 2014
@@ -255,12 +255,8 @@ load_config(svn_ra_serf__session_t *sess
                                SERF_LOG_INFO));
 #endif
 
-  if (config)
-    server_group = svn_config_find_group(config,
-                                         session->session_url.hostname,
-                                         SVN_CONFIG_SECTION_GROUPS, pool);
-  else
-    server_group = NULL;
+  server_group = svn_auth_get_parameter(session->wc_callbacks->auth_baton,
+                                        SVN_AUTH_PARAM_SERVER_GROUP);
 
   if (server_group)
     {
@@ -271,9 +267,6 @@ load_config(svn_ra_serf__session_t *sess
       svn_config_get(config, &timeout_str, server_group,
                      SVN_CONFIG_OPTION_HTTP_TIMEOUT, timeout_str);
 
-      svn_auth_set_parameter(session->wc_callbacks->auth_baton,
-                             SVN_AUTH_PARAM_SERVER_GROUP, server_group);
-
       /* Load the group proxy server settings, overriding global
          settings.  We intentionally ignore 'http-proxy-exceptions'
          here because, well, if this site was an exception, why is



Mime
View raw message