fix graphs after r1750, sigh

git-svn-id: http://www.observium.org/svn/observer/trunk@1754 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Tom Laermans
2010-12-02 18:12:50 +00:00
parent 588f353b55
commit 3133a5b2fd
2 changed files with 5 additions and 8 deletions

View File

@ -64,10 +64,9 @@ if (is_file($config['install_dir'] . "/html/includes/graphs/$type/$subtype.inc.p
}
}
}
if (!$auth)
{
include($config['install_dir'] . "/html/includes/graphs/$type/auth.inc.php");
}
include($config['install_dir'] . "/html/includes/graphs/$type/auth.inc.php");
if ($auth)
{
include($config['install_dir'] . "/html/includes/graphs/$type/$subtype.inc.php");
@ -117,7 +116,8 @@ if (!$auth)
$rrd_cmd = $config['rrdtool'] . " graph $graphfile $rrd_options" . $rrd_switches;
$woo = shell_exec($rrd_cmd);
if ($_GET['debug']) { echo("<pre>".$rrd_cmd."</pre>"); }
if (is_file($graphfile)) {
if (is_file($graphfile))
{
header('Content-type: image/png');
$fd = fopen($graphfile,'r');fpassthru($fd);fclose($fd);
unlink($graphfile);

View File

@ -17,7 +17,4 @@ if(is_numeric($id))
}
}
?>