[PATCH 1 of 2] Do not try to load empty files
Wald Commits
scm-commit at wald.intevation.org
Fri Aug 15 11:43:31 CEST 2014
# HG changeset patch
# User Andre Heinecke <andre.heinecke at intevation.de>
# Date 1407774830 -7200
# Node ID 2fcbcc9bb59a6f7248921c699dbbe930cbc883fa
# Parent 7ede7904c8a5cd24b529bbe8391b86840f524efe
Do not try to load empty files.
Aritfacts can be directly defined in the conf.xml nowadays so
an xlink is no longer required to exist.
diff -r 7ede7904c8a5 -r 2fcbcc9bb59a artifacts/src/main/java/org/dive4elements/river/artifacts/context/RiverContextFactory.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/context/RiverContextFactory.java Tue Aug 12 10:57:53 2014 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/context/RiverContextFactory.java Mon Aug 11 18:33:50 2014 +0200
@@ -261,6 +261,9 @@
String xlink = tmp.getAttribute(XPATH_XLINK);
xlink = Config.replaceConfigDir(xlink);
+ if (xlink.isEmpty()) {
+ continue;
+ }
File file = new File(xlink);
if (!file.isFile() || !file.canRead()) {
More information about the Dive4Elements-commits
mailing list