- final BufferedInputStream in = new BufferedInputStream(
- new URL(globalPrefix + localPrefix
- + ".thumbnails/metadata_6.dat").openStream());
+ final StringBuffer urlStringBuffer = new StringBuffer();
+
+ urlStringBuffer.append(globalPrefix);
+ urlStringBuffer.append(UrlParamEncoder.encode(localPrefix));
+ urlStringBuffer.append(UrlParamEncoder.encode(requestPath));
+ if (!requestPath.equals("/"))
+ urlStringBuffer.append("/");
+ urlStringBuffer.append(".thumbnails/metadata_6.dat");
+
+ final String urlString = urlStringBuffer.toString();
+
+ final BufferedInputStream in = new BufferedInputStream(new URL(
+ urlString).openStream());