]> Dogcows Code - chaz/tint2/commitdiff
Fix segfault when the clock has no background in config
authorThierry Lorthiois <lorthiois@bbsoft.fr>
Sun, 20 Feb 2011 22:32:35 +0000 (22:32 +0000)
committerThierry Lorthiois <lorthiois@bbsoft.fr>
Sun, 20 Feb 2011 22:32:35 +0000 (22:32 +0000)
src/clock/clock.c

index ec17a9fad6659477022a0ca76412cad02b9af8e0..73547d155dc21318c1a458d16e167eef05f8e1c5 100644 (file)
@@ -143,7 +143,9 @@ void init_clock_panel(void *p)
 {
        Panel *panel =(Panel*)p;
        Clock *clock = &panel->clock;
-
+       
+       if (clock->area.bg == 0)
+               clock->area.bg = &g_array_index(backgrounds, Background, 0);
        clock->area.parent = p;
        clock->area.panel = p;
        clock->area._draw_foreground = draw_clock;
This page took 0.024591 seconds and 4 git commands to generate.