changeset 3895:37cf1889667a transcoding

more explicit error message
author Alain Mazy <alain@mazy.be>
date Thu, 07 May 2020 11:31:58 +0200
parents 09798f2b985f
children 210af28c4087
files Core/DicomParsing/FromDcmtkBridge.cpp
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/Core/DicomParsing/FromDcmtkBridge.cpp	Wed Apr 29 12:26:51 2020 +0200
+++ b/Core/DicomParsing/FromDcmtkBridge.cpp	Thu May 07 11:31:58 2020 +0200
@@ -1725,7 +1725,7 @@
         DcmTag key(tag.GetGroup(), tag.GetElement());
         if (key.getEVR() != EVR_SQ)
         {
-          throw OrthancException(ErrorCode_BadParameterType);
+          throw OrthancException(ErrorCode_BadParameterType, "Bad Parameter type for tag " + tag.Format());
         }
 
         DcmSequenceOfItems* sequence = new DcmSequenceOfItems(key);
@@ -1769,7 +1769,7 @@
       }
 
       default:
-        throw OrthancException(ErrorCode_BadParameterType);
+        throw OrthancException(ErrorCode_BadParameterType, "Bad Parameter type for tag " + tag.Format());
     }
 
     return element.release();