From: jpr Date: Thu, 30 Mar 2006 17:29:00 +0000 (+0000) Subject: Avoid stupid messages when length = 0 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=60ac87ad1e0f2a7875e742b88672f61c40dc02fb;p=gdcm.git Avoid stupid messages when length = 0 --- diff --git a/src/gdcmDataEntry.cxx b/src/gdcmDataEntry.cxx index c5be15df..995aeb2c 100644 --- a/src/gdcmDataEntry.cxx +++ b/src/gdcmDataEntry.cxx @@ -3,8 +3,8 @@ Program: gdcm Module: $RCSfile: gdcmDataEntry.cxx,v $ Language: C++ - Date: $Date: 2006/03/13 14:44:07 $ - Version: $Revision: 1.33 $ + Date: $Date: 2006/03/30 17:29:00 $ + Version: $Revision: 1.34 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -174,8 +174,11 @@ double DataEntry::GetValue(const uint32_t &id) const { if( !BinArea ) { + if (GetLength() != 0) // avoid stupid messages /// \todo warn the user there was a problem ! - gdcmErrorMacro("BinArea not set" << std::hex << GetGroup() << " " << GetElement() << " Can't get the value"); + gdcmErrorMacro("BinArea not set " << std::hex + : << GetGroup() << " " << GetElement() + << " Can't get the value"); return 0.0; }