# HG changeset patch # User Sebastien Jodogne # Date 1487766725 -3600 # Node ID f915aff7a866bf81017138023dd872796a7847e7 # Parent a344e47e9c9acd106da2a9ad84d07b37f867bd16 fix diff -r a344e47e9c9a -r f915aff7a866 Plugins/Samples/Common/OrthancPluginCppWrapper.cpp --- a/Plugins/Samples/Common/OrthancPluginCppWrapper.cpp Tue Feb 14 16:03:18 2017 +0100 +++ b/Plugins/Samples/Common/OrthancPluginCppWrapper.cpp Wed Feb 22 13:32:05 2017 +0100 @@ -317,9 +317,10 @@ const std::string& password) { Clear(); - return CheckHttp(OrthancPluginHttpGet(context_, &buffer_, url.c_str(), - username.empty() ? NULL : username.c_str(), - password.empty() ? NULL : password.c_str())); + return CheckHttp(OrthancPluginHttpPost(context_, &buffer_, url.c_str(), + body.c_str(), body.size(), + username.empty() ? NULL : username.c_str(), + password.empty() ? NULL : password.c_str())); } @@ -1130,10 +1131,15 @@ unsigned int minor, unsigned int revision) { - char buf[128]; - sprintf(buf, "Your version of the Orthanc core (%s) is too old to run this plugin (%d.%d.%d is required)", - context->orthancVersion, major, minor, revision); - OrthancPluginLogError(context, buf); + std::string s = ("Your version of the Orthanc core (" + + std::string(context->orthancVersion) + + ") is too old to run this plugin (" + + boost::lexical_cast(major) + "." + + boost::lexical_cast(minor) + "." + + boost::lexical_cast(revision) + + " is required)"); + + OrthancPluginLogError(context, s.c_str()); }