mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 14:54:52 +02:00
8231790: Provide better FileSystemProviders
Reviewed-by: alanb, skoivu, rhalade
This commit is contained in:
parent
be35f9ef53
commit
68c5b95b13
1 changed files with 2 additions and 0 deletions
|
@ -3348,6 +3348,8 @@ public final class Files {
|
|||
Objects.requireNonNull(cs);
|
||||
|
||||
byte[] ba = readAllBytes(path);
|
||||
if (path.getClass().getModule() != Object.class.getModule())
|
||||
ba = ba.clone();
|
||||
return JLA.newStringNoRepl(ba, cs);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue