Fix graph argument issues (#12868)

* Fix top devices widget storage graphs
referenced the wrong graph, caused it to not work because device was not set.

* Handle feedback from rrdtool properly
This commit is contained in:
Tony Murray
2021-05-13 11:27:05 -05:00
committed by GitHub
parent 2c8576ea79
commit 1bf9afb744
2 changed files with 33 additions and 6 deletions

View File

@@ -73,7 +73,7 @@ if (! empty($command_only)) {
echo "<div class='infobox'>";
echo "<p style='font-size: 16px; font-weight: bold;'>RRDTool Command</p>";
echo "<pre class='rrd-pre'>";
echo 'rrdtool ' . Rrd::buildCommand('graph', '-', $rrd_options);
echo escapeshellcmd('rrdtool ' . Rrd::buildCommand('graph', Config::get('temp_dir') . '/' . strgen(), $rrd_options));
echo '</pre>';
try {
Rrd::graph($rrd_options);