mirror of
https://github.com/openjdk/jdk.git
synced 2026-01-28 03:58:21 +00:00
8365700: Jar --validate without any --file option leaves around a temporary file /tmp/tmpJar<number>.jar
Reviewed-by: jpai, asteiner
This commit is contained in:
parent
b453eb63c6
commit
320235ccb8
@ -420,7 +420,8 @@ public class Main {
|
||||
if (fname != null) {
|
||||
file = new File(fname);
|
||||
} else {
|
||||
file = createTemporaryFile("tmpJar", ".jar");
|
||||
tmpFile = createTemporaryFile("tmpJar", ".jar");
|
||||
file = tmpFile;
|
||||
try (InputStream in = new FileInputStream(FileDescriptor.in);
|
||||
OutputStream os = Files.newOutputStream(file.toPath())) {
|
||||
in.transferTo(os);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user