Enlightenment CVS committal

Author  : tsauerbeck
Project : e17
Module  : libs/edje

Dir     : e17/libs/edje/src/lib


Modified Files:
        edje_text.c 


Log Message:
fixed a buffer overflow vulnerability
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/edje/src/lib/edje_text.c,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -3 -r1.23 -r1.24
--- edje_text.c 30 Oct 2004 12:12:02 -0000      1.23
+++ edje_text.c 30 Oct 2004 15:04:51 -0000      1.24
@@ -295,7 +295,7 @@
    Evas_Coord  tw, th;
    Evas_Coord  ox, oy, sw, sh;
    char    *buf = NULL;
-   char     buf2[4096];
+   char     font_buf[4096];
    int      inlined_font = 0;
    
 
@@ -331,9 +331,8 @@
             
             if ((fnt->entry) && (!strcmp(fnt->entry, font)))
               {
-                 strcpy(buf2, "fonts/");
-                 strcat(buf2, font);
-                 font = buf2;
+                 snprintf(font_buf, sizeof(font_buf), "fonts/%s", font);
+                 font = font_buf;
                  inlined_font = 1;
                  break;
               }




-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to