Author: bdonlan
Date: 2004-06-05 17:38:52 -0400 (Sat, 05 Jun 2004)
New Revision: 227
Modified:
trunk/dev-tools/cold-backup.pl
Log:
Check for single quotes in paths
Modified: trunk/dev-tools/cold-backup.pl
===================================================================
--- trunk/dev-tools/cold-backup.pl 2004-06-05 21:37:23 UTC (rev 226)
+++ trunk/dev-tools/cold-backup.pl 2004-06-05 21:38:52 UTC (rev 227)
@@ -56,6 +56,11 @@
######################################################################
# Main
+if ($repo =~ /'/ || $backup_dir =~ /'/) {
+ print "Sorry, the full repository and backup paths must not contain '.";
+ exit 1;
+}
+
print "Beginning cold backup of '$repo_dir'.\n";
@@ -91,7 +96,7 @@
### Step 3: Ask subversion to make a dump of a repository.
-system("(svnadmin dump $repo > $backup_file) 2>&1") and exit $?;
+system("(svnadmin dump '$repo' > '$backup_file') 2>&1") and exit $?;
### Step 3+1: If --symlink is given, symlink the latest version.
if ($option{symlink}) {