Upload: Log the checksum / file hash

This commit is contained in:
Markus Goetz 2017-08-04 15:42:11 +02:00
parent 13a5653c4e
commit 4aad318446
2 changed files with 2 additions and 3 deletions

View file

@ -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"),
@ -333,8 +333,6 @@ void PropagateUploadFileNG::startNextChunk()
job->start();
propagator()->_activeJobList.append(this);
_currentChunk++;
// FIXME! parallel chunk?
}
void PropagateUploadFileNG::slotPutFinished()

View file

@ -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;
}