diff OrthancStone/Sources/Loaders/DicomSource.cpp @ 1737:ef2f56c0311c

remove calls to deprecated classes of JsonCpp
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 22 Dec 2020 09:16:42 +0100
parents c8d0ffb3047d
children 9ac2a65d4172
line wrap: on
line diff
--- a/OrthancStone/Sources/Loaders/DicomSource.cpp	Tue Dec 22 09:06:33 2020 +0100
+++ b/OrthancStone/Sources/Loaders/DicomSource.cpp	Tue Dec 22 09:16:42 2020 +0100
@@ -26,6 +26,7 @@
 #include "../Oracle/OrthancRestApiCommand.h"
 
 #include <OrthancException.h>
+#include <Toolbox.h>
 
 #include <boost/algorithm/string/predicate.hpp>
 
@@ -268,9 +269,8 @@
     }
 
     Json::Value a, b;
-    Json::Reader reader;
-    if (reader.parse(system, a) &&
-        reader.parse(plugins, b) &&
+    if (Orthanc::Toolbox::ReadJson(a, system) &&
+        Orthanc::Toolbox::ReadJson(b, plugins) &&
         a.type() == Json::objectValue &&
         b.type() == Json::arrayValue &&
         a.isMember(REST_API_VERSION) &&