CLOUD: Delete the incomplete file (when downloading)

This commit is contained in:
Alexander Tkachev 2016-06-19 13:50:11 +06:00
parent 2d3cfffa84
commit 4c381dafa3
3 changed files with 23 additions and 1 deletions

View file

@ -118,4 +118,9 @@ void DownloadRequest::finishSuccess(bool success) {
if (_boolCallback) (*_boolCallback)(Storage::BoolResponse(this, success));
}
void DownloadRequest::finishError(Networking::ErrorResponse error) {
if (_localFile) _localFile->close();
Request::finishError(error);
}
} // End of namespace Cloud