From 7518cb571069f23a5402243f4019d25710bab188 Mon Sep 17 00:00:00 2001 From: Keiron Liddle Date: Tue, 5 Jun 2001 12:55:18 +0000 Subject: [PATCH] sets baseDir to a URL string rather than a file path string git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@194271 13f79535-47bb-0310-9956-ffa450edef68 --- src/org/apache/fop/apps/Options.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/org/apache/fop/apps/Options.java b/src/org/apache/fop/apps/Options.java index 60a5a4148..6ed8322fe 100644 --- a/src/org/apache/fop/apps/Options.java +++ b/src/org/apache/fop/apps/Options.java @@ -98,8 +98,11 @@ public class Options { //set base directory String baseDir = Configuration.getStringValue("baseDir"); if (baseDir == null) { - baseDir = new File(clOptions.getInputFile().getAbsolutePath()).getParent(); - Configuration.put("baseDir",baseDir); + try { + baseDir = new File(clOptions.getInputFile().getAbsolutePath()).getParentFile().toURL().toExternalForm(); + Configuration.put("baseDir", baseDir); + } catch(Exception e) { + } } if (errorDump) { MessageHandler.logln("base directory: " + baseDir); -- 2.39.5