Fix attempt to remove missing files.

This commit is contained in:
James Turner 2016-03-01 12:35:08 +00:00
parent b8d07cc460
commit 8009a33b26

View File

@ -631,7 +631,10 @@ HTTPRepository::failure() const
virtual void onFail() virtual void onFail()
{ {
file.reset(); file.reset();
if (pathInRepo.exists()) {
pathInRepo.remove(); pathInRepo.remove();
}
if (_directory) { if (_directory) {
_directory->didFailToUpdateFile(fileName, AbstractRepository::REPO_ERROR_SOCKET); _directory->didFailToUpdateFile(fileName, AbstractRepository::REPO_ERROR_SOCKET);
_directory->repository()->finishedRequest(this); _directory->repository()->finishedRequest(this);