[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] UI improvement for svnadmin verify

From: Eric Gillespie <epg_at_google.com>
Date: Fri, 22 Feb 2008 15:57:56 -0800

Karl Fogel <kfogel_at_red-bean.com> writes:

> I think the way to do this is to pass a new boolean 'verify' argument
> to get_dump_editor(), which in turn is responsible for setting the
> boolean in the baton. (I.e., the baton should always remain 'void *'
> to the outside caller.)

Er, yeah, that's the way the rest of it works; moving too quickly
and not paying enough attention. Thanks.

Index: subversion/libsvn_repos/dump.c
===================================================================
--- subversion/libsvn_repos/dump.c (revision 29557)
+++ subversion/libsvn_repos/dump.c (working copy)
@@ -185,6 +185,9 @@
   /* True if dumped nodes should output deltas instead of full text. */
   svn_boolean_t use_deltas;
 
+ /* True if this "dump" is in fact a verify. */
+ svn_boolean_t verify;
+
   /* The first revision dumped in this dumpstream. */
   svn_revnum_t oldest_dumped_rev;
 
@@ -410,7 +413,7 @@
         }
       else
         {
- if (cmp_rev < eb->oldest_dumped_rev)
+ if (!eb->verify && cmp_rev < eb->oldest_dumped_rev)
             SVN_ERR(svn_stream_printf
                     (eb->feedback_stream, pool,
                      _("WARNING: Referencing data in revision %ld,"
@@ -810,6 +813,7 @@
                 svn_stream_t *feedback_stream,
                 svn_revnum_t oldest_dumped_rev,
                 svn_boolean_t use_deltas,
+ svn_boolean_t verify,
                 apr_pool_t *pool)
 {
   /* Allocate an edit baton to be stored in every directory baton.
@@ -827,6 +831,7 @@
   SVN_ERR(svn_fs_revision_root(&(eb->fs_root), fs, to_rev, pool));
   eb->current_rev = to_rev;
   eb->use_deltas = use_deltas;
+ eb->verify = verify;
 
   /* Set up the editor. */
   dump_editor->open_root = open_root;
@@ -1031,7 +1036,7 @@
       use_deltas_for_rev = use_deltas && (incremental || i != start_rev);
       SVN_ERR(get_dump_editor(&dump_editor, &dump_edit_baton, fs, to_rev,
                               "/", stream, feedback_stream, start_rev,
- use_deltas_for_rev, subpool));
+ use_deltas_for_rev, FALSE, subpool));
 
       /* Drive the editor in one way or another. */
       SVN_ERR(svn_fs_revision_root(&to_root, fs, to_rev, subpool));
@@ -1204,7 +1209,9 @@
       SVN_ERR(get_dump_editor((const svn_delta_editor_t **)&dump_editor,
                               &dump_edit_baton, fs, rev, "",
                               svn_stream_empty(pool), feedback_stream,
- start_rev, FALSE, iterpool));
+ start_rev,
+ FALSE, TRUE, /* use_deltas, verify */
+ iterpool));
       dump_editor->close_directory = verify_close_directory;
       SVN_ERR(svn_delta_get_cancellation_editor(cancel_func, cancel_baton,
                                                 dump_editor, dump_edit_baton,

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-02-23 00:58:08 CET

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.