Search found 147 matches

by Shaeto
Fri, 2024-02-16, 10:59
Forum: DCMTK - General
Topic: 32 bit unsigned overflow in dcmjpeg/libsrc/djcodecd.cc
Replies: 2
Views: 104

Re: 32 bit unsigned overflow in dcmjpeg/libsrc/djcodecd.cc

Thank you! will try to cherry-pick this fix to 3.6.8
by Shaeto
Thu, 2024-02-15, 13:59
Forum: DCMTK - General
Topic: 32 bit unsigned overflow in dcmjpeg/libsrc/djcodecd.cc
Replies: 2
Views: 104

32 bit unsigned overflow in dcmjpeg/libsrc/djcodecd.cc

dcmtk 3.6.7/3.6.8 file dcmjpeg/libsrc/djcodecd.cc line 169: result = uncompressedPixelData.createUint16Array(OFstatic_cast(Uint32, totalSize / sizeof(Uint16)), imageData16); if (result.good()) { .... } in my example i have dicom containing 9825 8bit jpeg frames 1024x1024 frameSize=1048576 totalSize=...
by Shaeto
Tue, 2023-10-03, 13:41
Forum: DCMTK - General
Topic: possible memory leak in dulfsm
Replies: 1
Views: 2166

possible memory leak in dulfsm

in dulfsm.cc a lot of network functions ending like this: if (cond.good()) { do { nbytes = (*association)->connection ? (*association)->connection->write((char*)b, size_t(pdu.length + 6)) : 0; } while (nbytes == -1 && OFStandard::getLastNetworkErrorCode().value() == DCMNET_EINTR); if ((unsig...
by Shaeto
Thu, 2021-10-07, 19:09
Forum: DCMTK - General
Topic: question about dcpath.cc and EVR_metainfo
Replies: 1
Views: 1642

question about dcpath.cc and EVR_metainfo

is some serios reason why DcmPath and DcmPathProcessor are work only with EVR_item and EVR_dataset but not with EVR_metainfo ? or is it just a historical omission ?
by Shaeto
Mon, 2021-09-06, 13:16
Forum: DCMTK - General
Topic: memory leak in DcmElement::getPartialValue
Replies: 1
Views: 1915

memory leak in DcmElement::getPartialValue

getPartialValue does not destroy readStream if stream status is not okay after creation // initialize the cache with new stream if (!readStream) { readStream = fLoadValue->create(); // check that read stream is non-NULL if (readStream == NULL) return EC_InvalidStream; // check that stream status is ...
by Shaeto
Wed, 2021-08-04, 15:01
Forum: DCMTK - General
Topic: OFSemaphore::wait(time)
Replies: 1
Views: 1619

Re: OFSemaphore::wait(time)

update: glibc 2.30+ provides pthread_cond_clockwait и sem_clockwait, imho it will be very interesting to see these functions in ofthread.cc (if available)
by Shaeto
Tue, 2021-08-03, 21:23
Forum: DCMTK - General
Topic: OFSemaphore::wait(time)
Replies: 1
Views: 1619

OFSemaphore::wait(time)

just fyi: this function uses posix sem_timedwait which is based on CLOCK_REALTIME, so, if between clock_gettime and sem_timedwait system time is will be changed sem_timedwait have a chance to work indefinitely... i am not sure what changed in latest RH8/CO8 patches but now this chance is much bigger...
by Shaeto
Fri, 2021-04-02, 13:38
Forum: DCMTK - General
Topic: dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT
Replies: 10
Views: 3626

Re: dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT

Okay thank you i will modify our fork,

last question is -Wall for cxx flags in cmake configuration
by Shaeto
Fri, 2021-04-02, 13:05
Forum: DCMTK - General
Topic: dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT
Replies: 10
Views: 3626

Re: dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT

yes i use a fork of master but seems it is modified to support jpeg-2000 classes in dcmimgle/include/dcmtk/dcmimgle/diutils.h we added const SP_Interpretation PhotometricInterpretationNames[] = ..... {"YBRICT", "YBR_ICT", EPI_YBR_ICT}, {"YBRRCT", "YBR_RCT", EP...
by Shaeto
Fri, 2021-04-02, 10:57
Forum: DCMTK - General
Topic: dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT
Replies: 10
Views: 3626

Re: dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT

YBR_RCT, YBR_ICT and YBR_PARTIAL_420 make no sense for uncompressed images. agree! but can't change this world - wrong dicom is came Anyway, where does the crash happen? it crashed in dcmdata/libsrc/dcpixel.cc:1195 1195 return (*current)->pixSeq->loadAllDataIntoMemory(); pixSeq is null (because of ...
by Shaeto
Fri, 2021-04-02, 09:25
Forum: DCMTK - General
Topic: dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT
Replies: 10
Views: 3626

Re: dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT

i tested this case using master I understand what YBR_RCT​ and YBR_ICT are only allowed for compressed images but it seems not all developers understand it also, so, our equipment sometime receives such dicoms from some "client tele-medical environment" it seems CMAKE_CXX_FLAGS is lack of ...
by Shaeto
Thu, 2021-04-01, 20:53
Forum: DCMTK - General
Topic: dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT
Replies: 10
Views: 3626

dcmjpeg encoder crashes on EPI_YBR_RCT and EPI_YBR_ICT

switch (photometricInterpretation) in dcmjpeg/libsrc/djcodece.cc: DJCodecEncoder::encode does not catch EPI_YBR_RCT and EPI_YBR_ICT and there is no default:, so, it produces wrong Pixel Representation context with NULL pixel sequence how to reproduce : get or create 8 bits image dicom having (0028,0...
by Shaeto
Thu, 2021-01-28, 10:34
Forum: DCMTK - General
Topic: bug in DcmFileFormat::writeJson
Replies: 2
Views: 1474

bug in DcmFileFormat::writeJson

version 3.6.6 (and master) method DcmFileFormat::writeJson does not print "," between meta and main dataset i used simplest fix (didn't want to use stringstream) if (dset && status.good()) { if (metinf && metinf->card()) out << ","; status = dset->writeJsonExt(out...
by Shaeto
Thu, 2020-08-06, 14:29
Forum: DCMTK - General
Topic: Bug in DcmPersonName::writeJson
Replies: 4
Views: 2264

Re: Bug in DcmPersonName::writeJson

Yes i meant the native model (dcm2xml -nat)
by Shaeto
Thu, 2020-08-06, 11:23
Forum: DCMTK - General
Topic: Bug in DcmPersonName::writeJson
Replies: 4
Views: 2264

Re: Bug in DcmPersonName::writeJson

Thank you Michael,

I see the same problem in DcmPersonName::writeXML method, the writer does not encode components of the patient name