Subject: | diff fails if revision numbers are omitted |
Distribition: Rcs-Agent-1.01
Perl version: 5.005_03
Operating system: Linux 2.2.14-5.0 (RedHat)
Bug details:
sub diff : documentation states that args 'revision1' and 'revision2' are optional, but the code reports "invalid revision number / tag supplied" if either is omitted.
Patch attached that fixes this for me. I haven't tried it anywhere else.
--- Agent.pm Sun May 5 21:23:29 2002
+++ Agent.pm.v1.21 Tue Feb 19 18:02:43 2002
@@ -3,10 +3,6 @@
# An RCS frobnicator
#
# $Id: Agent.pm,v 1.21 2002/02/19 18:02:43 nick Exp $
-#
-# ** Patched by B Mills, 2002/05/05:
-# sub diff: allow 'revision1' and/or 'revision2' to be omitted from arg list
-# ** End of Patch note
package Rcs::Agent;
@@ -601,8 +597,6 @@
}
foreach my $rev ($args{revision1}, $args{revision2}) {
- if (defined $rev)
- {
# We can either have a revision or a tag here
unless (defined ($self->{revisions}->{$rev}) ||
defined ($self->{symbols}->{$rev})) {
@@ -611,7 +605,6 @@
}
$cmdargs .= " -r".shell_quote("$rev");
- }
}
my $command = "rcsdiff -q $cmdargs ".shell_quote($self->{rcsfile});