Enlightenment CVS committal

Author  : rbdpngn
Project : e17
Module  : libs/ewl

Dir     : e17/libs/ewl/src


Modified Files:
        ewl_embed.c ewl_password.c 


Log Message:
Remove the embed widget's printf, and cleanup some possible segv's in the
password widget.

===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/ewl_embed.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -3 -r1.17 -r1.18
--- ewl_embed.c 25 Nov 2003 07:47:29 -0000      1.17
+++ ewl_embed.c 8 Dec 2003 21:59:44 -0000       1.18
@@ -278,12 +278,6 @@
 
        o = EWL_OBJECT(w);
 
-       printf("EWL Embedded Object configured at (%d, %d) and %d x %d\n",
-                       ewl_object_get_current_x(EWL_OBJECT(w)),
-                       ewl_object_get_current_y(EWL_OBJECT(w)),
-                       ewl_object_get_current_w(EWL_OBJECT(w)),
-                       ewl_object_get_current_h(EWL_OBJECT(w)));
-
        /*
         * Configure each of the child widgets.
         */
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/ewl_password.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -3 -r1.2 -r1.3
--- ewl_password.c      7 Dec 2003 21:34:21 -0000       1.2
+++ ewl_password.c      8 Dec 2003 21:59:44 -0000       1.3
@@ -109,7 +109,8 @@
 
        w = EWL_WIDGET(e);
 
-       DRETURN_PTR(strdup(e->real_text), DLEVEL_STABLE);
+       DRETURN_PTR((e->real_text ? strdup(e->real_text) : NULL),
+                       DLEVEL_STABLE);
 }
 
 /**
@@ -149,22 +150,26 @@
        DCHECK_PARAM_PTR("e", e);
 
        s2 = ewl_password_get_text(e);
-       l = strlen(s);
-       l2 = strlen(s2);
+       if (s)
+               l = strlen(s);
+       if (s2)
+               l2 = strlen(s2);
 
        s3 = NEW(char, l + l2 + 1);
        if (!s3) {
-               FREE(s2);
+               IF_FREE(s2);
                DRETURN(DLEVEL_STABLE);
        }
 
        s3[0] = 0;
-       strcat(s3, s2);
-       strcat(s3, s);
+       if (s2)
+               strcat(s3, s2);
+       if (s)
+               strcat(s3, s);
 
        ewl_password_set_text(e, s3);
 
-       FREE(s2);
+       IF_FREE(s2);
        FREE(s3);
 
        DLEAVE_FUNCTION(DLEVEL_STABLE);




-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to