Project

General

Profile

Bug #1028

filter.inc - discover_pkg_rules

Added by Serg Dvoriancev over 8 years ago. Updated over 8 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
-
Target version:
Start date:
11/20/2010
Due date:
% Done:

0%

Estimated time:
Affected Version:
Affected Architecture:

Description

filter.inc
Function discover_pkg_rules

Symptoms:
Errors in syslog
check_reload_status: syncing firewall
php: : The command '/sbin/pfctl -nf /tmp/rules.test.packages' returned exit code '1', the output was '/tmp/rules.test.packages:17: syntax error /tmp/rules.test.packages:18: syntax error'
php: : There was an error while parsing the package filter rules for /usr/local/pkg/havp.inc.

This message exists even havp_generate_rules returned empty string.

Bug:
$status = mwexec("/sbin/pfctl -nf {$g['tmp_path']}/rules.test.packages");
if ($status <> 0) {

In this code $status contains not-numeric value "0", and expression ($status <> 0) always TRUE, becose comparing different types.
Maybe good idea convert $status to the numeric type ?

History

#1 Updated by Serg Dvoriancev over 8 years ago

Hmm.. sorry
I found my error in rules.

Task can be closed.

#2 Updated by Chris Buechler over 8 years ago

  • Status changed from New to Closed

Also available in: Atom PDF