--- t1lib-5.1.2.fix/lib/type1/type1.c	2007-12-23 21:19:42.000000000 +0530
+++ t1lib-5.1.2.fix/lib/type1/type1.c	2012-01-03 11:54:52.257808202 +0530
@@ -1289,7 +1289,7 @@ 
 static int DoRead(CodeP)
   int *CodeP;
 {
-  if (strindex >= CharStringP->len) return(FALSE); /* end of string */
+  if (!CharStringP || strindex >= CharStringP->len) return(FALSE); /* end of string */
   /* We handle the non-documented Adobe convention to use lenIV=-1 to
      suppress charstring encryption. */
   if (blues->lenIV==-1) {
@@ -1700,6 +1700,7 @@ 
   long pindex = 0;
   
   /* compute hinting for previous segment! */
+  if (ppoints == NULL) Error0i("RLineTo: No previous point!\n");
   FindStems( currx, curry, currx-ppoints[numppoints-2].x, curry-ppoints[numppoints-2].y, dx, dy);
 
   /* Allocate a new path point and pre-setup data */
@@ -1728,6 +1729,7 @@ 
   long pindex = 0;
   
   /* compute hinting for previous point! */
+  if (ppoints == NULL) Error0i("RRCurveTo: No previous point!\n");
   FindStems( currx, curry, currx-ppoints[numppoints-2].x, curry-ppoints[numppoints-2].y, dx1, dy1);
 
   /* Allocate three new path points and pre-setup data */
@@ -1903,6 +1905,7 @@ 
     FindStems( currx, curry, 0, 0, dx, dy);
   }
   else {
+    if (ppoints == NULL) Error0i("RMoveTo: No previous point!\n");
     FindStems( currx, curry, ppoints[numppoints-2].x, ppoints[numppoints-2].y, dx, dy);
   }
   
