Description: Fixes for 64bit compilations with jsoncpp-0.6.0
Author: Sebastien Jodogne <s.jodogne@gmail.com>
Origin: upstream
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
Index: Orthanc-0.6.0/OrthancCppClient/OrthancConnection.cpp
===================================================================
--- Orthanc-0.6.0.orig/OrthancCppClient/OrthancConnection.cpp	2013-07-16 15:13:36.000000000 +0200
+++ Orthanc-0.6.0/OrthancCppClient/OrthancConnection.cpp	2013-07-17 11:57:11.765723817 +0200
@@ -48,7 +48,8 @@
 
   Orthanc::IDynamicObject* OrthancConnection::GetFillerItem(size_t index)
   {
-    return new Patient(*this, content_[index].asString());
+    Json::Value::ArrayIndex tmp = static_cast<Json::Value::ArrayIndex>(index);
+    return new Patient(*this, content_[tmp].asString());
   }
 
   Patient& OrthancConnection::GetPatient(unsigned int index)
Index: Orthanc-0.6.0/OrthancCppClient/Patient.cpp
===================================================================
--- Orthanc-0.6.0.orig/OrthancCppClient/Patient.cpp	2013-07-16 15:13:36.000000000 +0200
+++ Orthanc-0.6.0/OrthancCppClient/Patient.cpp	2013-07-17 11:57:11.765723817 +0200
@@ -50,7 +50,8 @@
 
   Orthanc::IDynamicObject* Patient::GetFillerItem(size_t index)
   {
-    return new Study(connection_, patient_["Studies"][index].asString());
+    Json::Value::ArrayIndex tmp = static_cast<Json::Value::ArrayIndex>(index);
+    return new Study(connection_, patient_["Studies"][tmp].asString());
   }
 
   Patient::Patient(const OrthancConnection& connection,
Index: Orthanc-0.6.0/OrthancCppClient/Series.cpp
===================================================================
--- Orthanc-0.6.0.orig/OrthancCppClient/Series.cpp	2013-07-16 15:13:36.000000000 +0200
+++ Orthanc-0.6.0/OrthancCppClient/Series.cpp	2013-07-17 11:57:11.765723817 +0200
@@ -215,7 +215,8 @@
 
   Orthanc::IDynamicObject* Series::GetFillerItem(size_t index)
   {
-    return new Instance(connection_, series_["Instances"][index].asString());
+    Json::Value::ArrayIndex tmp = static_cast<Json::Value::ArrayIndex>(index);
+    return new Instance(connection_, series_["Instances"][tmp].asString());
   }
 
   Series::Series(const OrthancConnection& connection,
Index: Orthanc-0.6.0/OrthancCppClient/Study.cpp
===================================================================
--- Orthanc-0.6.0.orig/OrthancCppClient/Study.cpp	2013-07-16 15:13:36.000000000 +0200
+++ Orthanc-0.6.0/OrthancCppClient/Study.cpp	2013-07-17 11:57:11.765723817 +0200
@@ -50,7 +50,8 @@
 
   Orthanc::IDynamicObject* Study::GetFillerItem(size_t index)
   {
-    return new Series(connection_, study_["Series"][index].asString());
+    Json::Value::ArrayIndex tmp = static_cast<Json::Value::ArrayIndex>(index);
+    return new Series(connection_, study_["Series"][tmp].asString());
   }
 
   Study::Study(const OrthancConnection& connection,
