pango r2818 - in trunk: . pango/opentype
- From: behdad svn gnome org
- To: svn-commits-list gnome org
- Subject: pango r2818 - in trunk: . pango/opentype
- Date: Thu, 29 Jan 2009 09:19:56 +0000 (UTC)
Author: behdad
Date: Thu Jan 29 09:19:56 2009
New Revision: 2818
URL: http://svn.gnome.org/viewvc/pango?rev=2818&view=rev
Log:
2009-01-29 Behdad Esfahbod <behdad gnome org>
* pango/opentype/harfbuzz-impl.c (_hb_alloc): Use calloc(),
instead of malloc()ing and memset()ing.
Modified:
trunk/ChangeLog
trunk/pango/opentype/harfbuzz-impl.c
Modified: trunk/pango/opentype/harfbuzz-impl.c
==============================================================================
--- trunk/pango/opentype/harfbuzz-impl.c (original)
+++ trunk/pango/opentype/harfbuzz-impl.c Thu Jan 29 09:19:56 2009
@@ -38,11 +38,9 @@
if ( size > 0 )
{
- block = malloc( size );
+ block = calloc( 1, size );
if ( !block )
error = ERR(HB_Err_Out_Of_Memory);
- else
- memset( (char*)block, 0, (size_t)size );
}
*perror = error;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]