subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From julianf...@apache.org
Subject svn commit: r1428592 - in /subversion/trunk/subversion/libsvn_wc: copy.c wc_db.h wc_db_pristine.c
Date Thu, 03 Jan 2013 20:55:24 GMT
Author: julianfoad
Date: Thu Jan  3 20:55:24 2013
New Revision: 1428592

URL: http://svn.apache.org/viewvc?rev=1428592&view=rev
Log:
Remove an unused parameter.

* subversion/libsvn_wc/wc_db.h
  (svn_wc__db_pristine_transfer): Remove the unused 'checksum' parameter.

* subversion/libsvn_wc/wc_db_pristine.c
  (pristine_transfer_txn2): Unconditionally find the checksum, as we know it
    is not passed in.
  (svn_wc__db_pristine_transfer): Remove the unused 'checksum' parameter.

* subversion/libsvn_wc/copy.c
  (copy_versioned_file): Adjust caller.

Modified:
    subversion/trunk/subversion/libsvn_wc/copy.c
    subversion/trunk/subversion/libsvn_wc/wc_db.h
    subversion/trunk/subversion/libsvn_wc/wc_db_pristine.c

Modified: subversion/trunk/subversion/libsvn_wc/copy.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/copy.c?rev=1428592&r1=1428591&r2=1428592&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/copy.c (original)
+++ subversion/trunk/subversion/libsvn_wc/copy.c Thu Jan  3 20:55:24 2013
@@ -197,7 +197,7 @@ copy_versioned_file(svn_wc__db_t *db,
      ensure the destination WC has a copy of the pristine text. */
 
   if (copy_pristine_file)
-    SVN_ERR(svn_wc__db_pristine_transfer(db, src_abspath, NULL,
+    SVN_ERR(svn_wc__db_pristine_transfer(db, src_abspath,
                                          dst_op_root_abspath,
                                          cancel_func, cancel_baton,
                                          scratch_pool));

Modified: subversion/trunk/subversion/libsvn_wc/wc_db.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/wc_db.h?rev=1428592&r1=1428591&r2=1428592&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/wc_db.h (original)
+++ subversion/trunk/subversion/libsvn_wc/wc_db.h Thu Jan  3 20:55:24 2013
@@ -995,12 +995,10 @@ svn_wc__db_pristine_get_sha1(const svn_c
 
 
 /* If necessary transfers the PRISTINE file of SRC_LOCAL_ABSPATH to the
-   working copy identified by DST_WRI_ABSPATH. If CHECKSUM is not NULL, use
-   CHECKSUM to identify which pristine file to transfer. */
+   working copy identified by DST_WRI_ABSPATH. */
 svn_error_t *
 svn_wc__db_pristine_transfer(svn_wc__db_t *db,
                              const char *src_local_abspath,
-                             const svn_checksum_t *checksum,
                              const char *dst_wri_abspath,
                              svn_cancel_func_t cancel_func,
                              void *cancel_baton,

Modified: subversion/trunk/subversion/libsvn_wc/wc_db_pristine.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/wc_db_pristine.c?rev=1428592&r1=1428591&r2=1428592&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/wc_db_pristine.c (original)
+++ subversion/trunk/subversion/libsvn_wc/wc_db_pristine.c Thu Jan  3 20:55:24 2013
@@ -544,26 +544,19 @@ pristine_transfer_txn2(void *baton, svn_
   svn_sqlite__stmt_t *stmt;
   svn_boolean_t have_row;
 
-  /* Get the right checksum if it wasn't passed */
-  if (!tb->sha1_checksum)
-    {
-      SVN_ERR(svn_sqlite__get_statement(&stmt, tb->src_wcroot->sdb,
-                                        STMT_SELECT_NODE_INFO));
-
-      SVN_ERR(svn_sqlite__bindf(stmt, "is",
-                                 tb->src_wcroot->wc_id, local_relpath));
-
-      SVN_ERR(svn_sqlite__step(&have_row, stmt));
-
-      if (have_row)
-        SVN_ERR(svn_sqlite__column_checksum(&(tb->sha1_checksum), stmt, 6,
-                                            scratch_pool));
-
-      SVN_ERR(svn_sqlite__reset(stmt));
+  /* Get the SHA1 checksum */
+  SVN_ERR(svn_sqlite__get_statement(&stmt, tb->src_wcroot->sdb,
+                                    STMT_SELECT_NODE_INFO));
+  SVN_ERR(svn_sqlite__bindf(stmt, "is",
+                            tb->src_wcroot->wc_id, local_relpath));
+  SVN_ERR(svn_sqlite__step(&have_row, stmt));
+  if (have_row)
+    SVN_ERR(svn_sqlite__column_checksum(&(tb->sha1_checksum), stmt, 6,
+                                        scratch_pool));
+  SVN_ERR(svn_sqlite__reset(stmt));
 
-      if (!tb->sha1_checksum)
-        return SVN_NO_ERROR; /* Nothing to transfer */
-    }
+  if (!tb->sha1_checksum)
+    return SVN_NO_ERROR; /* Nothing to transfer */
 
   /* Check if we have the pristine in the destination wcroot */
   SVN_ERR(svn_sqlite__get_statement(&stmt, tb->dst_wcroot->sdb,
@@ -661,7 +654,6 @@ pristine_transfer_txn1(void *baton, svn_
 svn_error_t *
 svn_wc__db_pristine_transfer(svn_wc__db_t *db,
                              const char *src_local_abspath,
-                             const svn_checksum_t *checksum,
                              const char *dst_wri_abspath,
                              svn_cancel_func_t cancel_func,
                              void *cancel_baton,



Mime
View raw message