]> Creatis software - gdcm.git/commitdiff
minor modif to gdcmHeaderEntry::Print()
authorjpr <jpr>
Fri, 23 Apr 2004 10:02:48 +0000 (10:02 +0000)
committerjpr <jpr>
Fri, 23 Apr 2004 10:02:48 +0000 (10:02 +0000)
src/gdcmHeaderEntry.cxx

index eda099ce8d65f185eac674ac5ef04a574ad6c93a..cdb3522e988b27557296cdc71f00b173bffbbff9 100644 (file)
@@ -123,11 +123,12 @@ void gdcmHeaderEntry::Print(std::ostream & os) {
    if ( (vr == "UL") || (vr == "US") || (vr == "SL") || (vr == "SS") ) {
       if (v == "4294967295") // to avoid troubles in convertion 
          sprintf (st," x(ffffffff)");
-      else
-                               {
-         //sprintf(st," x(%x)",(unsigned long)atof(v.c_str()));
-         sprintf(st," x(%x)", atoi(v.c_str()));//FIXME
-                                }
+      else {
+         if ( GetLength() !=0 )        
+            sprintf(st," x(%x)", atoi(v.c_str()));//FIXME
+        else
+         sprintf(st," "); 
+      }
       s << st;
    }
    s << std::endl;