Skip to content

Commit 6941248

Browse files
authored
Merge pull request #13014 from jloutsch/fix/download-resume-corruption
Fix download resume corruption when server returns HTTP 200
2 parents e61bc01 + 08008ca commit 6941248

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

app/src/main/java/us/shandian/giga/get/DownloadRunnableFallback.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ public void run() {
8585
if (mMission.unknownLength || mConn.getResponseCode() == 200) {
8686
// restart amount of bytes downloaded
8787
mMission.done = mMission.offsets[mMission.current] - mMission.offsets[0];
88+
start = 0; // reset position to avoid writing at wrong offset
8889
}
8990

9091
mF = mMission.storage.getStream();

0 commit comments

Comments
 (0)