aboutsummaryrefslogtreecommitdiffstats
path: root/src/java
diff options
context:
space:
mode:
authorAdrian Cumiskey <acumiskey@apache.org>2008-04-15 08:53:51 +0000
committerAdrian Cumiskey <acumiskey@apache.org>2008-04-15 08:53:51 +0000
commitbf8220d231490280738f0fb7629f329bf332b2f0 (patch)
tree987027188d56970835adb800832b7a36f5f13ccb /src/java
parent309f4e2998c676913e64070adda8dca5e3768fad (diff)
downloadxmlgraphics-fop-bf8220d231490280738f0fb7629f329bf332b2f0.tar.gz
xmlgraphics-fop-bf8220d231490280738f0fb7629f329bf332b2f0.zip
Merged revisions 647770,648122 via svnmerge from
https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk ........ r647770 | jeremias | 2008-04-14 13:41:00 +0100 (Mon, 14 Apr 2008) | 1 line Fixed a possible follow-up NPE when the TTC cannot be loaded. ........ r648122 | jeremias | 2008-04-15 07:07:00 +0100 (Tue, 15 Apr 2008) | 1 line A note about the generation of event-model.xml. ........ git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/Temp_AFPGOCAResources@648187 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java')
-rw-r--r--src/java/org/apache/fop/fonts/autodetect/FontInfoFinder.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/java/org/apache/fop/fonts/autodetect/FontInfoFinder.java b/src/java/org/apache/fop/fonts/autodetect/FontInfoFinder.java
index b223ea7a1..ce33bc5b6 100644
--- a/src/java/org/apache/fop/fonts/autodetect/FontInfoFinder.java
+++ b/src/java/org/apache/fop/fonts/autodetect/FontInfoFinder.java
@@ -196,7 +196,6 @@ public class FontInfoFinder {
// Get a list of the TTC Font names
List ttcNames = null; //List<String>
String fontFileURI = fontUrl.toExternalForm().trim();
- TTFFontLoader ttfLoader = new TTFFontLoader(fontFileURI, resolver);
InputStream in = null;
try {
in = FontLoader.openFontUri(resolver, fontFileURI);
@@ -207,6 +206,7 @@ public class FontInfoFinder {
if (this.eventListener != null) {
this.eventListener.fontLoadingErrorAtAutoDetection(this, fontFileURI, e);
}
+ return null;
} finally {
IOUtils.closeQuietly(in);
}
@@ -223,7 +223,7 @@ public class FontInfoFinder {
log.debug("Loading " + fontName);
}
try {
- ttfLoader = new TTFFontLoader(fontFileURI, fontName, resolver);
+ TTFFontLoader ttfLoader = new TTFFontLoader(fontFileURI, fontName, resolver);
customFont = ttfLoader.getFont();
if (this.eventListener != null) {
customFont.setEventListener(this.eventListener);