File freetype-bdflib-large-encodings.patch of Package freetype2

--- src/bdf/bdflib.c.orig	2011-10-31 00:25:09.691000464 +0100
+++ src/bdf/bdflib.c	2011-10-31 00:26:16.055000463 +0100
@@ -1594,6 +1594,14 @@
         goto Exit;
       }
 
+      /* Check that the encoding is in the range [0, 65535] because       */
+      /* otherwise p->have (a bitmap with static size) overflows.         */
+      if ( p->glyph_enc >= sizeof(p->have) * 8 )
+      {
+        error = BDF_Err_Invalid_File_Format; /* Not the ideal error code */
+        goto Exit;
+      }
+
       /* Check whether this encoding has already been encountered. */
       /* If it has then change it to unencoded so it gets added if */
       /* indicated.                                                */
openSUSE Build Service is sponsored by