aboutsummaryrefslogtreecommitdiffstats
path: root/src/java/org/apache/fop/hyphenation
diff options
context:
space:
mode:
Diffstat (limited to 'src/java/org/apache/fop/hyphenation')
-rw-r--r--src/java/org/apache/fop/hyphenation/HyphenationTree.java2
-rw-r--r--src/java/org/apache/fop/hyphenation/PatternParser.java2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/java/org/apache/fop/hyphenation/HyphenationTree.java b/src/java/org/apache/fop/hyphenation/HyphenationTree.java
index 67488c5b5..d145936c6 100644
--- a/src/java/org/apache/fop/hyphenation/HyphenationTree.java
+++ b/src/java/org/apache/fop/hyphenation/HyphenationTree.java
@@ -125,7 +125,7 @@ public class HyphenationTree extends TernaryTree
public void loadPatterns(String filename) throws HyphenationException {
File f = new File(filename);
try {
- InputSource src = new InputSource(f.toURL().toExternalForm());
+ InputSource src = new InputSource(f.toURI().toURL().toExternalForm());
loadPatterns(src);
} catch (MalformedURLException e) {
throw new HyphenationException("Error converting the File '" + f + "' to a URL: "
diff --git a/src/java/org/apache/fop/hyphenation/PatternParser.java b/src/java/org/apache/fop/hyphenation/PatternParser.java
index b0378a40b..2edf64676 100644
--- a/src/java/org/apache/fop/hyphenation/PatternParser.java
+++ b/src/java/org/apache/fop/hyphenation/PatternParser.java
@@ -92,7 +92,7 @@ public class PatternParser extends DefaultHandler implements PatternConsumer {
*/
public void parse(File file) throws HyphenationException {
try {
- InputSource src = new InputSource(file.toURL().toExternalForm());
+ InputSource src = new InputSource(file.toURI().toURL().toExternalForm());
parse(src);
} catch (MalformedURLException e) {
throw new HyphenationException("Error converting the File '" + file + "' to a URL: "