aboutsummaryrefslogtreecommitdiffstats
path: root/CVSROOT
diff options
context:
space:
mode:
authorjoe <joe@FreeBSD.org>2001-09-24 19:19:51 +0800
committerjoe <joe@FreeBSD.org>2001-09-24 19:19:51 +0800
commit6950913ba0aee167720feed93e81591ece69bf8e (patch)
treeea47cef0f235f18e69b7fe19563c5ffafd5dfa8e /CVSROOT
parentf66e433b37ba3c2fc52ae2e28c04c1b90975fada (diff)
downloadfreebsd-ports-gnome-6950913ba0aee167720feed93e81591ece69bf8e.tar.gz
freebsd-ports-gnome-6950913ba0aee167720feed93e81591ece69bf8e.tar.zst
freebsd-ports-gnome-6950913ba0aee167720feed93e81591ece69bf8e.zip
When working out what the previous revision was, for producing the
delta for a removed file for instance, take into account branch points.
Diffstat (limited to 'CVSROOT')
-rwxr-xr-xCVSROOT/log_accum.pl14
1 files changed, 11 insertions, 3 deletions
diff --git a/CVSROOT/log_accum.pl b/CVSROOT/log_accum.pl
index 37650ce6e2fa..89494c1e7698 100755
--- a/CVSROOT/log_accum.pl
+++ b/CVSROOT/log_accum.pl
@@ -329,10 +329,18 @@ sub change_summary_removed {
$rcsfile =~ s|/Attic/|/|; # Remove 'Attic/' if present.
if ($rev and $rcsfile) {
- $rev =~ /(.*)\.([^\.]+)$/;
- my $oldrev = "$1." . ($2 - 1);
+ $rev =~ /(?:(.*)\.)?([^\.]+)\.([^\.]+)$/;
+ my ($base, $r1, $r2) = ($1, $2, $3);
- my $lines = count_lines_in_revision($file, $oldrev);
+ my $prevrev = "";
+ if ($r2 == 1) {
+ $prevrev = $base;
+ } else {
+ $prevrev = "$base." if $base;
+ $prevrev .= "$r1." . ($r2 - 1);
+ }
+
+ my $lines = count_lines_in_revision($file, $prevrev);
$delta = "+0 -$lines";
}