From: Stefan Schantl Date: Thu, 20 May 2021 17:53:00 +0000 (+0200) Subject: ids-functions.pl: Use new system methods X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=05c1831ad4884258cd3325e503e2da4e30df604f;p=people%2Fstevee%2Fipfire-2.x.git ids-functions.pl: Use new system methods Signed-off-by: Stefan Schantl --- diff --git a/config/cfgroot/ids-functions.pl b/config/cfgroot/ids-functions.pl index 2fdae4a7a1..0e397ca192 100644 --- a/config/cfgroot/ids-functions.pl +++ b/config/cfgroot/ids-functions.pl @@ -118,7 +118,7 @@ sub check_and_create_filelayout() { # sub checkdiskspace () { # Call diskfree to gather the free disk space of /var. - my @df = `/bin/df -B M /var`; + my @df = &General::system_output("/bin/df", "-B", "M", "/var"); # Loop through the output. foreach my $line (@df) { @@ -463,7 +463,7 @@ sub call_suricatactrl ($) { # Call the suricatactrl binary and pass the "cron" command # with the requrested interval. - system("$suricatactrl $option $interval &>/dev/null"); + &General::system("$suricatactrl", "$option", "$interval"); # Return "1" - True. return 1; @@ -475,7 +475,7 @@ sub call_suricatactrl ($) { } else { # Call the suricatactrl binary and pass the requrested # option to it. - system("$suricatactrl $option &>/dev/null"); + &General::system("$suricatactrl", "$option"); # Return "1" - True. return 1;