You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by da...@apache.org on 2010/09/21 01:25:35 UTC

svn commit: r999158 - in /subversion/trunk/subversion: include/svn_error_codes.h include/svn_fs.h libsvn_fs_base/revs-txns.c libsvn_fs_fs/fs_fs.c tests/libsvn_fs/fs-test.c

Author: danielsh
Date: Mon Sep 20 23:25:35 2010
New Revision: 999158

URL: http://svn.apache.org/viewvc?rev=999158&view=rev
Log:
Rename an error code.

Suggested by: rhuijben
              blair

* subversion/include/svn_error_codes.h
  (SVN_ERR_BAD_OLD_VALUE): Remove.
  (SVN_ERR_FS_PROP_BASEVALUE_MISMATCH): New.

* subversion/tests/libsvn_fs/fs-test.c,
  subversion/libsvn_fs_base/revs-txns.c,
  subversion/include/svn_fs.h,
  subversion/libsvn_fs_fs/fs_fs.c:
    Track rename.

Modified:
    subversion/trunk/subversion/include/svn_error_codes.h
    subversion/trunk/subversion/include/svn_fs.h
    subversion/trunk/subversion/libsvn_fs_base/revs-txns.c
    subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c
    subversion/trunk/subversion/tests/libsvn_fs/fs-test.c

Modified: subversion/trunk/subversion/include/svn_error_codes.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/include/svn_error_codes.h?rev=999158&r1=999157&r2=999158&view=diff
==============================================================================
--- subversion/trunk/subversion/include/svn_error_codes.h (original)
+++ subversion/trunk/subversion/include/svn_error_codes.h Mon Sep 20 23:25:35 2010
@@ -219,11 +219,6 @@ SVN_ERROR_START
              SVN_ERR_BAD_CATEGORY_START + 13,
              "Unknown string value of token")
 
-  /** @since New in 1.7. */
-  SVN_ERRDEF(SVN_ERR_BAD_OLD_VALUE,
-             SVN_ERR_BAD_CATEGORY_START + 14,
-             "Old value doesn't match repository")
-
   /* xml errors */
 
   SVN_ERRDEF(SVN_ERR_XML_ATTRIB_NOT_FOUND,
@@ -743,6 +738,12 @@ SVN_ERROR_START
              SVN_ERR_FS_CATEGORY_START + 48,
              "Filesystem has no such checksum-representation index record")
 
+  /** @since New in 1.7. */
+  SVN_ERRDEF(SVN_ERR_FS_PROP_BASEVALUE_MISMATCH,
+             SVN_ERR_FS_CATEGORY_START + 49,
+             "Property value in filesystem differs from the provided "
+             "base value")
+
   /* repos errors */
 
   SVN_ERRDEF(SVN_ERR_REPOS_LOCKED,

Modified: subversion/trunk/subversion/include/svn_fs.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/include/svn_fs.h?rev=999158&r1=999157&r2=999158&view=diff
==============================================================================
--- subversion/trunk/subversion/include/svn_fs.h (original)
+++ subversion/trunk/subversion/include/svn_fs.h Mon Sep 20 23:25:35 2010
@@ -1896,8 +1896,8 @@ svn_fs_revision_proplist(apr_hash_t **ta
  * - @a name is the name of the property to change.
  * - if @a old_value_p is not @c NULL, then @a *old_value_p is the expected old
  *   value of the property, and changing the value will fail with error
- *   #SVN_ERR_BAD_OLD_VALUE if the present value of the property is not @a
- *   *old_value_p.  (This is an atomic test-and-set).
+ *   #SVN_ERR_FS_PROP_BASEVALUE_MISMATCH if the present value of the property
+ *   is not @a *old_value_p.  (This is an atomic test-and-set).
  * - @a value is the new value of the property, or zero if the property should
  *   be removed altogether.
  *

Modified: subversion/trunk/subversion/libsvn_fs_base/revs-txns.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_base/revs-txns.c?rev=999158&r1=999157&r2=999158&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_fs_base/revs-txns.c (original)
+++ subversion/trunk/subversion/libsvn_fs_base/revs-txns.c Mon Sep 20 23:25:35 2010
@@ -270,7 +270,7 @@ svn_fs_base__set_rev_prop(svn_fs_t *fs,
               && !svn_string_compare(wanted_value, present_value)))
         {
           /* What we expected isn't what we found. */
-          return svn_error_createf(SVN_ERR_BAD_OLD_VALUE, NULL,
+          return svn_error_createf(SVN_ERR_FS_PROP_BASEVALUE_MISMATCH, NULL,
                                    _("revprop '%s' has unexpected value in "
                                      "filesystem"),
                                    name);

Modified: subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c?rev=999158&r1=999157&r2=999158&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c (original)
+++ subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c Mon Sep 20 23:25:35 2010
@@ -7312,7 +7312,7 @@ change_rev_prop_body(void *baton, apr_po
               && !svn_string_compare(wanted_value, present_value)))
         {
           /* What we expected isn't what we found. */
-          return svn_error_createf(SVN_ERR_BAD_OLD_VALUE, NULL,
+          return svn_error_createf(SVN_ERR_FS_PROP_BASEVALUE_MISMATCH, NULL,
                                    _("revprop '%s' has unexpected value in "
                                      "filesystem"),
                                    cb->name);

Modified: subversion/trunk/subversion/tests/libsvn_fs/fs-test.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/libsvn_fs/fs-test.c?rev=999158&r1=999157&r2=999158&view=diff
==============================================================================
--- subversion/trunk/subversion/tests/libsvn_fs/fs-test.c (original)
+++ subversion/trunk/subversion/tests/libsvn_fs/fs-test.c Mon Sep 20 23:25:35 2010
@@ -586,12 +586,12 @@ list_directory(const svn_test_opts_t *op
 }
 
 
-/* If EXPR raises SVN_ERR_BAD_OLD_VALUE, continue; else, fail
+/* If EXPR raises SVN_ERR_FS_PROP_BASEVALUE_MISMATCH, continue; else, fail
  * the test. */
 #define FAILS_WITH_BOV(expr) \
   do { \
       svn_error_t *__err = (expr); \
-      if (!__err || __err->apr_err != SVN_ERR_BAD_OLD_VALUE) \
+      if (!__err || __err->apr_err != SVN_ERR_FS_PROP_BASEVALUE_MISMATCH) \
         return svn_error_create(SVN_ERR_TEST_FAILED, __err, \
                                 "svn_fs_change_rev_prop2() failed to " \
                                 "detect unexpected old value"); \