summaryrefslogtreecommitdiffstats
path: root/usr/local/www/status_rrd_graph_img.php
diff options
context:
space:
mode:
authorPhil Davis <phil.davis@inf.org>2015-05-14 16:49:43 +0545
committerPhil Davis <phil.davis@inf.org>2015-05-14 16:49:43 +0545
commitfa201d6322d936a131aa4b74adf24b903fe0dc41 (patch)
tree28020e29809dbbba0a87beccd2397a069be1783c /usr/local/www/status_rrd_graph_img.php
parent01cced787ca98e9017e339526912865570cf8e17 (diff)
downloadpfsense-fa201d6322d936a131aa4b74adf24b903fe0dc41.zip
pfsense-fa201d6322d936a131aa4b74adf24b903fe0dc41.tar.gz
Add some curlies in status_rrd_graph_img
These "if data" tests look like they should apply to all 4 lines below them. After sorting out this real-looking issue, I can mess with the rest of the formatting...
Diffstat (limited to 'usr/local/www/status_rrd_graph_img.php')
-rw-r--r--usr/local/www/status_rrd_graph_img.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/usr/local/www/status_rrd_graph_img.php b/usr/local/www/status_rrd_graph_img.php
index 74e7d3f..bb84b1d 100644
--- a/usr/local/www/status_rrd_graph_img.php
+++ b/usr/local/www/status_rrd_graph_img.php
@@ -1230,19 +1230,21 @@ else {
/* check modification time to see if we need to generate image */
if (file_exists("$rrdtmppath$curdatabase-$curgraph.png")) {
- if((time() - filemtime("$rrdtmppath$curdatabase-$curgraph.png")) >= 15 ) {
- if($data)
+ if ((time() - filemtime("$rrdtmppath$curdatabase-$curgraph.png")) >= 15 ) {
+ if ($data) {
$_gb = exec("$graphcmd 2>&1", $graphcmdoutput, $graphcmdreturn);
$graphcmdoutput = implode(" ", $graphcmdoutput) . $graphcmd;
flush();
usleep(500);
+ }
}
} else {
- if($data)
+ if ($data) {
$_gb = exec("$graphcmd 2>&1", $graphcmdoutput, $graphcmdreturn);
$graphcmdoutput = implode(" ", $graphcmdoutput) . $graphcmd;
flush();
usleep(500);
+ }
}
if(($graphcmdreturn <> 0) || (! $data)) {
log_error(sprintf(gettext('Failed to create graph with error code %1$s, the error is: %2$s'),$graphcmdreturn,$graphcmdoutput));
OpenPOWER on IntegriCloud