removed some warnings

This commit is contained in:
Michael Peter Christen 2015-01-27 17:00:20 +01:00
parent 783cf6fbc7
commit bee5ee7cce
9 changed files with 7 additions and 20 deletions

View File

@ -154,9 +154,8 @@ public class ViewImage {
image = ImageParser.parse(urlString, imgb);
if (image == null) {
return null;
} else {
if ((auth && (width == 0 || height == 0) && maxwidth == 0 && maxheight == 0)) return ext == null ? image : new EncodedImage(image, ext, isStatic);
}
if ((auth && (width == 0 || height == 0) && maxwidth == 0 && maxheight == 0)) return ext == null ? image : new EncodedImage(image, ext, isStatic);
// find original size
final int h = image.getHeight(null);
final int w = image.getWidth(null);

View File

@ -38,7 +38,6 @@ import net.yacy.cora.document.encoding.UTF8;
import net.yacy.cora.document.feed.RSSFeed;
import net.yacy.cora.document.feed.RSSMessage;
import net.yacy.cora.document.id.DigestURL;
import net.yacy.cora.protocol.ClientIdentification;
import net.yacy.cora.protocol.RequestHeader;
import net.yacy.cora.util.ConcurrentLog;
import net.yacy.cora.util.Html2Image;

View File

@ -87,14 +87,12 @@ abstract public class AbstractFederateSearchConnector implements FederateSearchC
// mandatory to contain a mapping for "sku" or alternatively "cfg_skufieldname" for a conversion to a final url
if (this.localcfg.contains(CollectionSchema.sku) || this.localcfg.contains("_skufieldname")) {
return true;
} else {
ConcurrentLog.config(this.instancename, "mandatory mapping for sku or _skufieldname missing in " + cfgFileName);
return false;
}
} else {
this.localcfg = null;
ConcurrentLog.config(this.instancename, "mandatory mapping for sku or _skufieldname missing in " + cfgFileName);
return false;
}
this.localcfg = null;
return false;
}
/**

View File

@ -164,9 +164,8 @@ public class FederateSearchManager {
sdl.addAll(fsc.query(query));
}
return sdl;
} else {
return null;
}
return null;
}
/**

View File

@ -492,9 +492,6 @@ public class CrawlQueues {
// we know a peer which should provide remote crawl entries. load them now.
final RSSFeed feed = Protocol.queryRemoteCrawlURLs(this.sb.peers, seed, 60, 10000);
if (feed == null || feed.isEmpty()) {
// something is wrong with this provider. To prevent that we get not stuck with this peer
// we remove it from the peer list
this.sb.peers.peerActions.peerDeparture(seed, "no results from provided remote crawls");
// try again and ask another peer
return remoteCrawlLoaderJob();
}

View File

@ -21,7 +21,6 @@ import net.yacy.cora.document.id.DigestURL;
import net.yacy.cora.protocol.ClientIdentification;
import net.yacy.cora.protocol.Domains;
import net.yacy.cora.protocol.HeaderFramework;
import static net.yacy.cora.protocol.HeaderFramework.http1_1;
import net.yacy.cora.protocol.RequestHeader;
import net.yacy.cora.protocol.ResponseHeader;
import net.yacy.cora.util.ConcurrentLog;

View File

@ -182,9 +182,8 @@ public class AutoSearch extends AbstractBusyThread {
this.lastInitTime = System.currentTimeMillis();
saveasPropFile();
return true;
} else {
return false;
}
return false;
}
/**
@ -305,9 +304,8 @@ public class AutoSearch extends AbstractBusyThread {
int cnt = currentTargets.size();
cnt += querystack.size() * sb.peers.sizeConnected();
return cnt;
} else {
return 0;
}
return 0;
}
@Override

View File

@ -27,7 +27,6 @@
package net.yacy.search.snippet;
import java.io.IOException;
import java.net.MalformedURLException;
import java.util.Comparator;
import java.util.Date;

View File

@ -30,7 +30,6 @@ import java.io.FileInputStream;
import java.io.IOException;
import java.io.OutputStream;
import java.io.PrintStream;
import java.net.InetAddress;
import java.net.MalformedURLException;
import java.util.Date;
import java.util.HashMap;