# HG changeset patch # User Alain Mazy # Date 1585728889 -7200 # Node ID c38b82bb6fd3e720f6dd6e4e617fcde723b505c1 # Parent 6cd4b7724c3d59ff54228db50f323810a6a46a67 improved error message when trying to C-Move a resource that is not found diff -r 6cd4b7724c3d -r c38b82bb6fd3 Core/DicomNetworking/DicomUserConnection.cpp --- a/Core/DicomNetworking/DicomUserConnection.cpp Tue Mar 10 09:49:18 2020 +0100 +++ b/Core/DicomNetworking/DicomUserConnection.cpp Wed Apr 01 10:14:49 2020 +0200 @@ -887,9 +887,22 @@ { char buf[16]; sprintf(buf, "%04X", response.DimseStatus); - throw OrthancException(ErrorCode_NetworkProtocol, - "C-MOVE SCU to AET \"" + remoteAet_ + - "\" has failed with DIMSE status 0x" + buf); + + if (response.DimseStatus == STATUS_MOVE_Failed_UnableToProcess) + { + throw OrthancException(ErrorCode_NetworkProtocol, + HttpStatus_422_UnprocessableEntity, + "C-MOVE SCU to AET \"" + remoteAet_ + + "\" has failed with DIMSE status 0x" + buf + + " (unable to process - resource not found ?)" + ); + } + else + { + throw OrthancException(ErrorCode_NetworkProtocol, + "C-MOVE SCU to AET \"" + remoteAet_ + + "\" has failed with DIMSE status 0x" + buf); + } } }