Mercurial > hg > orthanc
comparison OrthancFramework/Sources/JobsEngine/JobsRegistry.cpp @ 4768:a046e91cc76f
cont fix
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 18 Aug 2021 15:26:48 +0200 |
parents | 1db3b79d97bd |
children | 0a38000b086d |
comparison
equal
deleted
inserted
replaced
4767:e1711b6e141f | 4768:a046e91cc76f |
---|---|
222 } | 222 } |
223 | 223 |
224 const boost::posix_time::time_duration& GetRuntime() const | 224 const boost::posix_time::time_duration& GetRuntime() const |
225 { | 225 { |
226 return runtime_; | 226 return runtime_; |
227 } | |
228 | |
229 void ResetRuntime() | |
230 { | |
231 runtime_ = boost::posix_time::milliseconds(0); | |
227 } | 232 } |
228 | 233 |
229 const JobStatus& GetLastStatus() const | 234 const JobStatus& GetLastStatus() const |
230 { | 235 { |
231 return lastStatus_; | 236 return lastStatus_; |
1069 } | 1074 } |
1070 | 1075 |
1071 (void) ok; // Remove warning about unused variable in release builds | 1076 (void) ok; // Remove warning about unused variable in release builds |
1072 assert(ok); | 1077 assert(ok); |
1073 | 1078 |
1079 found->second->ResetRuntime(); | |
1074 found->second->SetState(JobState_Pending); | 1080 found->second->SetState(JobState_Pending); |
1075 pendingJobs_.push(found->second); | 1081 pendingJobs_.push(found->second); |
1076 pendingJobAvailable_.notify_one(); | 1082 pendingJobAvailable_.notify_one(); |
1077 | 1083 |
1078 CheckInvariants(); | 1084 CheckInvariants(); |