Mercurial > hg > orthanc
changeset 3441:6cc72ebfd6ef
Fix issue #141 (/tools/create-dicom removes non-ASCII characters from study description)
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 24 Jun 2019 12:37:52 +0200 |
parents | 77702c19a2fa |
children | dd1e68f2d0c0 |
files | NEWS OrthancServer/OrthancRestApi/OrthancRestAnonymizeModify.cpp |
diffstat | 2 files changed, 3 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/NEWS Fri Jun 21 18:28:11 2019 +0200 +++ b/NEWS Mon Jun 24 12:37:52 2019 +0200 @@ -30,6 +30,7 @@ * Fix issue #136 (C-FIND request fails when found DICOM file does not have certain tags) * Fix issue #137 (C-STORE fails for unknown SOP Class although server is configured to accept any) * Fix issue #138 (POST to modalities/{name} accepts invalid characters) +* Fix issue #141 (/tools/create-dicom removes non-ASCII characters from study description) Version 1.5.6 (2019-03-01)
--- a/OrthancServer/OrthancRestApi/OrthancRestAnonymizeModify.cpp Fri Jun 21 18:28:11 2019 +0200 +++ b/OrthancServer/OrthancRestApi/OrthancRestAnonymizeModify.cpp Mon Jun 24 12:37:52 2019 +0200 @@ -518,11 +518,8 @@ } else if (tag["Type"] == "String") { - std::string value = tag["Value"].asString(); - - bool hasCodeExtensions; - Encoding encoding = dicom.DetectEncoding(hasCodeExtensions); - dicom.ReplacePlainString(*it, Toolbox::ConvertFromUtf8(value, encoding)); + std::string value = tag["Value"].asString(); // This is an UTF-8 value (as it comes from JSON) + dicom.ReplacePlainString(*it, value); } } }