Mercurial > hg > orthanc
changeset 3702:643b5ee86f92
fix handling of errors of OrthancPluginStorageRemove()
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 26 Feb 2020 14:36:42 +0100 |
parents | 5cbbf14e516b |
children | 2eeaa076c8f6 58f92b1c8061 |
files | OrthancServer/ServerIndex.cpp |
diffstat | 1 files changed, 9 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/OrthancServer/ServerIndex.cpp Wed Feb 26 13:21:41 2020 +0100 +++ b/OrthancServer/ServerIndex.cpp Wed Feb 26 14:36:42 2020 +0100 @@ -152,7 +152,15 @@ it = pendingFilesToRemove_.begin(); it != pendingFilesToRemove_.end(); ++it) { - context_.RemoveFile(it->GetUuid(), it->GetContentType()); + try + { + context_.RemoveFile(it->GetUuid(), it->GetContentType()); + } + catch (OrthancException& e) + { + LOG(ERROR) << "Unable to remove an attachment from the storage area: " + << it->GetUuid() << " (type: " << EnumerationToString(it->GetContentType()) << ")"; + } } }