Skip to content

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

*) Bugfix: supportedFileExt Function didn't chop http parameters before trying to detect the file extension

theli2b3f964037fa
diff --git a/source/de/anomic/plasma/plasmaParser.java b/source/de/anomic/plasma/plasmaParser.java
index 55314f7ad..650c75b37 100644
--- a/source/de/anomic/plasma/plasmaParser.java
+++ b/source/de/anomic/plasma/plasmaParser.java
@@ -271,7 +271,12 @@ public final class plasmaParser {
public static boolean supportedFileExt(URL url) {
String name = url.getFile();
- int p = name.lastIndexOf('.');
+ int p = name.lastIndexOf('?');
+ if (p != -1) {
+ name = name.substring(0,p);
+ }
+
+ p = name.lastIndexOf('.');
if (p < 0) return true; // seams to be strange, but this is a directory entry or default file (html)
return supportedFileExtContains(name.substring(p + 1));
}