fixed segmantation fault
authorvlad <vlad@vlanout.(none)>
Sun, 25 Jul 2010 12:54:31 +0000 (15:54 +0300)
committervlad <vlad@vlanout.(none)>
Sun, 25 Jul 2010 12:54:31 +0000 (15:54 +0300)
applet/src/livewp-home-widget.c
applet/src/livewp-main.c

index 384327b..92e0d3d 100644 (file)
@@ -53,7 +53,6 @@ lw_applet_realize (GtkWidget *widget)
     desktop_plugin->priv->view = id;
     g_free(strid); 
     
-    fprintf(stderr,"ID !!!!!!!!!! %i\n",id);
 
     switch (id){
            case 0: child_argv[1] = "1";
@@ -67,7 +66,6 @@ lw_applet_realize (GtkWidget *widget)
     }
     desktop_plugin->priv->pid = fork();
     if (desktop_plugin->priv->pid == 0){
-       fprintf(stderr,"New proceess !!!!!!!!!! %s\n",child_argv[1]);
        execvp("/usr/bin/livewp", child_argv);
        fprintf(stderr,"Problem with new process");
     }
index 606de53..b16b15f 100644 (file)
@@ -74,10 +74,8 @@ void
 view_changed (GConfClient *client, guint cnxn_id,
                  GConfEntry *entry, Animation_WallpaperPrivate *priv)
 {
-    GConfValue *value;
-    value = gconf_entry_get_value (entry);
-    if (value) {
-       if (priv->view == gconf_value_get_int (value))
+   if (entry->value->type == GCONF_VALUE_INT) {
+       if (priv->view == gconf_value_get_int(entry->value))
            priv->visible = TRUE;
        else
            priv->visible = FALSE;
@@ -92,7 +90,6 @@ view_changed (GConfClient *client, guint cnxn_id,
                 priv->long_timer = 0;
             }
        }
-    gconf_value_free(value);
     }
 }
 /*******************************************************************************/