File CVE-2017-14976.patch of Package poppler.30682
From da63c35549e8852a410946ab016a3f25ac701bdf Mon Sep 17 00:00:00 2001
From: Albert Astals Cid <aacid@kde.org>
Date: Thu, 14 Sep 2017 19:14:41 +0200
Subject: [PATCH] FoFiType1C::convertToType0: Fix crash in broken files
Bug #102724
---
fofi/FoFiType1C.cc | 3 +++
1 file changed, 3 insertions(+)
diff --git a/fofi/FoFiType1C.cc b/fofi/FoFiType1C.cc
index 7a827855..7c9494f5 100644
--- a/fofi/FoFiType1C.cc
+++ b/fofi/FoFiType1C.cc
@@ -898,6 +898,9 @@ void FoFiType1C::convertToType0(char *psName, int *codeMap, int nCodes,
}
}
+ if (fd >= nFDs)
+ continue;
+
// font dictionary (unencrypted section)
(*outputFunc)(outputStream, "16 dict begin\n", 14);
(*outputFunc)(outputStream, "/FontName /", 11);
--
2.14.2