# HG changeset patch # User Alain Mazy # Date 1783002856 -7200 # Node ID 58018d5883d119a24689bbdd61c290c7582659bf # Parent 534f52a5dba0a8dbec24b51bfd80272dd5dc1dab C-Find SCP: don't try to match on PrivateCreator tags diff -r 534f52a5dba0 -r 58018d5883d1 NEWS --- a/NEWS Wed Jul 01 17:21:37 2026 +0200 +++ b/NEWS Thu Jul 02 16:34:16 2026 +0200 @@ -19,10 +19,13 @@ - StoreKeyValue(storeId, key, value) - value = GetKeyValue(storeId, key) - DeleteKeyValue(storeId, key) -* C-Find SCP: When Orthanc was requested a sequence in a C-Find, Orthanc was actually not returning - any sequences in the C-Find answer if the matched resource did contain the requested sequence and - was returning an empty sequence if the matched resource did not contain the requested sequence. - Orthanc now returns the full sequence content when the matched resource contains the requested sequence. +* C-Find SCP: + - When Orthanc was requested a sequence in a C-Find query, Orthanc was actually not returning + any sequences in the C-Find answer if the matched resource did contain the requested sequence and + was returning an empty sequence if the matched resource did not contain the requested sequence. + Orthanc now returns the full sequence content when the matched resource contains the requested sequence. + - When Orthanc was requested to return a private tag in a C-Find query, Orthanc was actually not returning + the resources that did not contain the private tag although it was not used as a filter in the query. REST API diff -r 534f52a5dba0 -r 58018d5883d1 OrthancFramework/Sources/DicomFormat/DicomTag.cpp --- a/OrthancFramework/Sources/DicomFormat/DicomTag.cpp Wed Jul 01 17:21:37 2026 +0200 +++ b/OrthancFramework/Sources/DicomFormat/DicomTag.cpp Thu Jul 02 16:34:16 2026 +0200 @@ -77,6 +77,10 @@ return group_ % 2 == 1; } + bool DicomTag::IsPrivateCreator() const + { + return IsPrivate() && (element_ >= 0x0010 && element_ <= 0x00FF); + } bool DicomTag::operator< (const DicomTag& other) const { diff -r 534f52a5dba0 -r 58018d5883d1 OrthancFramework/Sources/DicomFormat/DicomTag.h --- a/OrthancFramework/Sources/DicomFormat/DicomTag.h Wed Jul 01 17:21:37 2026 +0200 +++ b/OrthancFramework/Sources/DicomFormat/DicomTag.h Thu Jul 02 16:34:16 2026 +0200 @@ -51,6 +51,8 @@ bool IsPrivate() const; + bool IsPrivateCreator() const; + bool operator< (const DicomTag& other) const; bool operator<= (const DicomTag& other) const; diff -r 534f52a5dba0 -r 58018d5883d1 OrthancServer/Sources/OrthancFindRequestHandler.cpp --- a/OrthancServer/Sources/OrthancFindRequestHandler.cpp Wed Jul 01 17:21:37 2026 +0200 +++ b/OrthancServer/Sources/OrthancFindRequestHandler.cpp Thu Jul 02 16:34:16 2026 +0200 @@ -408,6 +408,11 @@ continue; } + if (tag.IsPrivateCreator()) // new in 1.12.11+: don't try to match PrivateCreators themselves (they are not mandatory); match only the private tags + { + continue; + } + if (FilterQueryTag(level, tag, connection.GetModalityManufacturer())) { ValueRepresentation vr = FromDcmtkBridge::LookupValueRepresentation(tag); diff -r 534f52a5dba0 -r 58018d5883d1 OrthancServer/Sources/ResourceFinder.cpp --- a/OrthancServer/Sources/ResourceFinder.cpp Wed Jul 01 17:21:37 2026 +0200 +++ b/OrthancServer/Sources/ResourceFinder.cpp Thu Jul 02 16:34:16 2026 +0200 @@ -980,8 +980,6 @@ } else { - // TODO-FIND: This fallback shouldn't be necessary - FindRequest requestDicomAttachment(request.GetLevel()); requestDicomAttachment.SetOrthancId(request.GetLevel(), resource.GetIdentifier());