Enlightenment CVS committal

Author  : sebastid
Project : e17
Module  : apps/e

Dir     : e17/apps/e/src/modules/temperature


Modified Files:
        e_mod_main.c 


Log Message:
Fix ecore_file_ls usage.

===================================================================
RCS file: 
/cvsroot/enlightenment/e17/apps/e/src/modules/temperature/e_mod_main.c,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -3 -r1.40 -r1.41
--- e_mod_main.c        24 Sep 2005 13:42:05 -0000      1.40
+++ e_mod_main.c        6 Oct 2005 19:37:18 -0000       1.41
@@ -987,7 +987,7 @@
      }
 #else  
    therms = ecore_file_ls("/proc/acpi/thermal_zone");
-   if (!therms || ecore_list_is_empty(therms))
+   if ((!therms) || ecore_list_is_empty(therms))
      {
        FILE *f;
 
@@ -1001,6 +1001,7 @@
          }
        else
          {
+            if (therms) ecore_list_destroy(therms);
             therms = ecore_file_ls("/sys/bus/i2c/devices");
             if ((therms) && (!ecore_list_is_empty(therms)))
               {
@@ -1034,6 +1035,7 @@
                              }
                         }
                    }
+                 ecore_list_destroy(therms);
               }
          }
      }
@@ -1056,10 +1058,9 @@
                    ret = 1;
                  fclose(f);
               }
-            free(name);
          }
+       ecore_list_destroy(therms);
      }
-   if (therms) ecore_list_destroy(therms);
 #endif   
    
    if (ef->conf->units == FAHRENHEIT)




-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to