[gs-commits] rev 11361 - trunk/gs/psi

alexcher at ghostscript.com alexcher at ghostscript.com
Tue Jun 8 01:04:11 UTC 2010


Author: alexcher
Date: 2010-06-08 01:04:10 +0000 (Tue, 08 Jun 2010)
New Revision: 11361

Modified:
   trunk/gs/psi/zchar.c
Log:
Check whether the font has /Encoding before trying to use it. Recent FAPI
changes give /BuildChar procedure to all fonts including CIDFont resources.
So the check for non-null pfdata->BuildChar no longer guaranteed that the
font has /Encoding. Bug 691311.


Modified: trunk/gs/psi/zchar.c
===================================================================
--- trunk/gs/psi/zchar.c	2010-06-07 17:14:20 UTC (rev 11360)
+++ trunk/gs/psi/zchar.c	2010-06-08 01:04:10 UTC (rev 11361)
@@ -626,7 +626,8 @@
 		if (chr != gs_no_char &&
 		    !r_has_type(&pfdata->BuildChar, t_null) &&
 		    (glyph == gs_no_glyph ||
-		     (array_get(imemory, &pfdata->Encoding, (long)(chr & 0xff), &eref) >= 0 &&
+		     (!r_has_type(&pfdata->Encoding, t_null) &&
+		       array_get(imemory, &pfdata->Encoding, (long)(chr & 0xff), &eref) >= 0 &&
 		      (glyph_ref(imemory, glyph, &gref), obj_eq(imemory, &gref, &eref))))
 		    ) {
 		    make_int(op, chr & 0xff);



More information about the gs-commits mailing list