Skip to content
Browse files

bug fix to ensure that a pristine psad.conf file is preserved across …

…--install-test-dir mode
  • Loading branch information...
1 parent 276f516 commit ed34b4c5e3ad36758f9409e6e347b9a21d85f6f1 @mrash committed Apr 17, 2012
Showing with 3 additions and 2 deletions.
  1. +3 −2 install.pl
View
5 install.pl
@@ -270,8 +270,8 @@
### restore the original psad.conf file (this is just the local one in the
### sources directory).
if (-e "${psad_conf_file}.orig") {
- copy "${psad_conf_file}.orig", $psad_conf_file or die "[*] Could not ",
- "copy $psad_conf_file.orig -> $psad_conf_file";
+ unlink $psad_conf_file if -e $psad_conf_file;
+ move "${psad_conf_file}.orig", $psad_conf_file;
}
exit 0;
@@ -1873,6 +1873,7 @@ ()
sub put_string() {
my ($var, $value, $file) = @_;
+
open RF, "< $file" or die "[*] Could not open $file: $!";
my @lines = <RF>;
close RF;

0 comments on commit ed34b4c

Please sign in to comment.
Something went wrong with that request. Please try again.