subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rhuij...@apache.org
Subject svn commit: r1588778 - /subversion/trunk/subversion/mod_dav_svn/repos.c
Date Sun, 20 Apr 2014 15:12:24 GMT
Author: rhuijben
Date: Sun Apr 20 15:12:24 2014
New Revision: 1588778

URL: http://svn.apache.org/r1588778
Log:
* subversion/mod_dav_svn/repos.c
  (do_out_of_date_check): Following up on r1588772, use the transaction BASE
    revision for checks, not HEAD. The comparison between these is already
    handled in the merge phase and would make the behavior different between
    the different ra layers.

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=1588778&r1=1588777&r2=1588778&view=diff
==============================================================================
--- subversion/trunk/subversion/mod_dav_svn/repos.c (original)
+++ subversion/trunk/subversion/mod_dav_svn/repos.c Sun Apr 20 15:12:24 2014
@@ -1829,27 +1829,18 @@ do_out_of_date_check(dav_resource_combin
              For now I would say reporting out of date in a few too many
              cases is safer than not reporting out of date when we should.
        */
-      svn_revnum_t youngest;
-      svn_fs_root_t *youngest_root;
+      svn_revnum_t txn_base_rev;
+      svn_fs_root_t *txn_base_root;
       svn_fs_root_t *rev_root;
       svn_fs_node_relation_t node_relation;
 
-      serr = svn_fs_youngest_rev(&youngest, comb->res.info->repos->fs,
-                                 r->pool);
-      if (serr != NULL)
-        {
-          return dav_svn__convert_err(serr, HTTP_INTERNAL_SERVER_ERROR,
-                                      "Could not determine the youngest "
-                                      "revision for verification against "
-                                      "the baseline being checked out",
-                                      r->pool);
-        }
+      txn_base_rev = svn_fs_txn_base_revision(comb->res.info->root.txn);
 
-      if (comb->priv.version_name == youngest)
-        return NULL; /* Easy out: we commit against HEAD */
+      if (comb->priv.version_name == txn_base_rev)
+        return NULL; /* Easy out: Nothing changed */
 
-      serr = svn_fs_revision_root(&youngest_root, comb->res.info->repos->fs,
-                                  youngest, r->pool);
+      serr = svn_fs_revision_root(&txn_base_root, comb->res.info->repos->fs,
+                                  txn_base_rev, r->pool);
 
       if (serr != NULL)
         {
@@ -1872,12 +1863,12 @@ do_out_of_date_check(dav_resource_combin
 
       serr = svn_fs_node_relation(&node_relation, rev_root,
                                   comb->priv.repos_path,
-                                  youngest_root,
+                                  txn_base_root,
                                   comb->priv.repos_path,
                                   r->pool);
 
       svn_fs_close_root(rev_root);
-      svn_fs_close_root(youngest_root);
+      svn_fs_close_root(txn_base_root);
 
       if (serr != NULL)
         {



Mime
View raw message