]> Creatis software - gdcm.git/commitdiff
misplaced return 0.; for ACR/NEMA
authormalaterre <malaterre>
Mon, 28 Jul 2003 12:21:09 +0000 (12:21 +0000)
committermalaterre <malaterre>
Mon, 28 Jul 2003 12:21:09 +0000 (12:21 +0000)
src/gdcmHeader.cxx

index 46838845b37f94b6e4f2f4616a5f61494b635d4b..d09ff768c75f84b974f083cf835927479ddb78dc 100644 (file)
@@ -1,5 +1,5 @@
 
-// $Header: /cvs/public/gdcm/src/Attic/gdcmHeader.cxx,v 1.79 2003/07/23 08:43:03 jpr Exp $
+// $Header: /cvs/public/gdcm/src/Attic/gdcmHeader.cxx,v 1.80 2003/07/28 12:21:09 malaterre Exp $
 
 #include <stdio.h>
 #include <cerrno>
@@ -2075,8 +2075,8 @@ float gdcmHeader::GetXImagePosition(void) {
        if (StrImPos == "gdcm::Unfound") {
           dbg.Verbose(0, "gdcmHeader::GetXImagePosition: unfound Image Position (RET) (0020,0030)");
           // How to tell the caller nothing was found ?
+          return 0.;
        }  
-       return 0.;
      }
    if( sscanf( StrImPos.c_str(), "%f\\%f\\%f", &xImPos, &yImPos, &zImPos) != 3)
      return 0.;
@@ -2099,8 +2099,9 @@ float gdcmHeader::GetYImagePosition(void) {
        StrImPos = GetPubElValByNumber(0x0020,0x0030); // For ACR-NEMA images
        if (StrImPos == "gdcm::Unfound") {
           dbg.Verbose(0, "gdcmHeader::GetYImagePosition: unfound Image Position (RET) (0020,0030)");
+          // How to tell the caller nothing was found ?
+          return 0.;
        }  
-       return 0.;
      }
    if( sscanf( StrImPos.c_str(), "%f\\%f\\%f", &xImPos, &yImPos, &zImPos) != 3)
      return 0.;