changeset 1147:ae9a83a6fa47

simplification
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 11 Sep 2014 14:15:30 +0200
parents 200fcac0deb4
children ac36589f699e
files OrthancServer/FromDcmtkBridge.cpp
diffstat 1 files changed, 8 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/OrthancServer/FromDcmtkBridge.cpp	Thu Sep 11 14:04:48 2014 +0200
+++ b/OrthancServer/FromDcmtkBridge.cpp	Thu Sep 11 14:15:30 2014 +0200
@@ -326,11 +326,16 @@
 
         case EVR_AT:
         {
-          OFString s;
-          if (dynamic_cast<DcmAttributeTag&>(element).getOFString(s, 0).good())
-            return new DicomString(s.c_str());
+          DcmTagKey tag;
+          if (dynamic_cast<DcmAttributeTag&>(element).getTagVal(tag, 0).good())
+          {
+            DicomTag t(tag.getGroup(), tag.getElement());
+            return new DicomString(t.Format());
+          }
           else
+          {
             return new DicomNullValue;
+          }
         }