changeset 5076:25844bc0b2cb

fix signature of OrthancPluginSendHttpStatus() for the "body" argument
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 16 Aug 2022 16:09:59 +0200
parents a342e561c29d
children 6c0ed4a98bb0
files OrthancServer/Plugins/Engine/OrthancPlugins.cpp OrthancServer/Plugins/Include/orthanc/OrthancCPlugin.h
diffstat 2 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/OrthancServer/Plugins/Engine/OrthancPlugins.cpp	Tue Aug 16 12:46:46 2022 +0200
+++ b/OrthancServer/Plugins/Engine/OrthancPlugins.cpp	Tue Aug 16 16:09:59 2022 +0200
@@ -2979,7 +2979,7 @@
 
     if (p.bodySize > 0 && p.body != NULL)
     {
-      translatedOutput.SendStatus(status, p.body, p.bodySize);
+      translatedOutput.SendStatus(status, reinterpret_cast<const char*>(p.body), p.bodySize);
     }
     else
     {
--- a/OrthancServer/Plugins/Include/orthanc/OrthancCPlugin.h	Tue Aug 16 12:46:46 2022 +0200
+++ b/OrthancServer/Plugins/Include/orthanc/OrthancCPlugin.h	Tue Aug 16 16:09:59 2022 +0200
@@ -3830,7 +3830,7 @@
   {
     OrthancPluginRestOutput* output;
     uint16_t                 status;
-    const char*              body;
+    const void*              body;
     uint32_t                 bodySize;
   } _OrthancPluginSendHttpStatus;
 
@@ -3860,7 +3860,7 @@
     OrthancPluginContext*    context,
     OrthancPluginRestOutput* output,
     uint16_t                 status,
-    const char*              body,
+    const void*              body,
     uint32_t                 bodySize)
   {
     _OrthancPluginSendHttpStatus params;