Merge branch 'master' of ssh://git@gitorious.org/yacy/rc1.git

This commit is contained in:
Michael Peter Christen 2014-03-24 09:57:04 +01:00
commit 3aa6a1207a
4 changed files with 12 additions and 3 deletions

View File

@ -91,6 +91,8 @@ public class WordCache {
}
} catch (final IOException e) {
// finish
} finally {
reader.close();
}
}

View File

@ -69,6 +69,8 @@ public class KeyList implements Iterable<String> {
}
} catch (final IOException e) {
// finish
} finally {
reader.close();
}
}

View File

@ -161,14 +161,18 @@ public class Switchboard {
* @param propFile
*/
public static void load(File propFile) {
FileInputStream fis = null;
try {
properties.load(new FileInputStream(propFile));
fis = new FileInputStream(propFile);
properties.load(fis);
} catch (final FileNotFoundException e1) {
log.info("error: file dispatcher.properties does not exist. Exit");
System.exit(-1);
} catch (final IOException e1) {
log.info("error: file dispatcher.properties cannot be readed. Exit");
System.exit(-1);
} finally {
if (fis != null) try { fis.close(); } catch (IOException ex) { }
}
}

View File

@ -538,8 +538,9 @@ public final class yacy {
if (configFile.exists()) {
Properties p = new Properties();
try {
p.load(new FileInputStream(configFile));
FileInputStream fis = new FileInputStream(configFile);
p.load(fis);
fis.close();
// Test for server access restriction (is implemented using Jetty IPaccessHandler which does not support IPv6
// try to disavle IPv6
String teststr = p.getProperty("serverClient", "*");