Enlightenment CVS committal

Author  : sebastid
Project : e17
Module  : apps/e

Dir     : e17/apps/e/src/bin


Modified Files:
        e_widget_entry.c 


Log Message:
Fix _e_wid_text_change

===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/e/src/bin/e_widget_entry.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -3 -r1.2 -r1.3
--- e_widget_entry.c    25 Oct 2005 22:01:50 -0000      1.2
+++ e_widget_entry.c    26 Oct 2005 20:41:06 -0000      1.3
@@ -118,23 +118,19 @@
    
    wd = data;      
    
-   if(*(wd->valptr) == NULL) 
+   if (*(wd->valptr) == NULL) 
      {
        size = (strlen(key) + 1) * sizeof(char);
-       *(wd->valptr) = realloc(*(wd->valptr), size);   
+       *(wd->valptr) = malloc(size);   
        snprintf(*(wd->valptr), size, "%s", key);
      }
    else
      {
-       char *tmp;
-       
        size = (strlen(*(wd->valptr)) + strlen(key) + 1) * sizeof(char);
-       tmp = E_NEW(char *, strlen(*(wd->valptr)) + 1);
-       snprintf(tmp, strlen(*(wd->valptr)) + 1, "%s", *(wd->valptr));  
        *(wd->valptr) = realloc(*(wd->valptr), size);   
-       snprintf(*(wd->valptr), size, "%s%s\0", tmp, key);
-       E_FREE(tmp);
+       strcat(*(wd->valptr), key);
      }
+   return 1;
 }
 
 /* externally accessible functions */




-------------------------------------------------------
This SF.Net email is sponsored by the JBoss Inc.
Get Certified Today * Register for a JBoss Training Course
Free Certification Exam for All Training Attendees Through End of 2005
Visit http://www.jboss.com/services/certification for more information
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to