changeset 7196:6331d240a7fc default tip

Make Orthanc more resilient on SpecificCharacterSet typo errors
author Alain Mazy <am@orthanc.team>
date Wed, 04 Nov 2026 16:04:49 +0100
parents abb0321e1aeb
children
files NEWS OrthancFramework/Sources/Enumerations.cpp
diffstat 2 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/NEWS	Wed Nov 04 15:39:25 2026 +0100
+++ b/NEWS	Wed Nov 04 16:04:49 2026 +0100
@@ -47,6 +47,7 @@
   (https://discourse.orthanc-server.org/t/1-13-0-orthancpluginloaddicominstance-reads-the-whole-dicom-file-in-emptypixeldata-and-untilpixeldata-modes/6489)
 * Fix uncompressed size in Prometheus metrics
   (https://discourse.orthanc-server.org/t/fixing-prometheus-metrics-contribution/6490)
+* Make Orthanc more resilient on SpecificCharacterSet typo errors ('ISO-IR' vs 'ISO IR' vs 'ISO_IR' that is the valid prefix)
 * Fix use of the static runtime under Visual Studio (/MT), which broke in 1.12.10
 * New CMake options: 
   - "THIRD_PARTY_DOWNLOADS_ROOT_URL" to specify another webserver to downloads the third-parties from.
--- a/OrthancFramework/Sources/Enumerations.cpp	Wed Nov 04 15:39:25 2026 +0100
+++ b/OrthancFramework/Sources/Enumerations.cpp	Wed Nov 04 16:04:49 2026 +0100
@@ -2018,6 +2018,8 @@
     Toolbox::ToUpperCase(s);
 
     // handle common spelling mistakes
+    boost::replace_all(s, "ISO-IR ", "ISO_IR ");
+    boost::replace_all(s, "ISO IR ", "ISO_IR ");
     boost::replace_all(s, "ISO_IR_", "ISO_IR ");
     boost::replace_all(s, "ISO_2022_IR_", "ISO 2022 IR ");