From 66424afb747dfc91511f216ed4190e527e3e7e87 Mon Sep 17 00:00:00 2001 From: neurolabusc Date: Tue, 28 Mar 2023 07:10:15 -0400 Subject: [PATCH] Completely ignore empty tags (https://github.com/rordenlab/dcm2niix/issues/695) --- console/nii_dicom.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/console/nii_dicom.cpp b/console/nii_dicom.cpp index 875e1fce..098b7a1d 100644 --- a/console/nii_dicom.cpp +++ b/console/nii_dicom.cpp @@ -5171,6 +5171,7 @@ const uint32_t kEffectiveTE = 0x0018 + uint32_t(0x9082 << 16); //FD // d.isValid = false; //return d; } + if (lLength > 0) //issue694: skip empty tags, "gdcmanon --dumb --empty 0018,0089 good.dcm bad.dcm" switch (groupElement) { case kMediaStorageSOPClassUID: { char mediaUID[kDICOMStr];