# HG changeset patch # User Sebastien Jodogne # Date 1792588639 -7200 # Node ID 67a629f02859fe160f1957dcbe61c71995a15e76 # Parent e4bf724a5886c238f01bfbc57acca0271acd097d reduce granularity if the runnable must be executed faster diff -r e4bf724a5886 -r 67a629f02859 OrthancFramework/Sources/MultiThreading/PeriodicRunnableThread.cpp --- a/OrthancFramework/Sources/MultiThreading/PeriodicRunnableThread.cpp Wed Oct 21 15:11:24 2026 +0200 +++ b/OrthancFramework/Sources/MultiThreading/PeriodicRunnableThread.cpp Wed Oct 21 15:17:19 2026 +0200 @@ -102,6 +102,12 @@ { throw OrthancException(ErrorCode_NullPointer); } + + // Reduce the default granularity if the runnable must be executed faster + if (delay_ < timeResolution_) + { + timeResolution_ = delay_; + } }