From 37d8817219220ee69cbca32c98d17aa126cd610d Mon Sep 17 00:00:00 2001 From: PiBa-NL Date: Mon, 2 Nov 2015 21:40:30 +0100 Subject: haproxy-devel, array safety check --- config/haproxy-devel/pkg/haproxy.inc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/config/haproxy-devel/pkg/haproxy.inc b/config/haproxy-devel/pkg/haproxy.inc index d9f8242e..638ece28 100644 --- a/config/haproxy-devel/pkg/haproxy.inc +++ b/config/haproxy-devel/pkg/haproxy.inc @@ -2074,6 +2074,9 @@ function haproxy_get_transparent_backends(){ global $config; $a_backends = &$config['installedpackages']['haproxy']['ha_pools']['item']; $transparent_backends = array(); + if (!is_array($a_backends)) { + return $transparent_backends; + } foreach ($a_backends as $backend) { if ($backend["transparent_clientip"] != 'yes') { continue; -- cgit v1.2.3