hack ConfigImplUtil.urlToFile to make "file://whatever" with two slashes work

This compounds the wrongness of that method.
This commit is contained in:
Havoc Pennington 2012-04-09 11:41:11 -04:00
parent 3b7d99a797
commit 386613909b

View File

@ -150,6 +150,10 @@ final public class ConfigImplUtil {
// this handles some stuff like file:///c:/Whatever/
// apparently but mangles handling of hex escapes
return new File(url.getPath());
} catch (IllegalArgumentException e) {
// file://foo with double slash causes
// IllegalArgumentException "url has an authority component"
return new File(url.getPath());
}
}