]> Creatis software - gdcm.git/blobdiff - src/gdcmUtil.cxx
* Memory link hunt (by using valgrind --leak-check=yes PrintHeader).
[gdcm.git] / src / gdcmUtil.cxx
index 127737e1d95a7773f62577eccbae3f5f3ebea1c7..9b93e96cef69cb519e7e5e2fc4e24183faec1856 100644 (file)
@@ -3,6 +3,10 @@
 #include <ctype.h>   // For isspace
 #include "gdcmUtil.h"
 
+// Library globals.
+gdcmDebug dbg;
+gdcmVR * gdcmGlobal::VR = new gdcmVR();
+
 gdcmDebug::gdcmDebug(int level) {
        DebugLevel = level;
 }
@@ -43,8 +47,19 @@ void gdcmDebug::Exit(int a) {
 #endif
 }
 
-gdcmDebug dbg;
+///////////////////////////////////////////////////////////////////////////
+gdcmGlobal::gdcmGlobal(void) {
+}
+
+gdcmGlobal::~gdcmGlobal(void) {
+   delete VR;
+}
+
+gdcmVR * gdcmGlobal::GetVR(void) {
+   return VR;
+}
 
+///////////////////////////////////////////////////////////////////////////
 // Because is not yet available in g++2.96
 istream& eatwhite(istream& is) {
        char c;