mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
Fix potential bug in UPnP config.
If the shaper has never been used, the value being checked may not exist or not be an array.
This commit is contained in:
parent
9568c1a1b8
commit
02afa68458
@ -34,7 +34,11 @@
|
||||
function upnp_validate_queue($qname) {
|
||||
read_altq_config();
|
||||
$qlist = get_altq_name_list();
|
||||
return in_array($qname, $qlist);
|
||||
if (is_array($qlist)) {
|
||||
return in_array($qname, $qlist);
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
function upnp_validate_ip($ip, $check_cdir) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user