Skip to content

Commit

Permalink
Upload: Log the checksum / file hash
Browse files Browse the repository at this point in the history
  • Loading branch information
guruz committed Aug 4, 2017
1 parent 13a5653 commit 4aad318
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
4 changes: 1 addition & 3 deletions src/libsync/propagateuploadng.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -284,9 +284,9 @@ void PropagateUploadFileNG::startNextChunk()
headers["If"] = "<" + destination.toUtf8() + "> ([" + ifMatch + "])";
}
if (!_transmissionChecksumHeader.isEmpty()) {
qCInfo(lcPropagateUpload) << destination << _transmissionChecksumHeader;
headers[checkSumHeaderC] = _transmissionChecksumHeader;
}

headers["OC-Total-Length"] = QByteArray::number(fileSize);

auto job = new MoveJob(propagator()->account(), Utility::concatUrlPath(chunkUrl(), "/.file"),
Expand Down Expand Up @@ -333,8 +333,6 @@ void PropagateUploadFileNG::startNextChunk()
job->start();
propagator()->_activeJobList.append(this);
_currentChunk++;

// FIXME! parallel chunk?
}

void PropagateUploadFileNG::slotPutFinished()
Expand Down
1 change: 1 addition & 0 deletions src/libsync/propagateuploadv1.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ void PropagateUploadFileV1::startNextChunk()
qCDebug(lcPropagateUpload) << _chunkCount << isFinalChunk << chunkStart << currentChunkSize;

if (isFinalChunk && !_transmissionChecksumHeader.isEmpty()) {
qCInfo(lcPropagateUpload) << propagator()->_remoteFolder + path << _transmissionChecksumHeader;
headers[checkSumHeaderC] = _transmissionChecksumHeader;
}

Expand Down

0 comments on commit 4aad318

Please sign in to comment.