Commit e09b62e3 authored by Mike Hibler's avatar Mike Hibler
Browse files

More nits related to root's .ssh dir.

parent ef076c85
...@@ -222,7 +222,8 @@ sub doboot() ...@@ -222,7 +222,8 @@ sub doboot()
} }
close(NKEYS); close(NKEYS);
if (! -e $authkeysold && system("cp -pf $authkeys $authkeysold")) { if (-e $authkeys && ! -e $authkeysold &&
system("cp -pf $authkeys $authkeysold")) {
warning("Could not backup $authkeys"); warning("Could not backup $authkeys");
} }
if (system("mv -f $authkeysnew $authkeys")) { if (system("mv -f $authkeysnew $authkeys")) {
......
...@@ -260,6 +260,7 @@ if (! -x "$BINDIR/rc/rc.localize" || system("$BINDIR/rc/rc.localize boot")) { ...@@ -260,6 +260,7 @@ if (! -x "$BINDIR/rc/rc.localize" || system("$BINDIR/rc/rc.localize boot")) {
system("mv $ROOTSSHDIR.bak $ROOTSSHDIR"); system("mv $ROOTSSHDIR.bak $ROOTSSHDIR");
die("Could not clean root .ssh directory"); die("Could not clean root .ssh directory");
} }
system("rm -rf $ROOTSSHDIR.bak");
print "Cleaning mail spool files ...\n"; print "Cleaning mail spool files ...\n";
system("rm -rf $MAILDIR/*"); system("rm -rf $MAILDIR/*");
......
...@@ -366,6 +366,7 @@ if (! -x "$BINDIR/rc/rc.localize" || system("$BINDIR/rc/rc.localize boot")) { ...@@ -366,6 +366,7 @@ if (! -x "$BINDIR/rc/rc.localize" || system("$BINDIR/rc/rc.localize boot")) {
system("mv $ROOTSSHDIR.bak $ROOTSSHDIR"); system("mv $ROOTSSHDIR.bak $ROOTSSHDIR");
die("Could not clean root .ssh directory"); die("Could not clean root .ssh directory");
} }
system("rm -rf $ROOTSSHDIR.bak");
print "Cleaning mail spool files ...\n"; print "Cleaning mail spool files ...\n";
system("rm -rf $MAILDIR/*"); system("rm -rf $MAILDIR/*");
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment