changeset 1:9143a0c4c678

small fix for // in pathnames
author casties
date Thu, 08 Jul 2004 19:27:59 +0200
parents 30497c6a3eca
children b7259a1c85aa
files archiver.pl metacheck.pl
diffstat 2 files changed, 6 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/archiver.pl	Thu Jun 17 17:58:42 2004 +0200
+++ b/archiver.pl	Thu Jul 08 19:27:59 2004 +0200
@@ -16,7 +16,7 @@
 #
 
 # program version
-my $version = "0.5 (15.1.2004)";
+my $version = "0.5.1 (8.7.2004)";
 
 # rewrite XML file (necessary for archive date!)
 my $fix_xml = 1;
@@ -64,8 +64,10 @@
     exit 1;
 }
 my $docdir = $ARGV[0];
+# strip double slashes
+$docdir =~ s/\/\//\//;
 # strip trailing slashes
-$docdir =~ s/\/$//;
+$docdir =~ s/\/+$//;
 if (! -d $docdir) {
     print "ABORT: document directory \'$docdir\' doesn't exist!\n";
     exit 1;
--- a/metacheck.pl	Thu Jun 17 17:58:42 2004 +0200
+++ b/metacheck.pl	Thu Jul 08 19:27:59 2004 +0200
@@ -45,6 +45,8 @@
     logger("ABORT", "no document directory given!");
     exit 1;
 }
+# strip double slashes
+$docdir =~ s/\/\//\//;
 # strip trailing slashes
 $docdir =~ s/\/$//;
 if (! -d $docdir) {