Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
[JENKINS-38814] Use GREEDY `RemoteInputStream`s (#2583)
(cherry picked from commit b62ad15)
- Loading branch information
Showing
with
2 additions
and
2 deletions.
-
+2
−2
core/src/main/java/hudson/FilePath.java
|
@@ -555,7 +555,7 @@ public Void invoke(File dir, VirtualChannel channel) throws IOException, Interru |
|
|
* @see #unzip(FilePath) |
|
|
*/ |
|
|
public void unzipFrom(InputStream _in) throws IOException, InterruptedException { |
|
|
final InputStream in = new RemoteInputStream(_in); |
|
|
final InputStream in = new RemoteInputStream(_in, Flag.GREEDY); |
|
|
act(new SecureFileCallable<Void>() { |
|
|
public Void invoke(File dir, VirtualChannel channel) throws IOException { |
|
|
unzip(dir, in); |
|
@@ -724,7 +724,7 @@ public OutputStream compress(OutputStream out) throws IOException { |
|
|
*/ |
|
|
public void untarFrom(InputStream _in, final TarCompression compression) throws IOException, InterruptedException { |
|
|
try { |
|
|
final InputStream in = new RemoteInputStream(_in); |
|
|
final InputStream in = new RemoteInputStream(_in, Flag.GREEDY); |
|
|
act(new SecureFileCallable<Void>() { |
|
|
public Void invoke(File dir, VirtualChannel channel) throws IOException { |
|
|
readFromTar("input stream",dir, compression.extract(in)); |
|
|