comparison Plugins/Samples/Common/OrthancPluginCppWrapper.h @ 2961:3ed449d0204d

fix
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 04 Dec 2018 18:58:45 +0100
parents 7364415851ac
children e361df74639f
comparison
equal deleted inserted replaced
2960:74a5a7fd6e0e 2961:3ed449d0204d
497 { 497 {
498 #if HAS_ORTHANC_EXCEPTION == 1 && HAS_ORTHANC_PLUGIN_EXCEPTION_DETAILS == 1 498 #if HAS_ORTHANC_EXCEPTION == 1 && HAS_ORTHANC_PLUGIN_EXCEPTION_DETAILS == 1
499 if (HasGlobalContext() && 499 if (HasGlobalContext() &&
500 e.HasDetails()) 500 e.HasDetails())
501 { 501 {
502 OrthancPluginSetHttpErrorDetails(GetGlobalContext(), output, e.GetDetails()); 502 // The "false" instructs Orthanc not to log the detailed
503 // error message. This is to avoid duplicating the details,
504 // because "OrthancException" already does it on construction.
505 OrthancPluginSetHttpErrorDetails
506 (GetGlobalContext(), output, e.GetDetails(), false);
503 } 507 }
504 #endif 508 #endif
505 509
506 return static_cast<OrthancPluginErrorCode>(e.GetErrorCode()); 510 return static_cast<OrthancPluginErrorCode>(e.GetErrorCode());
507 } 511 }