No need for 2 carriage returns after rdr rule.

This commit is contained in:
Scott Ullrich 2005-02-15 00:05:51 +00:00
parent 1e024d52af
commit 564a42cf8e

View File

@ -815,20 +815,20 @@ function filter_nat_rules_generate() {
if ((!$extport[1]) || ($extport[0] == $extport[1])) {
if($rule['protocol'] == "tcp/udp")
$natrules .=
"rdr on $natif proto { tcp udp } from any to {$extaddr} port {$extport[0]} -> {$target} port {$rule['local-port']}\n";
"rdr on $natif proto { tcp udp } from any to {$extaddr} port {$extport[0]} -> {$target} port {$rule['local-port']}";
else
$natrules .=
"rdr on $natif proto " . $rule['protocol'] . " from any to {$extaddr} port {$extport[0]} -> {$target} port {$rule['local-port']}\n";
"rdr on $natif proto " . $rule['protocol'] . " from any to {$extaddr} port {$extport[0]} -> {$target} port {$rule['local-port']}";
} else {
if($rule['protocol'] == "tcp/udp")
$natrules .=
"rdr on $natif proto { tcp udp } from any to {$extaddr} port {$extport[0]}:{$extport[1]} -> {$target} port {$extport[0]}:{$extport[1]}" .
"-> {$target} \n";
"-> {$target}";
else
$natrules .=
"rdr on $natif proto " . $rule['protocol']. " from any to {$extaddr} port {$extport[0]}:{$extport[1]} -> {$target} port {$extport[0]}:{$extport[1]}" .
"-> {$target} \n";
"-> {$target}";
}
$natrules .= "\n";