Enlightenment CVS committal

Author  : sebastid
Project : e17
Module  : libs/epsilon

Dir     : e17/libs/epsilon/src/lib


Modified Files:
        Epsilon.c 


Log Message:
Don't use strlen to check for empty string.

===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/epsilon/src/lib/Epsilon.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -3 -r1.21 -r1.22
--- Epsilon.c   31 Oct 2005 20:29:51 -0000      1.21
+++ Epsilon.c   4 Nov 2005 08:21:28 -0000       1.22
@@ -363,7 +363,7 @@
          strcat (hash_seed, buf);
        }
 
-      if (strlen(hash_seed) > 0)
+      if (hash_seed[0] != 0)
        e->hash = epsilon_hash (hash_seed);
       else
        e->hash = epsilon_hash (e->src);
@@ -442,7 +442,7 @@
       !strcasecmp (&e->src[len - 3], "jpg") && (im = epeg_file_open (e->src)))
     {
       char *dir;
-      if(e->tw == THUMB_SIZE_LARGE)
+      if (e->tw == THUMB_SIZE_LARGE)
         dir = strdup("large");
       else
         dir = strdup("normal");
@@ -568,7 +568,7 @@
        if ((src = imlib_create_cropped_scaled_image (0, 0, iw, ih, tw, th)))
          {
            char *dir;
-           if(e->tw == THUMB_SIZE_LARGE)
+           if (e->tw == THUMB_SIZE_LARGE)
               dir = strdup("large");
            else
               dir = strdup("normal");
@@ -600,9 +600,9 @@
 void
 epsilon_thumb_size(Epsilon *e, Epsilon_Thumb_Size size)
 {
-   if(!e) return;
+   if (!e) return;
    
-   switch(size)
+   switch (size)
      {
       case EPSILON_THUMB_NORMAL:
        e->tw = THUMB_SIZE_NORMAL;




-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to