# HG changeset patch # User Sebastien Jodogne # Date 1630959187 -7200 # Node ID b47ee86a0d109b189b4659b878638e78a6f40b64 # Parent 9a1f106e175c768983fb1a7e479e1e2968b118b4 support 64 bit integers in DICOMweb diff -r 9a1f106e175c -r b47ee86a0d10 OrthancFramework/Sources/DicomFormat/DicomMap.cpp --- a/OrthancFramework/Sources/DicomFormat/DicomMap.cpp Tue Aug 31 12:49:39 2021 +0200 +++ b/OrthancFramework/Sources/DicomFormat/DicomMap.cpp Mon Sep 06 22:13:07 2021 +0200 @@ -1406,11 +1406,11 @@ break; case Json::intValue: - s += boost::lexical_cast(value[j].asInt()); + s += boost::lexical_cast(value[j].asInt64()); break; case Json::uintValue: - s += boost::lexical_cast(value[j].asUInt()); + s += boost::lexical_cast(value[j].asUInt64()); break; case Json::realValue: diff -r 9a1f106e175c -r b47ee86a0d10 OrthancFramework/UnitTestsSources/FromDcmtkTests.cpp --- a/OrthancFramework/UnitTestsSources/FromDcmtkTests.cpp Tue Aug 31 12:49:39 2021 +0200 +++ b/OrthancFramework/UnitTestsSources/FromDcmtkTests.cpp Mon Sep 06 22:13:07 2021 +0200 @@ -3132,6 +3132,23 @@ } +TEST(DicomMap, DicomWebWithInteger64) +{ + /** + * This failed in Orthanc <= 1.9.7 with + * "http://localhost:8042/dicom-web/studies/1.3.6.1.4.1.14519.5.2.1.314316487728501506587013300243937537423/series/1.3.6.1.4.1.1459.5.2.1.62266640231940987006694557463549207147/instances/1.3.6.1.4.1.14519.5.2.1.147718809116229175846174241356499989705/metadata" + * of patient "GLIOMA01-i_03A6" from collection "ICDC-Glioma" of + * TCIA. + **/ + Json::Value v = Json::objectValue; + v["00191297"]["Value"][0] = 29362240; + v["00191297"]["Value"][1] = Json::Int64(4294948074l); + v["00191297"]["vr"] = "UL"; + DicomMap m; + m.FromDicomWeb(v); +} + + #if ORTHANC_ENABLE_DCMTK_TRANSCODING == 1