From 221423156f38c059e608604cb46b0e1608cb166f Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Fri, 16 Nov 2007 10:25:06 +0000 Subject: fixes to ctan-check git-svn-id: svn://tug.org/texlive/trunk@5434 c570f23f-e606-0410-a88d-b1316a301751 --- Master/tlpkg/bin/ctan-check | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/Master/tlpkg/bin/ctan-check b/Master/tlpkg/bin/ctan-check index ef0dde02a4f..6aabfb18124 100755 --- a/Master/tlpkg/bin/ctan-check +++ b/Master/tlpkg/bin/ctan-check @@ -249,7 +249,10 @@ sub do_tlp my $needed = 0; my $tlp = $tlpdb->get_package($tlpn); - die("Cannot get package $tlpn, strange!\n") unless (defined($tlp)); + if (not(defined($tlp))) { + warn("Cannot get package $tlpn, strange!\n"); + return 1; + } chomp (my $ctan_dir = `$mydir/tlpkginfo --ctan-dir '$tlpn'`); if (! $ctan_dir) { @@ -272,7 +275,7 @@ sub do_tlp } (my $basefile = $file) =~ s,^.*/,,; - chomp (my @ctan_files = `find $tpm{CTANdir}/ -name $basefile`); + chomp (my @ctan_files = `find $ctan_dir/ -name $basefile`); #warn "ctan find $basefile: @ctan_files\n"; # the trailing / is so if we happen to hit a symlink on CTAN, it'll # go through. @@ -282,7 +285,7 @@ sub do_tlp #warn "ctan file is $ctan_file\n"; if (! -e $ctan_file) { # maybe it'll be there with a case change in the name - chomp (@ctan_files = `find $tpm{CTANdir}/ -iname $basefile`); + chomp (@ctan_files = `find $ctan_dir/ -iname $basefile`); next if @ctan_files > 1; # if more than one file by same name, skip $ctan_file = $ctan_files[0]; @@ -310,7 +313,7 @@ sub do_tlp # xx check ctan dir for new files if (@compared == 0) { - warn "\n$tpm: no files to compare in $tpm{CTANdir}, fixme!\n"; + warn "\n$tpm: no files to compare in $ctan_dir, fixme!\n"; warn "(tpm_files = @tpm_files)\n"; } elsif ($needed == 0) { print "ok, " . (@compared + 0) . " compared (@compared)\n" -- cgit v1.2.3