Author: julianfoad
Date: Fri Jul 2 15:25:03 2010
New Revision: 960024
URL: http://svn.apache.org/viewvc?rev=960024&view=rev
Log:
Start stripping out code that is obsolete now that SVN_EXPERIMENTAL_PRISTINE
is defined.
* subversion/ibsvn_wc/adm_crawler.c,
subversion/libsvn_wc/diff.c,
subversion/libsvn_wc/copy.c
Remove SVN_EXPERIMENTAL_PRISTINE ifdefs and the pre-pristine-store code
chunks that were ifdef'd out.
Modified:
subversion/trunk/subversion/libsvn_wc/adm_crawler.c
subversion/trunk/subversion/libsvn_wc/copy.c
subversion/trunk/subversion/libsvn_wc/diff.c
Modified: subversion/trunk/subversion/libsvn_wc/adm_crawler.c
URL:
http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/adm_crawler.c?rev=960024&r1=960023&r2=960024&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/adm_crawler.c (original)
+++ subversion/trunk/subversion/libsvn_wc/adm_crawler.c Fri Jul 2 15:25:03 2010
@@ -1300,12 +1300,10 @@ svn_wc__internal_transmit_text_deltas(co
result_pool);
if (new_text_base_sha1_checksum)
{
-#ifdef SVN_EXPERIMENTAL_PRISTINE
SVN_ERR(svn_wc__db_pristine_install(db, new_pristine_tmp_abspath,
local_sha1_checksum,
local_md5_checksum,
scratch_pool));
-#endif
*new_text_base_sha1_checksum = svn_checksum_dup(local_sha1_checksum,
result_pool);
}
Modified: subversion/trunk/subversion/libsvn_wc/copy.c
URL:
http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/copy.c?rev=960024&r1=960023&r2=960024&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/copy.c (original)
+++ subversion/trunk/subversion/libsvn_wc/copy.c Fri Jul 2 15:25:03 2010
@@ -167,7 +167,6 @@ copy_versioned_file(svn_wc__db_t *db,
scratch_pool));
}
-#ifdef SVN_EXPERIMENTAL_PRISTINE
/* 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,48 +214,6 @@ copy_versioned_file(svn_wc__db_t *db,
scratch_pool));
}
}
-#else
- {
- /* This goes away when the pristine store is enabled, but until
- then we may need to copy the text-base. */
- svn_wc__db_status_t src_status;
-
- SVN_ERR(svn_wc__db_read_info(&src_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, src_abspath,
- scratch_pool, scratch_pool));
- if (src_status == svn_wc__db_status_absent
- || src_status == svn_wc__db_status_excluded
- || src_status == svn_wc__db_status_not_present)
- src_pristine = NULL;
- else
- SVN_ERR(svn_wc__get_pristine_contents(&src_pristine, db,
- src_abspath,
- scratch_pool, scratch_pool));
-
- if (src_pristine)
- {
- svn_skel_t *work_item;
- svn_stream_t *tmp_pristine;
- const char *tmp_pristine_abspath, *dst_pristine_abspath;
-
- SVN_ERR(svn_stream_open_unique(&tmp_pristine, &tmp_pristine_abspath,
- tmpdir_abspath, svn_io_file_del_none,
- scratch_pool, scratch_pool));
- SVN_ERR(svn_stream_copy3(src_pristine, tmp_pristine,
- cancel_func, cancel_baton, scratch_pool));
- SVN_ERR(svn_wc__text_base_path(&dst_pristine_abspath, db,
- dst_abspath, scratch_pool));
- SVN_ERR(svn_wc__loggy_move(&work_item, db, dir_abspath,
- tmp_pristine_abspath, dst_pristine_abspath,
- scratch_pool));
- work_items = svn_wc__wq_merge(work_items, work_item, scratch_pool);
- }
- }
-#endif
#if (SVN_WC__VERSION < SVN_WC__PROPS_IN_DB)
/* This goes away when we move to in-db-props. */
Modified: subversion/trunk/subversion/libsvn_wc/diff.c
URL:
http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/diff.c?rev=960024&r1=960023&r2=960024&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/diff.c (original)
+++ subversion/trunk/subversion/libsvn_wc/diff.c Fri Jul 2 15:25:03 2010
@@ -153,7 +153,6 @@ get_nearest_pristine_text_as_file(const
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
{
-#ifdef SVN_EXPERIMENTAL_PRISTINE
const svn_checksum_t *checksum;
SVN_ERR(svn_wc__db_read_info(NULL, NULL, NULL, NULL, NULL, NULL,
@@ -186,34 +185,6 @@ get_nearest_pristine_text_as_file(const
result_pool, scratch_pool));
return SVN_NO_ERROR;
}
-#else
- svn_error_t *err;
-
- err = svn_wc__text_base_path_to_read(result_abspath, db, local_abspath,
- result_pool, scratch_pool);
-
- if (err && err->apr_err == SVN_ERR_WC_PATH_UNEXPECTED_STATUS)
- svn_error_clear(err);
- else
- return svn_error_return(err);
-
- err = svn_wc__text_revert_path_to_read(result_abspath, db, local_abspath,
- result_pool);
-
- /* If there is no revert base to diff either, don't attempt to diff it.
- ### This is a band-aid.
- ### In WC-NG, files added within a copied subtree are marked "copied",
- ### which will cause the code below to end up calling
- ### eb->callbacks->file_changed() with a non-existent text-base.
- ### Not sure how to properly tell apart a file added within a copied
- ### subtree from a copied file. But eventually we'll have to get the
- ### base text from the pristine store anyway and use tempfiles (or
- ### streams, hopefully) for diffing, so this hack will just go away. */
- if (err && err->apr_err == SVN_ERR_WC_PATH_UNEXPECTED_STATUS)
- svn_error_clear(err);
- else
- return svn_error_return(err);
-#endif
*result_abspath = NULL;
return SVN_NO_ERROR;