Skip to content

Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance

Handle '?' and '+' chars as valid wild cards when adding to blacklist.

luccioman58d23047ddeb
diff --git a/source/net/yacy/repository/BlacklistHelper.java b/source/net/yacy/repository/BlacklistHelper.java
index 976088e02..dd57a1ee8 100644
--- a/source/net/yacy/repository/BlacklistHelper.java
+++ b/source/net/yacy/repository/BlacklistHelper.java
@@ -1,7 +1,6 @@
package net.yacy.repository;
import net.yacy.cora.document.id.Punycode.PunycodeException;
-import net.yacy.cora.protocol.HeaderFramework;
import net.yacy.cora.protocol.RequestHeader;
import net.yacy.cora.util.ConcurrentLog;
import net.yacy.data.ListManager;
@@ -53,7 +52,7 @@ public final class BlacklistHelper {
newEntry = newEntry.substring(8);
}
- if (newEntry.indexOf("*") < 0) {
+ if (newEntry.indexOf("*") < 0 && newEntry.indexOf("?") < 0 && newEntry.indexOf("+") < 0) {
// user did not use any wild cards and just submitted a word
newEntry = ".*" + newEntry + ".*/.*";