[Bps-public-commit] r15853 - in SVN-Mirror/trunk: lib/SVN/Mirror
clkao at bestpractical.com
clkao at bestpractical.com
Mon Sep 8 07:40:26 EDT 2008
Author: clkao
Date: Mon Sep 8 07:40:26 2008
New Revision: 15853
Modified:
SVN-Mirror/trunk/ (props changed)
SVN-Mirror/trunk/lib/SVN/Mirror/Ra.pm
Log:
r389 at mtl: clkao | 2006-11-05 03:17:55 +0800
In get_latest_rev, resolve the right HEAD for use in get_logs.
Submitted by: Rolf Schäuble
Modified: SVN-Mirror/trunk/lib/SVN/Mirror/Ra.pm
==============================================================================
--- SVN-Mirror/trunk/lib/SVN/Mirror/Ra.pm (original)
+++ SVN-Mirror/trunk/lib/SVN/Mirror/Ra.pm Mon Sep 8 07:40:26 2008
@@ -614,18 +614,17 @@
my ($rev, $headrev);
my $offset = 2;
- until (defined $rev) {
- # there were once get_log2, but it then was refactored by the svn_ra
- # overhaul. We have to check the version.
- # also, it's harmful to make use of the limited get_log for svn 1.2
- # vs svnserve 1.1, it retrieves all logs and leave the connection
- # in an inconsistent state.
- if ($SVN::Core::VERSION ge '1.2.0' && $self->{rsource} !~ m/^svn/) {
- my $_start = $self->{rsource} =~ m/^file/ ? 0 : -1;
- $ra->get_log ([''], -1, $_start, 1, 0, 1,
- sub { $rev = $_[1] });
- }
- else {
+ # there were once get_log2, but it then was refactored by the svn_ra
+ # overhaul. We have to check the version.
+ # also, it's harmful to make use of the limited get_log for svn 1.2
+ # vs svnserve 1.1, it retrieves all logs and leave the connection
+ # in an inconsistent state.
+ if ($SVN::Core::VERSION ge '1.2.0' && $self->{rsource} !~ m/^svn/) {
+ $ra->get_log ([''], $ra->get_latest_revnum, 0, 1, 0, 1,
+ sub { $rev = $_[1] });
+ }
+ else {
+ until (defined $rev) {
$headrev = $ra->get_latest_revnum
unless defined $headrev;
More information about the Bps-public-commit
mailing list