Blob Blame Raw
diff -up netpbm-10.35.58/lib/ppmdfont.c.ppmdfontfix netpbm-10.35.58/lib/ppmdfont.c
--- netpbm-10.35.58/lib/ppmdfont.c.ppmdfontfix	2009-01-19 09:23:54.000000000 +0100
+++ netpbm-10.35.58/lib/ppmdfont.c	2009-03-23 13:06:36.000000000 +0100
@@ -62,7 +62,8 @@ static void
 readFontHeader(FILE *                   const ifP,
                struct ppmd_fontHeader * const fontHeaderP) {
     
-    fread(&fontHeaderP->signature, 1, sizeof(fontHeaderP->signature), ifP);
+    if (!fread(&fontHeaderP->signature, 1, sizeof(fontHeaderP->signature), ifP))
+	pm_error("Error reading font header.");
     fontHeaderP->format         = fgetc(ifP);
     fontHeaderP->characterCount = fgetc(ifP);
     fontHeaderP->firstCodePoint = fgetc(ifP);