summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Southworth <john.southworth@vyatta.com>2011-05-20 18:08:48 -0500
committerJohn Southworth <john.southworth@vyatta.com>2011-05-20 18:08:48 -0500
commit877e1c6a826ca8367c176882be410a588484cd1c (patch)
treeb0c420a5b51fea0befcf3f929875d1f46428dc4c
parenta5d5cce555c492c33b197297cda6ea33cf3e6599 (diff)
downloadvyatta-op-877e1c6a826ca8367c176882be410a588484cd1c.tar.gz
vyatta-op-877e1c6a826ca8367c176882be410a588484cd1c.zip
only attempt to move the old /config dir if it exists when cloning a configuration
-rwxr-xr-xscripts/vyatta-image-tools.pl2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/vyatta-image-tools.pl b/scripts/vyatta-image-tools.pl
index 034a676..4eaf7bb 100755
--- a/scripts/vyatta-image-tools.pl
+++ b/scripts/vyatta-image-tools.pl
@@ -184,7 +184,7 @@ sub update {
. "Do you wish to continue?";
if (y_or_n("$msg")){
system("rm -rf $to/config.preclone");
- system("mv $to/config $to/config.preclone");
+ system("mv $to/config $to/config.preclone") if ( -d "$to/config" );
rsync("$from/config", $to);
}
}