Browse Source

Fix the issue where scp transfer completion tracking wasn't being triggered for 100% completion

This closes #91 pull request at github/apache/ant
master
wenjingwang Jaikiran Pai 6 years ago
parent
commit
e91c4dc223
4 changed files with 12 additions and 4 deletions
  1. +1
    -0
      CONTRIBUTORS
  2. +4
    -0
      WHATSNEW
  3. +4
    -0
      contributors.xml
  4. +3
    -4
      src/main/org/apache/tools/ant/taskdefs/optional/ssh/ScpFromMessage.java

+ 1
- 0
CONTRIBUTORS View File

@@ -441,6 +441,7 @@ Vladislav Bauer
Volker Leidl
Waldek Herka
Wang Weijun
Wenjing Wang
Will Wang
William Bernardet
William Ferguson


+ 4
- 0
WHATSNEW View File

@@ -56,6 +56,10 @@ Fixed bugs:
actual address could potentially be unreachable. This is now fixed
and the resolved address is actually checked for reachability.

* Fixes an issue where scp transfer completion tracking wasn't being
triggered for 100% completion.
Github Pull Request #91


Other changes:
--------------


+ 4
- 0
contributors.xml View File

@@ -1815,6 +1815,10 @@
<first>Wang</first>
<last>Weijun</last>
</name>
<name>
<first>Wenjing</first>
<last>Wang</last>
</name>
<name>
<first>Will</first>
<last>Wang</last>


+ 3
- 4
src/main/org/apache/tools/ant/taskdefs/optional/ssh/ScpFromMessage.java View File

@@ -286,15 +286,14 @@ public class ScpFromMessage extends AbstractSshMessage {
fos.write(buf, 0, length);
filesize -= length;
totalLength += length;
if (filesize == 0) {
break;
}

if (trackProgress) {
percentTransmitted = trackProgress(initFilesize,
totalLength,
percentTransmitted);
}
if (filesize == 0) {
break;
}
}
} finally {
final long endTime = System.currentTimeMillis();


Loading…
Cancel
Save