Commit 1e6e1b8390868c1a1c749f0a8434381bc9724c95

Werner Lemberg 2014-11-20T21:07:56

* src/base/ftbitmap.c (FT_Bitmap_New): Check argument.

diff --git a/ChangeLog b/ChangeLog
index 375f759..65e5c16 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2014-11-20  Werner Lemberg  <wl@gnu.org>
+
+	* src/base/ftbitmap.c (FT_Bitmap_New): Check argument.
+
 2014-11-19  Werner Lemberg  <wl@gnu.org>
 
 	Change some fields in `FT_Bitmap' to unsigned type.
diff --git a/src/base/ftbitmap.c b/src/base/ftbitmap.c
index 3e98079..d333643 100644
--- a/src/base/ftbitmap.c
+++ b/src/base/ftbitmap.c
@@ -33,7 +33,8 @@
   FT_EXPORT_DEF( void )
   FT_Bitmap_New( FT_Bitmap  *abitmap )
   {
-    *abitmap = null_bitmap;
+    if ( abitmap )
+      *abitmap = null_bitmap;
   }