~rgrjr/rgrjr-scripts

7df43449d38c54e21e5e206abfeb1ee495bc747c — Bob Rogers 1 year, 11 months ago 9b5e44a
Fix some undef warnings in parse_bzr

* vc-chrono-log.pl:
   + (parse_bzr):  Fix some undef warnings.
1 files changed, 6 insertions(+), 4 deletions(-)

M vc-chrono-log.pl
M vc-chrono-log.pl => vc-chrono-log.pl +6 -4
@@ 333,7 333,7 @@ sub parse_bzr {
	my $message = '';
	my $files;
	chomp($line = <$source>);
	while ($line =~ /^\s*([^:]+):\s*(.*)/) {
	while ($line && $line =~ /^\s*([^:]+):\s*(.*)/) {
	    my ($key, $value) = ($1, $2);
	    if ($key eq 'message') {
		# Read the commit message.


@@ 350,11 350,13 @@ sub parse_bzr {
	    elsif ($key eq 'modified') {
		# Read modified files.
		chomp($line = <$source>);
		while ($line =~ s/^  //) {
		while ($line && $line =~ s/^  //) {
		    my $rev = RGR::CVS::FileRevision->new
			(file_name => $line);
		    push(@$files, $rev);
		    chomp($line = <$source>);
		    $line = <$source>;
		    chomp($line)
			if $line;
		}
	    }
	    else {


@@ 362,7 364,7 @@ sub parse_bzr {
		chomp($line = <$source>);
	    }
	}
	unless ($line eq BZR_DIVIDER) {
	if ($line && $line ne BZR_DIVIDER) {
	    # This is all we expect to see betwen revisions.
	    warn "$.:  Unexpected line: $line";
	}