aboutsummaryrefslogtreecommitdiffstats
path: root/config/haproxy-devel/haproxy_socketinfo.inc
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2014-09-23 08:13:18 -0400
committerjim-p <jimp@pfsense.org>2014-09-23 08:13:18 -0400
commit91f558f5bb14486b053ad9fb2a0f24b527665b59 (patch)
tree29b5e3ff6d0d779f378b997320199aad2088ee21 /config/haproxy-devel/haproxy_socketinfo.inc
parent5de466966718de28d50e84f5e7a6b4560aaf643f (diff)
parentd2db08d5449698dcb3e98bcd58b39e8ff4cc23b0 (diff)
downloadpfsense-packages-91f558f5bb14486b053ad9fb2a0f24b527665b59.tar.gz
pfsense-packages-91f558f5bb14486b053ad9fb2a0f24b527665b59.tar.bz2
pfsense-packages-91f558f5bb14486b053ad9fb2a0f24b527665b59.zip
Merge pull request #704 from PiBa-NL/haproxy_1.5.3_extra
Diffstat (limited to 'config/haproxy-devel/haproxy_socketinfo.inc')
-rw-r--r--config/haproxy-devel/haproxy_socketinfo.inc6
1 files changed, 4 insertions, 2 deletions
diff --git a/config/haproxy-devel/haproxy_socketinfo.inc b/config/haproxy-devel/haproxy_socketinfo.inc
index 6beb17c5..cbfb131b 100644
--- a/config/haproxy-devel/haproxy_socketinfo.inc
+++ b/config/haproxy-devel/haproxy_socketinfo.inc
@@ -122,6 +122,8 @@ function haproxy_get_clients($show_traffic = false){// "show sess"
$clients=array();
$sessions = haproxy_socket_command("show sess");
foreach($sessions as $line) {
+ if (trim($line) == "")
+ continue;
list($sessid,$proto,$src,$fe,$be,$srv,$ts,$age,$calls,$rq,$rp,$s0,$s1,$exp) = explode(" ", $line);
#Retrieve data
$sessid = explode(":", $sessid);
@@ -149,10 +151,10 @@ function haproxy_get_clients($show_traffic = false){// "show sess"
$session_data = haproxy_socket_command("show sess {$client['sessid']}");
$client['session_data'] = $session_data;
- $req = explode(" ",$session_data[13]);
+ $req = explode(" ",$session_data[12]);
$x = explode("=",$req[7]);
$client['session_datareq'] = $x[1];
- $res = explode(" ",$session_data[16]);
+ $res = explode(" ",$session_data[15]);
$x = explode("=",$res[7]);
$client['session_datares'] = $x[1];
}