mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
8242186: Reduce allocations in URLStreamHandler.parseURL for some cases
Reviewed-by: redestad, chegar
This commit is contained in:
parent
722a18d31e
commit
e9adf7bbe1
1 changed files with 2 additions and 2 deletions
|
@ -266,8 +266,8 @@ public abstract class URLStreamHandler {
|
|||
spec.substring(start, limit);
|
||||
|
||||
} else {
|
||||
String separator = (authority != null) ? "/" : "";
|
||||
path = separator + spec.substring(start, limit);
|
||||
path = spec.substring(start, limit);
|
||||
path = (authority != null) ? "/" + path : path;
|
||||
}
|
||||
} else if (queryOnly && path != null) {
|
||||
int ind = path.lastIndexOf('/');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue