You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by rh...@apache.org on 2010/07/26 18:37:37 UTC

svn commit: r979350 - in /subversion/trunk/subversion/libsvn_wc: adm_files.c adm_ops.c copy.c status.c update_editor.c workqueue.c workqueue.h

Author: rhuijben
Date: Mon Jul 26 16:37:37 2010
New Revision: 979350

URL: http://svn.apache.org/viewvc?rev=979350&view=rev
Log:
More out-of-db properties and revert file cleanup. There should be no
functional changes, but after this commit three wq operations are
no longer supported as they didn't perform actual work after disabling
the out-of-db properties.

* subversion/libsvn_wc/adm_files.c
  (init_adm_tmp_area): Remove wc-format < 18 code.

* subversion/libsvn_wc/adm_ops.c
  (process_committed_leaf,
   svn_wc_add4): Remove wc < 18 code.

* subversion/libsvn_wc/copy.c
  (copy_versioned_file): Stop making prepare revert wq item and
    remove < 18 code.
  (copy_versioned_dir): Remove wc < 18 code.

* subversion/libsvn_wc/status.c
  (assemble_status): Remove wc < 18 code.

* subversion/libsvn_wc/update_editor.c
  (svn_wc_add_repos_file4): Don't queue prepare revert files wq op.

* subversion/libsvn_wc/workqueue.c
  (OP_PREPARE_REVERT_FILES,
   OP_DELETE,
   OP_WRITE_OLD_PROPS): Remove defines.
  (run_revert): Remove wc < 18 code.
  (run_prepare_revert_files,
   svn_wc__wq_prepare_revert_files,
   run_delete,
   svn_wc__wq_add_delete,
   run_write_old_props,
   svn_wc__wq_build_write_old_props): Remove functions.
  (dispatch_table): Remove OP_PREPARE_REVERT_FILES, OP_DELETE and
    OP_WRITE_OLD_PROPS.

* subversion/libsvn_wc/workqueue.h
  (svn_wc__wq_build_write_old_props,
   svn_wc__wq_prepare_revert_files,
   svn_wc__wq_add_delete): Remove functions.

Modified:
    subversion/trunk/subversion/libsvn_wc/adm_files.c
    subversion/trunk/subversion/libsvn_wc/adm_ops.c
    subversion/trunk/subversion/libsvn_wc/copy.c
    subversion/trunk/subversion/libsvn_wc/status.c
    subversion/trunk/subversion/libsvn_wc/update_editor.c
    subversion/trunk/subversion/libsvn_wc/workqueue.c
    subversion/trunk/subversion/libsvn_wc/workqueue.h

Modified: subversion/trunk/subversion/libsvn_wc/adm_files.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/adm_files.c?rev=979350&r1=979349&r2=979350&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/adm_files.c (original)
+++ subversion/trunk/subversion/libsvn_wc/adm_files.c Mon Jul 26 16:37:37 2010
@@ -544,14 +544,6 @@ init_adm_tmp_area(const char *path, apr_
   /* SVN_WC__ADM_TMP */
   SVN_ERR(make_adm_subdir(path, SVN_WC__ADM_TMP, FALSE, pool));
 
-#if (SVN_WC__VERSION < 18)
-  /* SVN_WC__ADM_TMP/SVN_WC__ADM_PROP_BASE */
-  SVN_ERR(make_adm_subdir(path, SVN_WC__ADM_PROP_BASE, TRUE, pool));
-
-  /* SVN_WC__ADM_TMP/SVN_WC__ADM_PROPS */
-  SVN_ERR(make_adm_subdir(path, SVN_WC__ADM_PROPS, TRUE, pool));
-#endif
-
   return SVN_NO_ERROR;
 }
 
@@ -576,14 +568,6 @@ init_adm(svn_wc__db_t *db,
 
   /** Make subdirectories. ***/
 
-#if (SVN_WC__VERSION < 18)
-  /* SVN_WC__ADM_PROP_BASE */
-  SVN_ERR(make_adm_subdir(local_abspath, SVN_WC__ADM_PROP_BASE, FALSE, pool));
-
-  /* SVN_WC__ADM_PROPS */
-  SVN_ERR(make_adm_subdir(local_abspath, SVN_WC__ADM_PROPS, FALSE, pool));
-#endif
-
   /* SVN_WC__ADM_PRISTINE */
   SVN_ERR(make_adm_subdir(local_abspath, SVN_WC__ADM_PRISTINE, FALSE, pool));
 

Modified: subversion/trunk/subversion/libsvn_wc/adm_ops.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/adm_ops.c?rev=979350&r1=979349&r2=979350&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/adm_ops.c (original)
+++ subversion/trunk/subversion/libsvn_wc/adm_ops.c Mon Jul 26 16:37:37 2010
@@ -160,30 +160,6 @@ process_committed_leaf(svn_wc__db_t *db,
                                 scratch_pool));
     }
 
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-  /* Queue a removal of any "revert" properties now. These correspond to
-     the BASE properties, but hidden by new pristine props in WORKING.
-     Regardless, the commit will be installing new BASE props.  */
-  /* ### this goes away once props are fully in the database  */
-  {
-    const char *revert_props_abspath;
-    svn_skel_t *work_item;
-
-    /* ### this breaks the abstraction of svn_wc__props_delete, but
-       ### screw it. this is transitional code.  */
-    /* ### what happens if the node changes its KIND? should be okay
-       ### since we disallow that today, and props should be in the DB
-       ### by the time that we DO allow that.  */
-    SVN_ERR(svn_wc__prop_path(&revert_props_abspath, local_abspath, kind,
-                              svn_wc__props_revert, scratch_pool));
-
-    SVN_ERR(svn_wc__wq_build_file_remove(&work_item,
-                                         db, revert_props_abspath,
-                                         scratch_pool, scratch_pool));
-    SVN_ERR(svn_wc__db_wq_add(db, adm_abspath, work_item, scratch_pool));
-  }
-#endif
-
   /* ### this picks up file and symlink  */
   if (kind != svn_wc__db_kind_dir)
     {
@@ -858,12 +834,6 @@ svn_wc_delete4(svn_wc_context_t *wc_ctx,
       SVN_ERR(svn_wc__db_temp_op_delete(wc_ctx->db, local_abspath, pool));
       if (keep_local)
         SVN_ERR(svn_wc__db_temp_set_keep_local(db, local_abspath, TRUE, pool));
-      SVN_ERR(svn_wc__wq_add_delete(wc_ctx->db, parent_abspath, local_abspath,
-                                    kind, was_add, was_copied, was_replace,
-                                    pool));
-
-      SVN_ERR(svn_wc__wq_run(db, parent_abspath, cancel_func, cancel_baton,
-                             pool));
     }
 
   /* Report the deletion to the caller. */
@@ -1198,30 +1168,6 @@ svn_wc_add4(svn_wc_context_t *wc_ctx,
     }
 #endif
 
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-  /* ### this is totally bogus. we clear these cuz turds might have been
-     ### left around. Thankfully, this will gone soon... */
-  if (!is_wc_root && (node_exists || is_replace))
-    SVN_ERR(svn_wc__props_delete(db, local_abspath, svn_wc__props_working,
-                                 scratch_pool));
-#endif
-
-#if SVN_WC__VERSION < SVN_WC__PROPS_IN_DB
-    if (is_replace)
-      {
-        /* We don't want the old base text (if any) and base props to be
-           mistakenly used as the bases for the new, replacement object.
-           So, move them out of the way. */
-
-        /* ### TODO: In an ideal world, this whole function would be loggy.
-           ### Thankfully this code will be gone soon. */
-        SVN_ERR(svn_wc__wq_prepare_revert_files(db, local_abspath,
-                                                scratch_pool));
-        SVN_ERR(svn_wc__wq_run(db, local_abspath,
-                               cancel_func, cancel_baton, scratch_pool));
-      }
-#endif
-
   if (kind == svn_node_file)
     {
       if (!copyfrom_url)
@@ -2016,14 +1962,6 @@ svn_wc__internal_remove_from_revision_co
       else
         SVN_ERR(err);
 
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-      /* Remove prop/NAME, prop-base/NAME.svn-base. */
-      SVN_ERR(svn_wc__props_delete(db, local_abspath, svn_wc__props_working,
-                                   scratch_pool));
-      SVN_ERR(svn_wc__props_delete(db, local_abspath, svn_wc__props_base,
-                                   scratch_pool));
-#endif
-
       /* Remove NAME from PATH's entries file: */
       SVN_ERR(svn_wc__db_temp_op_remove_entry(db, local_abspath,
                                               scratch_pool));

Modified: subversion/trunk/subversion/libsvn_wc/copy.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/copy.c?rev=979350&r1=979349&r2=979350&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/copy.c (original)
+++ subversion/trunk/subversion/libsvn_wc/copy.c Mon Jul 26 16:37:37 2010
@@ -144,29 +144,6 @@ copy_versioned_file(svn_wc__db_t *db,
                                          dst_abspath,
                                          scratch_pool, scratch_pool));
 
-  
-  /* This goes away when we stop using revert bases. */
-  {
-    svn_wc__db_status_t dst_status; 
-    svn_boolean_t will_replace;
-    svn_error_t *err;
-
-    err = svn_wc__db_read_info(&dst_status,
-                               NULL, NULL, NULL, NULL, NULL, NULL, NULL,
-                               NULL, NULL, NULL, NULL, NULL, NULL, NULL,
-                               NULL, NULL, NULL, NULL, NULL, NULL, NULL,
-                               NULL, NULL,
-                               db, dst_abspath,
-                               scratch_pool, scratch_pool);
-    if (err && err->apr_err != SVN_ERR_WC_PATH_NOT_FOUND)
-      return svn_error_return(err);
-    will_replace = (!err && dst_status == svn_wc__db_status_deleted);
-    svn_error_clear(err);
-    if (will_replace)
-      SVN_ERR(svn_wc__wq_prepare_revert_files(db, dst_abspath,
-                                              scratch_pool));
-  }
-
   /* This goes away when we centralise, but until then we might need
      to do a cross-db pristine copy. */
   if (strcmp(svn_dirent_dirname(src_abspath, scratch_pool),
@@ -215,43 +192,6 @@ copy_versioned_file(svn_wc__db_t *db,
         }
     }
 
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-  /* This goes away when we move to in-db-props. */
-  {
-    apr_hash_t *src_props;
-
-    SVN_ERR(svn_wc__get_pristine_props(&src_props, db, src_abspath,
-                                       scratch_pool, scratch_pool));
-    if (src_props && apr_hash_count(src_props))
-      {
-        svn_skel_t *work_item;
-        const char *props_abspath;
-
-        SVN_ERR(svn_wc__prop_path(&props_abspath, dst_abspath, 
-                                  svn_wc__db_kind_file, svn_wc__props_base,
-                                  scratch_pool));
-        SVN_ERR(svn_wc__wq_build_write_old_props(&work_item, props_abspath,
-                                                 src_props, scratch_pool));
-        work_items = svn_wc__wq_merge(work_items, work_item, scratch_pool);
-      }
-
-    SVN_ERR(svn_wc__get_actual_props(&src_props, db, src_abspath,
-                                     scratch_pool, scratch_pool));
-    if (src_props && apr_hash_count(src_props))
-      {
-        svn_skel_t *work_item;
-        const char *props_abspath;
-
-        SVN_ERR(svn_wc__prop_path(&props_abspath, dst_abspath, 
-                                  svn_wc__db_kind_file, svn_wc__props_working,
-                                  scratch_pool));
-        SVN_ERR(svn_wc__wq_build_write_old_props(&work_item, props_abspath,
-                                                 src_props, scratch_pool));
-        work_items = svn_wc__wq_merge(work_items, work_item, scratch_pool);
-      }
-  }
-#endif
-
   SVN_ERR(copy_to_tmpdir(&tmp_dst_abspath, &kind, src_abspath, tmpdir_abspath,
                          TRUE, /* recursive */
                          cancel_func, cancel_baton, scratch_pool));
@@ -423,43 +363,6 @@ copy_versioned_dir(svn_wc__db_t *db,
 #endif
     }
 
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-  /* This goes away when we move to in-db-props. */
-  {
-    apr_hash_t *src_props;
-
-    SVN_ERR(svn_wc__get_pristine_props(&src_props, db, src_abspath,
-                                       scratch_pool, scratch_pool));
-    if (src_props && apr_hash_count(src_props))
-      {
-        svn_skel_t *work_item;
-        const char *props_abspath;
-
-        SVN_ERR(svn_wc__prop_path(&props_abspath, dst_abspath, 
-                                  svn_wc__db_kind_dir, svn_wc__props_base,
-                                  scratch_pool));
-        SVN_ERR(svn_wc__wq_build_write_old_props(&work_item, props_abspath,
-                                                 src_props, scratch_pool));
-        work_items = svn_wc__wq_merge(work_items, work_item, scratch_pool);
-      }
-
-    SVN_ERR(svn_wc__get_actual_props(&src_props, db, src_abspath,
-                                     scratch_pool, scratch_pool));
-    if (src_props && apr_hash_count(src_props))
-      {
-        svn_skel_t *work_item;
-        const char *props_abspath;
-
-        SVN_ERR(svn_wc__prop_path(&props_abspath, dst_abspath, 
-                                  svn_wc__db_kind_dir, svn_wc__props_working,
-                                  scratch_pool));
-        SVN_ERR(svn_wc__wq_build_write_old_props(&work_item, props_abspath,
-                                                 src_props, scratch_pool));
-        work_items = svn_wc__wq_merge(work_items, work_item, scratch_pool);
-      }
-  }
-#endif
-
   SVN_ERR(svn_wc__db_op_copy(db, src_abspath, dst_abspath,
                              work_items, scratch_pool));
   SVN_ERR(svn_wc__wq_run(db, dir_abspath,

Modified: subversion/trunk/subversion/libsvn_wc/status.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/status.c?rev=979350&r1=979349&r2=979350&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/status.c (original)
+++ subversion/trunk/subversion/libsvn_wc/status.c Mon Jul 26 16:37:37 2010
@@ -461,20 +461,10 @@ assemble_status(svn_wc_status3_t **statu
       if (has_props)
         prop_status = svn_wc_status_normal;
 
-      /* If the entry has a property file, see if it has local changes. */
-      /* ### we could compute this ourself, based on the prop hashes
-         ### fetched above. but for now, there is some trickery we may
-         ### need to rely upon in ths function. keep it for now.  */
-      /* ### see r944980 as an example of the brittleness of this stuff.  */
+      /* If the entry has a properties, see if it has local changes. */
       if (has_props)
-        {
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-          SVN_ERR(svn_wc__props_modified(&prop_modified_p, db, local_abspath,
-                                         scratch_pool));
-#endif
-          prop_status = prop_modified_p ? svn_wc_status_modified
-                                        : svn_wc_status_normal;
-        }
+        prop_status = prop_modified_p ? svn_wc_status_modified
+                                      : svn_wc_status_normal;
 
 #ifdef HAVE_SYMLINK
       if (has_props)

Modified: subversion/trunk/subversion/libsvn_wc/update_editor.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/update_editor.c?rev=979350&r1=979349&r2=979350&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/update_editor.c (original)
+++ subversion/trunk/subversion/libsvn_wc/update_editor.c Mon Jul 26 16:37:37 2010
@@ -6590,33 +6590,6 @@ svn_wc_add_repos_file4(svn_wc_context_t 
       }
     else if (err)
       return svn_error_return(err);
-    else if (status == svn_wc__db_status_normal ||
-             status == svn_wc__db_status_incomplete)
-      {
-        svn_boolean_t have_work;
-
-        SVN_ERR(svn_wc__db_read_info(
-                  &status, NULL, NULL,
-                  NULL, NULL, NULL, NULL, NULL, NULL,
-                  NULL, NULL, NULL, NULL, NULL, NULL,
-                  NULL, NULL, NULL, NULL,
-                  NULL, NULL, &have_work,
-                  NULL, NULL,
-                  db, local_abspath,
-                  pool, pool));
-
-        /* If there is a WORKING node present AND it is not an "add",
-           then we need to move the base/props. If an add is present,
-           that would imply we've done this move before.  */
-        if (have_work
-            && status != svn_wc__db_status_added
-            && status != svn_wc__db_status_obstructed_add)
-          {
-            /* Move around some files to keep them safe for a possible
-               future revert operation.  */
-            SVN_ERR(svn_wc__wq_prepare_revert_files(db, local_abspath, pool));
-          }
-      }
   }
 
   /* Set CHANGED_* to reflect the entry props in NEW_BASE_PROPS, and

Modified: subversion/trunk/subversion/libsvn_wc/workqueue.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/workqueue.c?rev=979350&r1=979349&r2=979350&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/workqueue.c (original)
+++ subversion/trunk/subversion/libsvn_wc/workqueue.c Mon Jul 26 16:37:37 2010
@@ -43,7 +43,6 @@
 
 /* Workqueue operation names.  */
 #define OP_REVERT "revert"
-#define OP_PREPARE_REVERT_FILES "prep-rev-files"
 #define OP_KILLME "killme"
 #define OP_LOGGY "loggy"
 #define OP_DELETION_POSTCOMMIT "deletion-postcommit"
@@ -52,14 +51,12 @@
  *    [dav_cache/wc_props], keep_changelist, [tmp_text_base_abspath]). */
 #define OP_POSTCOMMIT "postcommit"
 #define OP_INSTALL_PROPERTIES "install-properties-2"
-#define OP_DELETE "delete"
 #define OP_FILE_INSTALL "file-install"
 #define OP_FILE_REMOVE "file-remove"
 #define OP_FILE_MOVE "file-move"
 #define OP_FILE_COPY_TRANSLATED "file-translate"
 #define OP_SYNC_FILE_FLAGS "sync-file-flags"
 #define OP_PREJ_INSTALL "prej-install"
-#define OP_WRITE_OLD_PROPS "write-old-props"
 #define OP_RECORD_FILEINFO "record-fileinfo"
 #define OP_TMP_SET_TEXT_CONFLICT_MARKERS "tmp-set-text-conflict-markers"
 #define OP_TMP_SET_PROPERTY_CONFLICT_MARKER "tmp-set-property-conflict-marker"
@@ -212,7 +209,6 @@ run_revert(svn_wc__db_t *db,
   const char *local_abspath;
   svn_boolean_t replaced;
   svn_wc__db_kind_t kind;
-  const char *working_props_path;
   const char *parent_abspath;
   svn_boolean_t conflicted;
 
@@ -233,39 +229,6 @@ run_revert(svn_wc__db_t *db,
             db, local_abspath,
             scratch_pool, scratch_pool));
 
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-  /* Move the "revert" props over/on the "base" props.  */
-  if (replaced)
-    {
-      const char *revert_props_path;
-      const char *base_props_path;
-
-      SVN_ERR(svn_wc__prop_path(&revert_props_path, local_abspath,
-                                kind, svn_wc__props_revert, scratch_pool));
-      SVN_ERR(svn_wc__prop_path(&base_props_path, local_abspath,
-                                kind, svn_wc__props_base, scratch_pool));
-
-      SVN_ERR(move_if_present(revert_props_path, base_props_path,
-                              scratch_pool));
-
-      /* ### we should also be setting BASE props. and really... we shouldn't
-         ### even bother zero-ing out these props. the WORKING node should
-         ### be disappearing after a revert.  */
-#if 0
-      SVN_ERR(svn_wc__db_temp_working_set_props(db, local_abspath,
-                                                apr_hash_make(scratch_pool),
-                                                scratch_pool));
-#endif
-    }
-#endif
-
-  /* The "working" props contain changes. Nuke 'em from orbit.  */
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-  SVN_ERR(svn_wc__prop_path(&working_props_path, local_abspath,
-                            kind, svn_wc__props_working, scratch_pool));
-  SVN_ERR(svn_io_remove_file2(working_props_path, TRUE, scratch_pool));
-#endif
-
   SVN_ERR(svn_wc__db_op_set_props(db, local_abspath, NULL, NULL, NULL,
                                   scratch_pool));
 
@@ -564,97 +527,6 @@ svn_wc__wq_add_revert(svn_boolean_t *wil
   return SVN_NO_ERROR;
 }
 
-
-/* ------------------------------------------------------------------------ */
-
-/* OP_PREPARE_REVERT_FILES  */
-
-
-/* Process the OP_PREPARE_REVERT_FILES work item WORK_ITEM.
- * See svn_wc__wq_prepare_revert_files() which generates this work item.
- * Implements (struct work_item_dispatch).func.
- * With the Pristine Store, the "revert-base" concept no longer applies
- * to texts, so this only deals with properties. */
-static svn_error_t *
-run_prepare_revert_files(svn_wc__db_t *db,
-                         const svn_skel_t *work_item,
-                         const char *wri_abspath,
-                         svn_cancel_func_t cancel_func,
-                         void *cancel_baton,
-                         apr_pool_t *scratch_pool)
-{
-  const svn_skel_t *arg1 = work_item->children->next;
-  const char *local_abspath;
-  svn_wc__db_kind_t kind;
-  const char *revert_prop_abspath;
-  const char *base_prop_abspath;
-  svn_node_kind_t on_disk;
-
-  /* We need a NUL-terminated path, so copy it out of the skel.  */
-  local_abspath = apr_pstrmemdup(scratch_pool, arg1->data, arg1->len);
-
-  /* Rename the original text base over to the revert text base.  */
-  SVN_ERR(svn_wc__db_read_kind(&kind, db, local_abspath, FALSE, scratch_pool));
-
-  /* Set up the revert props.  */
-
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-  SVN_ERR(svn_wc__prop_path(&revert_prop_abspath, local_abspath, kind,
-                            svn_wc__props_revert, scratch_pool));
-  SVN_ERR(svn_wc__prop_path(&base_prop_abspath, local_abspath, kind,
-                            svn_wc__props_base, scratch_pool));
-
-  /* First: try to move any base properties to the revert location.  */
-  SVN_ERR(move_if_present(base_prop_abspath, revert_prop_abspath,
-                          scratch_pool));
-
-  /* If no props exist at the revert location, then drop a set of empty
-     props there. They are expected to be present.  */
-  SVN_ERR(svn_io_check_path(revert_prop_abspath, &on_disk, scratch_pool));
-  if (on_disk == svn_node_none)
-    {
-      svn_stream_t *stream;
-
-      /* A set of empty props is just an empty file. */
-      SVN_ERR(svn_stream_open_writable(&stream, revert_prop_abspath,
-                                       scratch_pool, scratch_pool));
-      SVN_ERR(svn_stream_close(stream));
-      SVN_ERR(svn_io_set_file_read_only(revert_prop_abspath, FALSE,
-                                        scratch_pool));
-    }
-#endif
-
-  /* Put some blank properties into the WORKING node.  */
-  /* ### this seems bogus. something else should come along and put the
-     ### correct values in here. we shouldn't put empty values in.  */
-#if 0
-  SVN_ERR(svn_wc__db_temp_working_set_props(db, local_abspath,
-                                            apr_hash_make(scratch_pool),
-                                            scratch_pool));
-#endif
-
-  return SVN_NO_ERROR;
-}
-
-
-svn_error_t *
-svn_wc__wq_prepare_revert_files(svn_wc__db_t *db,
-                                const char *local_abspath,
-                                apr_pool_t *scratch_pool)
-{
-  svn_skel_t *work_item = svn_skel__make_empty_list(scratch_pool);
-
-  /* These skel atoms hold references to very transitory state, but
-     we only need the work_item to survive for the duration of wq_add.  */
-  svn_skel__prepend_str(local_abspath, work_item, scratch_pool);
-  svn_skel__prepend_str(OP_PREPARE_REVERT_FILES, work_item, scratch_pool);
-
-  SVN_ERR(svn_wc__db_wq_add(db, local_abspath, work_item, scratch_pool));
-
-  return SVN_NO_ERROR;
-}
-
-
 /* ------------------------------------------------------------------------ */
 
 /* OP_KILLME  */
@@ -1672,91 +1544,6 @@ svn_wc__wq_add_install_properties(svn_wc
 
 /* ------------------------------------------------------------------------ */
 
-/* OP_DELETE */
-
-/* Process the OP_DELETE work item WORK_ITEM.
- * See svn_wc__wq_add_delete() which generates this work item.
- * Implements (struct work_item_dispatch).func. */
-static svn_error_t *
-run_delete(svn_wc__db_t *db,
-           const svn_skel_t *work_item,
-           const char *wri_abspath,
-           svn_cancel_func_t cancel_func,
-           void *cancel_baton,
-           apr_pool_t *scratch_pool)
-{
-  const svn_skel_t *arg = work_item->children->next;
-  const char *local_abspath;
-  svn_wc__db_kind_t kind;
-  svn_boolean_t was_added, was_copied, was_replaced;
-
-  local_abspath = apr_pstrmemdup(scratch_pool, arg->data, arg->len);
-  arg = arg->next;
-  kind = (int) svn_skel__parse_int(arg, scratch_pool);
-  arg = arg->next;
-  was_added = svn_skel__parse_int(arg, scratch_pool) != 0;
-  arg = arg->next;
-  was_copied = svn_skel__parse_int(arg, scratch_pool) != 0;
-  arg = arg->next;
-  was_replaced = svn_skel__parse_int(arg, scratch_pool) != 0;
-
-  if (was_replaced && was_copied)
-    {
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-      const char *props_base, *props_revert;
-
-      SVN_ERR(svn_wc__prop_path(&props_base, local_abspath, kind,
-                                svn_wc__props_base, scratch_pool));
-      SVN_ERR(svn_wc__prop_path(&props_revert, local_abspath, kind,
-                                svn_wc__props_revert, scratch_pool));
-      SVN_ERR(move_if_present(props_revert, props_base, scratch_pool));
-#endif
-    }
-#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
-  if (was_added)
-    {
-      const char *props_base, *props_working;
-
-      SVN_ERR(svn_wc__prop_path(&props_base, local_abspath, kind,
-                                svn_wc__props_base, scratch_pool));
-      SVN_ERR(svn_wc__prop_path(&props_working, local_abspath, kind,
-                                svn_wc__props_working, scratch_pool));
-
-      SVN_ERR(svn_io_remove_file2(props_base, TRUE, scratch_pool));
-      SVN_ERR(svn_io_remove_file2(props_working, TRUE, scratch_pool));
-    }
-#endif
-
-  return SVN_NO_ERROR;
-}
-
-svn_error_t *
-svn_wc__wq_add_delete(svn_wc__db_t *db,
-                      const char *parent_abspath,
-                      const char *local_abspath,
-                      svn_wc__db_kind_t kind,
-                      svn_boolean_t was_added,
-                      svn_boolean_t was_copied,
-                      svn_boolean_t was_replaced,
-                      apr_pool_t *scratch_pool)
-{
-  svn_skel_t *work_item = svn_skel__make_empty_list(scratch_pool);
-
-  svn_skel__prepend_int(was_replaced, work_item, scratch_pool);
-  svn_skel__prepend_int(was_copied, work_item, scratch_pool);
-  svn_skel__prepend_int(was_added, work_item, scratch_pool);
-  svn_skel__prepend_int(kind, work_item, scratch_pool);
-  svn_skel__prepend_str(local_abspath, work_item, scratch_pool);
-  svn_skel__prepend_str(OP_DELETE, work_item, scratch_pool);
-
-  SVN_ERR(svn_wc__db_wq_add(db, parent_abspath, work_item, scratch_pool));
-
-  return SVN_NO_ERROR;
-}
-
-
-/* ------------------------------------------------------------------------ */
-
 /* OP_FILE_INSTALL */
 
 /* Process the OP_FILE_INSTALL work item WORK_ITEM.
@@ -2245,85 +2032,6 @@ svn_wc__wq_build_prej_install(svn_skel_t
 
 /* ------------------------------------------------------------------------ */
 
-/* OP_WRITE_OLD_PROPS  */
-
-
-static svn_error_t *
-run_write_old_props(svn_wc__db_t *db,
-                    const svn_skel_t *work_item,
-                    const char *wri_abspath,
-                    svn_cancel_func_t cancel_func,
-                    void *cancel_baton,
-                    apr_pool_t *scratch_pool)
-{
-  const svn_skel_t *arg1 = work_item->children->next;
-  const char *props_abspath;
-  svn_stream_t *stream;
-  apr_hash_t *props;
-
-  props_abspath = apr_pstrmemdup(scratch_pool, arg1->data, arg1->len);
-
-  /* Torch whatever may be there.  */
-  SVN_ERR(svn_io_remove_file2(props_abspath, TRUE, scratch_pool));
-
-  if (arg1->next == NULL)
-    {
-      /* PROPS == NULL means the file should be removed. Note that an
-         empty set of properties has an entirely different meaning.
-
-         The file has already been removed. Simply exit.  */
-      return SVN_NO_ERROR;
-    }
-  SVN_ERR(svn_skel__parse_proplist(&props, arg1->next, scratch_pool));
-
-  SVN_ERR(svn_stream_open_writable(&stream, props_abspath,
-                                   scratch_pool, scratch_pool));
-
-  /* An empty file is shorthand for an empty set of properties.  */
-  if (apr_hash_count(props) != 0)
-    SVN_ERR(svn_hash_write2(props, stream, SVN_HASH_TERMINATOR, scratch_pool));
-
-  SVN_ERR(svn_stream_close(stream));
-
-  SVN_ERR(svn_io_set_file_read_only(props_abspath,
-                                    FALSE /* ignore_enoent */,
-                                    scratch_pool));
-
-  return SVN_NO_ERROR;
-}
-
-
-svn_error_t *
-svn_wc__wq_build_write_old_props(svn_skel_t **work_item,
-                                 const char *props_abspath,
-                                 apr_hash_t *props,
-                                 apr_pool_t *result_pool)
-{
-#if (SVN_WC__VERSION >= SVN_WC__PROPS_IN_DB)
-  *work_item = NULL;
-#else
-  *work_item = svn_skel__make_empty_list(result_pool);
-
-  SVN_ERR_ASSERT(svn_dirent_is_absolute(props_abspath));
-
-  if (props != NULL)
-    {
-      svn_skel_t *props_skel;
-
-      SVN_ERR(svn_skel__unparse_proplist(&props_skel, props, result_pool));
-      svn_skel__prepend(props_skel, *work_item);
-    }
-  svn_skel__prepend_str(apr_pstrdup(result_pool, props_abspath),
-                        *work_item, result_pool);
-  svn_skel__prepend_str(OP_WRITE_OLD_PROPS, *work_item, result_pool);
-#endif
-
-  return SVN_NO_ERROR;
-}
-
-
-/* ------------------------------------------------------------------------ */
-
 /* OP_RECORD_FILEINFO  */
 
 
@@ -2606,19 +2314,16 @@ svn_wc__wq_build_pristine_get_translated
 
 static const struct work_item_dispatch dispatch_table[] = {
   { OP_REVERT, run_revert },
-  { OP_PREPARE_REVERT_FILES, run_prepare_revert_files },
   { OP_KILLME, run_killme },
   { OP_LOGGY, run_loggy },
   { OP_DELETION_POSTCOMMIT, run_deletion_postcommit },
   { OP_POSTCOMMIT, run_postcommit },
-  { OP_DELETE, run_delete },
   { OP_FILE_INSTALL, run_file_install },
   { OP_FILE_REMOVE, run_file_remove },
   { OP_FILE_MOVE, run_file_move },
   { OP_FILE_COPY_TRANSLATED, run_file_copy_translated },
   { OP_SYNC_FILE_FLAGS, run_sync_file_flags },
   { OP_PREJ_INSTALL, run_prej_install },
-  { OP_WRITE_OLD_PROPS, run_write_old_props },
   { OP_RECORD_FILEINFO, run_record_fileinfo },
   { OP_TMP_SET_TEXT_CONFLICT_MARKERS, run_set_text_conflict_markers },
   { OP_TMP_SET_PROPERTY_CONFLICT_MARKER, run_set_property_conflict_marker },

Modified: subversion/trunk/subversion/libsvn_wc/workqueue.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/workqueue.h?rev=979350&r1=979349&r2=979350&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/workqueue.h (original)
+++ subversion/trunk/subversion/libsvn_wc/workqueue.h Mon Jul 26 16:37:37 2010
@@ -173,18 +173,6 @@ svn_wc__wq_build_prej_install(svn_skel_t
                               apr_pool_t *result_pool,
                               apr_pool_t *scratch_pool);
 
-
-/* Set *WORK_ITEM to a new work item that will install PROPS at PROPS_ABSPATH.
-   If PROPS is NULL, then the target props file will will be removed.
-
-   ### this will go away when we fully move to in-db properties.  */
-svn_error_t *
-svn_wc__wq_build_write_old_props(svn_skel_t **work_item,
-                                 const char *props_abspath,
-                                 apr_hash_t *props,
-                                 apr_pool_t *result_pool);
-
-
 /* Set *WORK_ITEM to a new work item that will record file information of
    LOCAL_ABSPATH into the TRANSLATED_SIZE and LAST_MOD_TIME of the node via
    the svn_wc__db_global_record_fileinfo() function.
@@ -208,15 +196,6 @@ svn_wc__wq_add_revert(svn_boolean_t *wil
                       svn_boolean_t use_commit_times,
                       apr_pool_t *scratch_pool);
 
-
-/* Record a work item to prepare the "revert props" and "revert text base"
-   for LOCAL_ABSPATH.  */
-svn_error_t *
-svn_wc__wq_prepare_revert_files(svn_wc__db_t *db,
-                                const char *local_abspath,
-                                apr_pool_t *scratch_pool);
-
-
 /* Handle the old "KILLME" concept -- perform the actual deletion of a
    subdir (or just its admin area) during post-commit processing of a
    deleted subdir.  */
@@ -332,23 +311,6 @@ svn_wc__wq_add_install_properties(svn_wc
                                   apr_pool_t *scratch_pool);
 #endif
 
-/* Add a work item to delete a node.
-
-   ### LOCAL_ABSPATH is the node to be deleted and the queue exists in
-   PARENT_ABSPATH (because when LOCAL_ABSPATH is a directory it might
-   not exist on disk).  This use of PARENT_ABSPATH is inherited from
-   the log file conversion but perhaps we don't need to use a work
-   queue when deleting a directory that does not exist on disk.
- */
-svn_error_t *
-svn_wc__wq_add_delete(svn_wc__db_t *db,
-                      const char *parent_abspath,
-                      const char *local_abspath,
-                      svn_wc__db_kind_t kind,
-                      svn_boolean_t was_added,
-                      svn_boolean_t was_copied,
-                      svn_boolean_t was_replaced,
-                      apr_pool_t *scratch_pool);
 
 #ifdef __cplusplus
 }