changeset 1868:c8877965d67d

More tolerant "/series/.../ordered-slices" with broken series
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 04 Dec 2015 16:18:46 +0100
parents 769178f0ab2c
children 9af3b492b010 e8146c9c28a4
files NEWS OrthancServer/SliceOrdering.cpp
diffstat 2 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/NEWS	Fri Dec 04 12:45:07 2015 +0100
+++ b/NEWS	Fri Dec 04 16:18:46 2015 +0100
@@ -2,6 +2,7 @@
 ===============================
 
 * Fix modality worklists server if some fields are null
+* More tolerant "/series/.../ordered-slices" with broken series
 
 
 Version 0.9.5 (2015/12/02)
--- a/OrthancServer/SliceOrdering.cpp	Fri Dec 04 12:45:07 2015 +0100
+++ b/OrthancServer/SliceOrdering.cpp	Fri Dec 04 16:18:46 2015 +0100
@@ -320,7 +320,8 @@
       if (instances_[i - 1]->GetIndexInSeries() == instances_[i]->GetIndexInSeries())
       {
         // The current "IndexInSeries" occurs 2 times: Not a proper ordering
-        return false;
+        LOG(WARNING) << "This series contains 2 slices with the same index, trying to display it anyway";
+        break;
       }
     }