On Sun, 8 Aug 2010, Enlightenment SVN wrote:
> Log: > eina: fix strdup calloc, it's number of elements and then size, and not the > other way around. in the end, it's the same, it's the multiplication of the size by the nbr of elements, and as the multiplication with real numbers is commutative... Vincent > Author: tasn > Date: 2010-08-08 05:03:18 -0700 (Sun, 08 Aug 2010) > New Revision: 50898 > > Modified: > trunk/eina/src/lib/eina_unicode.c > > Modified: trunk/eina/src/lib/eina_unicode.c > =================================================================== > --- trunk/eina/src/lib/eina_unicode.c 2010-08-08 11:53:33 UTC (rev 50897) > +++ trunk/eina/src/lib/eina_unicode.c 2010-08-08 12:03:18 UTC (rev 50898) > @@ -116,7 +116,7 @@ > int len; > > len = eina_unicode_strlen(text); > - ustr = (Eina_Unicode *)calloc(sizeof(Eina_Unicode), len + 1); > + ustr = (Eina_Unicode *)calloc(len + 1, sizeof(Eina_Unicode)); > memcpy(ustr, text, len * sizeof(Eina_Unicode)); > > return ustr; > > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by > > Make an app they can't live without > Enter the BlackBerry Developer Challenge > http://p.sf.net/sfu/RIM-dev2dev > _______________________________________________ > enlightenment-svn mailing list > enlightenment-...@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/enlightenment-svn > > ------------------------------------------------------------------------------ This SF.net email is sponsored by Make an app they can't live without Enter the BlackBerry Developer Challenge http://p.sf.net/sfu/RIM-dev2dev _______________________________________________ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel