]> Creatis software - gdcm.git/blobdiff - src/gdcmDicomDirObject.cxx
To avoid C / C++ style warnings
[gdcm.git] / src / gdcmDicomDirObject.cxx
index e53002695e95d7ada673d7a48a5d0cdaa6d6e435..1625584cb2670c6542cd653c781ead5035d3137b 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmDicomDirObject.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/10/18 08:35:49 $
-  Version:   $Revision: 1.21 $
+  Date:      $Date: 2005/10/25 09:22:15 $
+  Version:   $Revision: 1.23 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -67,13 +67,14 @@ void DicomDirObject::FillObject(ListDicomDirMetaElem const &elemList)
       tmpGr = it->Group;
       tmpEl = it->Elem;
       dictEntry = Global::GetDicts()->GetDefaultPubDict()->GetEntry(tmpGr,tmpEl);
-      entry = new DataEntry(dictEntry);
+      entry = DataEntry::New(dictEntry);
       entry->SetOffset(0); // just to avoid further missprinting
       entry->SetString(it->Value);
 
       AddEntry(entry);
-   }   
-}  
+      entry->Delete();
+   } 
+} 
 
 //-----------------------------------------------------------------------------
 // Private