Mercurial > hg > orthanc
diff Core/DicomNetworking/Internals/StoreScp.cpp @ 3786:3801435e34a1 SylvainRouquette/fix-issue169-95b752c
integration Orthanc-1.6.0->SylvainRouquette
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 19 Mar 2020 11:48:30 +0100 |
parents | 58f92b1c8061 |
children |
line wrap: on
line diff
--- a/Core/DicomNetworking/Internals/StoreScp.cpp Wed Mar 18 08:59:06 2020 +0100 +++ b/Core/DicomNetworking/Internals/StoreScp.cpp Thu Mar 19 11:48:30 2020 +0100 @@ -2,7 +2,7 @@ * Orthanc - A Lightweight, RESTful DICOM Store * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics * Department, University Hospital of Liege, Belgium - * Copyright (C) 2017-2019 Osimis S.A., Belgium + * Copyright (C) 2017-2020 Osimis S.A., Belgium * * This program is free software: you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -251,7 +251,8 @@ T_DIMSE_Message * msg, T_ASC_PresentationContextID presID, IStoreRequestHandler& handler, - const std::string& remoteIp) + const std::string& remoteIp, + int timeout) { OFCondition cond = EC_Normal; T_DIMSE_C_StoreRQ *req; @@ -294,8 +295,8 @@ cond = DIMSE_storeProvider(assoc, presID, req, NULL, /*opt_useMetaheader*/OFFalse, &dset, storeScpCallback, &data, - /*opt_blockMode*/ DIMSE_BLOCKING, - /*opt_dimse_timeout*/ 0); + /*opt_blockMode*/ (timeout ? DIMSE_NONBLOCKING : DIMSE_BLOCKING), + /*opt_dimse_timeout*/ timeout); // if some error occured, dump corresponding information and remove the outfile if necessary if (cond.bad())