i3 - improved tiling WM


Make sure colorful_output variable is initialized.

Patch status: rejected

Patch by Emil Mikulic

To apply this patch, use:
curl http://cr.i3wm.org/patch/14/raw.patch | git am

b/src/print_cpu_temperature.c

13
@@ -38,7 +38,6 @@ void print_cpu_temperature_info(yajl_gen json_gen, char *buffer, int zone, const
14
 #ifdef THERMAL_ZONE
15
         const char *walk;
16
         char *outwalk = buffer;
17
-	bool colorful_output;
18
 
19
         if (path == NULL)
20
                 asprintf(&thermal_zone, THERMAL_ZONE, zone);
21
@@ -64,6 +63,7 @@ void print_cpu_temperature_info(yajl_gen json_gen, char *buffer, int zone, const
22
                         if (temp == LONG_MIN || temp == LONG_MAX || temp <= 0)
23
                                 *(outwalk++) = '?';
24
                         else {
25
+                                bool colorful_output = false;
26
                                 if ((temp/1000) >= max_threshold) {
27
                                         START_COLOR("color_bad");
28
                                         colorful_output = true;
29
@@ -102,6 +102,7 @@ void print_cpu_temperature_info(yajl_gen json_gen, char *buffer, int zone, const
30
 			mib[3] = SENSOR_TEMP;
31
 			/* Limit to temo0, but should retrieve from a full path... */
32
 			for (numt = 0; numt < 1 /*sensordev.maxnumt[SENSOR_TEMP]*/; numt++) {
33
+                                bool colorful_output = false;
34
 				mib[4] = numt;
35
 				if (sysctl(mib, 5, &sensor, &slen, NULL, 0) == -1) {
36
 					if (errno != ENOENT) {