ganglia webfrontend 3.6.1 division by zero

Bug #1825533 reported by ssducf on 2019-04-19
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ganglia-web (Ubuntu)
Undecided
Unassigned

Bug Description

When columns=0 is selected (to get one line per host), a division by zero error occurs and no graphs are returned.

--- /usr/share/ganglia-webfrontend/cluster_view.php.orig 2019-04-19 09:45:14.581175724 -0400
+++ /usr/share/ganglia-webfrontend/cluster_view.php 2019-04-19 09:47:25.507084333 -0400
@@ -348,7 +348,7 @@
       }
     } else {
       $sorted_list[$host]["metric_image"] = $cell;
- if (! ($i++ % $conf['hostcols']) ) {
+ if ($conf['hostcols']==0 || ! ($i++ % $conf['hostcols']) ) {
         $sorted_list[$host]["br"] = "</tr><tr>";
       } else {
         $sorted_list[$host]["br"] = "";

tags: added: patch
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers