protection against wrong word hash length

see http://www.yacy-forum.de/viewtopic.php?p=35657#35657

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@3723 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
orbiter 18 years ago
parent e897eb9b4a
commit b28e5d0ee9

@ -54,6 +54,7 @@ import de.anomic.plasma.urlPattern.plasmaURLPattern;
import de.anomic.server.logging.serverLog;
import de.anomic.server.serverMemory;
import de.anomic.yacy.yacyDHTAction;
import de.anomic.yacy.yacySeedDB;
public final class plasmaWordIndex implements indexRI {
@ -323,7 +324,11 @@ public final class plasmaWordIndex implements indexRI {
}
public indexContainer getContainer(String wordHash, Set urlselection, long maxTime) {
if ((wordHash == null) || (wordHash.length() != yacySeedDB.commonHashLength)) {
// wrong input
return null;
}
// get from cache
indexContainer container;
synchronized (dhtOutCache) {

Loading…
Cancel
Save