aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/type
diff options
context:
space:
mode:
authorPim van den Berg2012-12-21 19:08:57 +0100
committerPim van den Berg2012-12-21 19:08:57 +0100
commitf30bbf8be225743711d7b161b59b8fb0c310ab22 (patch)
tree917c65604a1c9fe13573728f6b13922da46b0f68 /type
parentplugin/mysql: add support for cache_result, cache_size, threads, total_threads (diff)
downloadapt-panopticon_cgp-f30bbf8be225743711d7b161b59b8fb0c310ab22.zip
apt-panopticon_cgp-f30bbf8be225743711d7b161b59b8fb0c310ab22.tar.gz
apt-panopticon_cgp-f30bbf8be225743711d7b161b59b8fb0c310ab22.tar.bz2
apt-panopticon_cgp-f30bbf8be225743711d7b161b59b8fb0c310ab22.tar.xz
type: resolve undefined variable $c and $raw notices
Reported-by: Philipp Hellmich <Philipp.Hellmich@Bertelsmann.de>
Diffstat (limited to 'type')
-rw-r--r--type/Default.class.php1
-rw-r--r--type/GenericIO.class.php1
-rw-r--r--type/GenericStacked.class.php4
3 files changed, 3 insertions, 3 deletions
diff --git a/type/Default.class.php b/type/Default.class.php
index 13e45c9..26189c7 100644
--- a/type/Default.class.php
+++ b/type/Default.class.php
@@ -35,6 +35,7 @@ class Type_Default {
35 } 35 }
36 36
37 function rainbow_colors() { 37 function rainbow_colors() {
38 $c = 0;
38 $sources = count($this->rrd_get_sources()); 39 $sources = count($this->rrd_get_sources());
39 foreach ($this->rrd_get_sources() as $ds) { 40 foreach ($this->rrd_get_sources() as $ds) {
40 # hue (saturnation=1, value=1) 41 # hue (saturnation=1, value=1)
diff --git a/type/GenericIO.class.php b/type/GenericIO.class.php
index bbbbea7..42314fd 100644
--- a/type/GenericIO.class.php
+++ b/type/GenericIO.class.php
@@ -9,6 +9,7 @@ class Type_GenericIO extends Type_Default {
9 9
10 $sources = $this->rrd_get_sources(); 10 $sources = $this->rrd_get_sources();
11 11
12 $raw = null;
12 if ($this->scale) 13 if ($this->scale)
13 $raw = '_raw'; 14 $raw = '_raw';
14 $i=0; 15 $i=0;
diff --git a/type/GenericStacked.class.php b/type/GenericStacked.class.php
index a0ae4c5..7c65ddd 100644
--- a/type/GenericStacked.class.php
+++ b/type/GenericStacked.class.php
@@ -9,11 +9,9 @@ class Type_GenericStacked extends Type_Default {
9 9
10 $sources = $this->rrd_get_sources(); 10 $sources = $this->rrd_get_sources();
11 11
12 $raw = null;
12 if ($this->scale) 13 if ($this->scale)
13 $raw = '_raw'; 14 $raw = '_raw';
14 else
15 $raw = null;
16
17 $i=0; 15 $i=0;
18 foreach ($this->tinstances as $tinstance) { 16 foreach ($this->tinstances as $tinstance) {
19 foreach ($this->data_sources as $ds) { 17 foreach ($this->data_sources as $ds) {