[Gdcm-hackers] [ gdcm-Bugs-2900596 ] bug in debug reading code
Cross-platform DICOM implementation
Brought to you by:
malat
|
From: SourceForge.net <no...@so...> - 2011-01-25 15:47:24
|
Bugs item #2900596, was opened at 2009-11-19 18:15 Message generated for change (Settings changed) made by malat You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=739587&aid=2900596&group_id=137895 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: General (default) Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Mathieu Malaterre (malat) >Assigned to: Mark Roden (mmroden) Summary: bug in debug reading code Initial Comment: Hi Mathieu, There's a small bug in the image reading code example in itk. The bug happens in debug mode; if there is a non-dcm image in the directory, then the following asserts break: //line 205, gdcmAttribute.h void SetFromDataElement(DataElement const &de) { // This is kind of hackish but since I do not generate other element than the first one: 0x6000 I should be ok: assert( GetTag() == de.GetTag() || GetTag().GetGroup() == 0x6000 || GetTag().GetGroup() == 0x5000 ); Basically, there is no data in the dataelement, because the element itself is null, because it's not a dcm file. This code works perfectly well in release mode, because the asserts aren't hit. I'm not sure if the fix should be to rewrite the asserts or to prevent the reading code from getting into this spot in the first place. I can send you more of my code if you'd like. Thanks, Mark ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=739587&aid=2900596&group_id=137895 |