mirror of
https://github.com/apache/jclouds.git
synced 2025-02-08 19:15:24 +00:00
JCLOUDS-629: SshjSshClient Payload without length
sshj treats -1 as an unknown length and uses a less efficient copying mechanism.
This commit is contained in:
parent
a8b106c2bb
commit
086fb9c728
@ -318,7 +318,8 @@ public class SshjSshClient implements SshClient {
|
||||
|
||||
@Override
|
||||
public long getLength() {
|
||||
return contents.getContentMetadata().getContentLength();
|
||||
Long length = contents.getContentMetadata().getContentLength();
|
||||
return length != null ? length : -1;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
x
Reference in New Issue
Block a user