Author: stefan2
Date: Tue Dec 3 17:20:28 2013
New Revision: 1547486
URL: http://svn.apache.org/r1547486
Log:
Fix 'svnadmin recover' regression crash with old repositories
(--compatible-version=1.3 / 1.2 / 1.1). Follow-up to r1532029.
* subversion/libsvn_fs_fs/recovery.c
(svn_fs_fs__find_max_ids): Call svn_fs_fs__open_pack_or_rev_file in order to
initialize REV_FILE before passing it as an argument to other functions
(namely, svn_fs_fs__item_offset).
Patch by: Evgeny Kotkov <evgeny.kotkov{_AT_}visualsvn.com>
Modified:
subversion/trunk/subversion/libsvn_fs_fs/recovery.c
Modified: subversion/trunk/subversion/libsvn_fs_fs/recovery.c
URL:
http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_fs/recovery.c?rev=1547486&r1=1547485&r2=1547486&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_fs_fs/recovery.c (original)
+++ subversion/trunk/subversion/libsvn_fs_fs/recovery.c Tue Dec 3 17:20:28 2013
@@ -288,10 +288,10 @@ svn_fs_fs__find_max_ids(svn_fs_t *fs,
SVN_ERR_ASSERT(ffd->format < SVN_FS_FS__MIN_NO_GLOBAL_IDS_FORMAT);
SVN_ERR(svn_fs_fs__rev_get_root(&root_id, fs, youngest, pool));
+ SVN_ERR(svn_fs_fs__open_pack_or_rev_file(&rev_file, fs, youngest, pool));
SVN_ERR(svn_fs_fs__item_offset(&root_offset, fs, rev_file, youngest, NULL,
svn_fs_fs__id_item(root_id), pool));
- SVN_ERR(svn_fs_fs__open_pack_or_rev_file(&rev_file, fs, youngest, pool));
SVN_ERR(recover_find_max_ids(fs, youngest, rev_file, root_offset,
max_node_id, max_copy_id, pool));
SVN_ERR(svn_fs_fs__close_revision_file(rev_file));