diff --git a/source/net/yacy/document/content/SurrogateReader.java b/source/net/yacy/document/content/SurrogateReader.java index 0bb47b8f3..a24f77678 100644 --- a/source/net/yacy/document/content/SurrogateReader.java +++ b/source/net/yacy/document/content/SurrogateReader.java @@ -178,12 +178,11 @@ public class SurrogateReader extends DefaultHandler implements Runnable { private boolean isSolrDump() { try { - if (this.inputStream.available() < 60) return false; byte[] b = new byte[100]; this.inputStream.read(b); try { String s = UTF8.String(b); - if (s.contains("") && s.contains("")) { + if ((s.contains("") && s.contains("")) || s.startsWith("")) { this.inputStream.unread(b); return true; } diff --git a/source/net/yacy/search/Switchboard.java b/source/net/yacy/search/Switchboard.java index bae47c53f..4d9464ed0 100644 --- a/source/net/yacy/search/Switchboard.java +++ b/source/net/yacy/search/Switchboard.java @@ -1945,9 +1945,7 @@ public final class Switchboard extends serverSwitch { InputStream is = null; try { is = new BufferedInputStream(new FileInputStream(infile)); - if ( s.endsWith(".gz") ) { - is = new GZIPInputStream(is); - } + if (s.endsWith(".gz")) is = new GZIPInputStream(is, 65535); processSurrogate(is, infile.getName()); } catch (final IOException e ) { ConcurrentLog.logException(e);