Mercurial > hg > orthanc-dicomweb
changeset 349:8ea13bf99ff5
fix handling of bad frame index in retrieve rendered transaction
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 22 Aug 2019 18:50:32 +0200 |
parents | d4a535ebd88c |
children | 9222c93c0b5b |
files | Plugin/Plugin.cpp Plugin/WadoRs.cpp |
diffstat | 2 files changed, 13 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/Plugin/Plugin.cpp Thu Aug 22 13:53:40 2019 +0200 +++ b/Plugin/Plugin.cpp Thu Aug 22 18:50:32 2019 +0200 @@ -441,6 +441,15 @@ OrthancPluginAnswerBuffer(context, output, buffer.GetData(), buffer.GetSize(), Orthanc::EnumerationToString(mime)); } + else + { + throw Orthanc::OrthancException(Orthanc::ErrorCode_ParameterOutOfRange, + "Inexistent frame index in this image: " + boost::lexical_cast<std::string>(frame)); + } + } + else + { + throw Orthanc::OrthancException(Orthanc::ErrorCode_InexistentItem, "Inexistent instance"); } } }
--- a/Plugin/WadoRs.cpp Thu Aug 22 13:53:40 2019 +0200 +++ b/Plugin/WadoRs.cpp Thu Aug 22 18:50:32 2019 +0200 @@ -344,9 +344,10 @@ #if 0 // This is a FAST version, that does not access the filesystem. It // only uses the main DICOM tags as stored in the database, so - // less common tags will be missing. This is important if the - // DICOM/JSON files are stored on low-speed filesystem (e.g. AWS - // S3). TODO - Add a configuration option in the plugin + // less common tags will be missing (this is INCOMPATIBLE with Web + // Viewer 2). This is important if the DICOM/JSON files are stored + // on low-speed filesystem (e.g. AWS S3). TODO - Add a + // configuration option in the plugin const std::string bulkRoot = (wadoBase + "studies/" + studyInstanceUid + "/series/" + seriesInstanceUid +