You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by ph...@apache.org on 2010/09/02 19:14:49 UTC

svn commit: r992024 - /subversion/trunk/subversion/libsvn_wc/upgrade.c

Author: philip
Date: Thu Sep  2 17:14:49 2010
New Revision: 992024

URL: http://svn.apache.org/viewvc?rev=992024&view=rev
Log:
Make upgrade a bit more user friendly.

* subversion/libsvn_wc/upgrade.c
  (upgrade_working_copy): Skip if this dir is later than 1.6.
  (svn_wc_upgrade): Include path in error message.

Modified:
    subversion/trunk/subversion/libsvn_wc/upgrade.c

Modified: subversion/trunk/subversion/libsvn_wc/upgrade.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/upgrade.c?rev=992024&r1=992023&r2=992024&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/upgrade.c (original)
+++ subversion/trunk/subversion/libsvn_wc/upgrade.c Thu Sep  2 17:14:49 2010
@@ -1504,9 +1504,14 @@ upgrade_working_copy(svn_wc__db_t *db,
                                      iterpool));
 
   if (old_format >= SVN_WC__WC_NG_VERSION)
-    return svn_error_create(
-      SVN_ERR_WC_INVALID_OP_ON_CWD, NULL,
-      _("Upgrade can only be used on the root of a pre-1.7 working copy."));
+    {
+      if (notify_func)
+        notify_func(notify_baton,
+                    svn_wc_create_notify(dir_abspath, svn_wc_notify_skip,
+                                         iterpool),
+                iterpool);
+      return SVN_NO_ERROR;
+    }
 
   /* At present upgrade_to_wcng removes the entries file so get the
      children before calling it. */
@@ -1602,9 +1607,10 @@ svn_wc_upgrade(svn_wc_context_t *wc_ctx,
                           scratch_pool, scratch_pool));
 
   if (!is_old_wcroot(local_abspath, scratch_pool))
-    return svn_error_create(
+    return svn_error_createf(
       SVN_ERR_WC_INVALID_OP_ON_CWD, NULL,
-      _("Upgrade can only be used on the root of a pre-1.7 working copy."));
+      _("Cannot upgrade '%s' as it is not a pre-1.7 working copy root"),
+      svn_dirent_local_style(local_abspath, scratch_pool));
 
   /* Upgrade this directory and/or its subdirectories.  */
   SVN_ERR(upgrade_working_copy(db, local_abspath,