diff options
author | Keiron Liddle <keiron@apache.org> | 2001-10-11 09:13:33 +0000 |
---|---|---|
committer | Keiron Liddle <keiron@apache.org> | 2001-10-11 09:13:33 +0000 |
commit | 9bdae5379ad37ea10dbbb649612d771ce0f45198 (patch) | |
tree | cb4729a30e717bb33290803d651942ac39c0e514 | |
parent | 648173146fb3ef5d7cd74b63c024cb6d759f4bdf (diff) | |
download | xmlgraphics-fop-9bdae5379ad37ea10dbbb649612d771ce0f45198.tar.gz xmlgraphics-fop-9bdae5379ad37ea10dbbb649612d771ce0f45198.zip |
throws a different error if base dir not specified
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@194497 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | src/org/apache/fop/image/FopImageFactory.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/org/apache/fop/image/FopImageFactory.java b/src/org/apache/fop/image/FopImageFactory.java index 9a2650c07..4e1ea97e6 100644 --- a/src/org/apache/fop/image/FopImageFactory.java +++ b/src/org/apache/fop/image/FopImageFactory.java @@ -76,6 +76,12 @@ public class FopImageFactory { } catch (Exception e) { // maybe relative URL context_url = null; + String base = Configuration.getStringValue("baseDir"); + if(base == null) { + throw new FopImageException("Error with image URL: " + + e.getMessage() + + " and no base directory is specified"); + } try { absoluteURL = new URL(Configuration.getStringValue("baseDir") + absoluteURL.getFile()); |