diff OrthancServer/DicomDirWriter.cpp @ 1893:d7f63122c7f3

cppcheck
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 15 Dec 2015 17:22:52 +0100
parents 5be57564ffc4
children b1291df2f780
line wrap: on
line diff
--- a/OrthancServer/DicomDirWriter.cpp	Mon Dec 14 10:10:50 2015 +0100
+++ b/OrthancServer/DicomDirWriter.cpp	Tue Dec 15 17:22:52 2015 +0100
@@ -159,10 +159,10 @@
                                 const DcmTagKey& key)
     {
       DcmElement* element = NULL;
-      char* s = NULL;
 
       if (source.findAndGetElement(key, element).good())
       {
+        char* s = NULL;
         if (element->isLeaf() &&
             element->getString(s).good() &&
             s != NULL)