Do not use mwexec when unlink can be used and is faster. This also avoids errors on log from rm(1).

This commit is contained in:
Ermal 2010-10-04 13:13:10 +00:00
parent a17027a6b3
commit da3ee8238a

View File

@ -1328,9 +1328,9 @@ function filter_nat_rules_generate() {
/* XXX: FIX ME! IPV6 */
$natrules .= "rdr on \${$FilterIflist['wan']['descr']} proto ipv6 from any to any -> {$config['diag']['ipv6nat']['ipaddr']}\n";
}
if(file_exists("/var/etc/inetd.conf"))
mwexec("rm /var/etc/inetd.conf");
touch("/var/etc/inetd.conf");
@unlink("/var/etc/inetd.conf");
// Open inetd.conf write handle
$inetd_fd = fopen("/var/etc/inetd.conf","w");
/* add tftp protocol helper */