Explorar el Código

Merge branch '0.2' of https://github.com/open62541/open62541 into 0.2

ichrispa hace 8 años
padre
commit
5776128d1c
Se han modificado 1 ficheros con 3 adiciones y 1 borrados
  1. 3 1
      src/server/ua_server_worker.c

+ 3 - 1
src/server/ua_server_worker.c

@@ -247,7 +247,9 @@ processRepeatedJobs(UA_Server *server, UA_DateTime current) {
         /* Set the time for the next execution */
         rj->nextTime += (UA_Int64)rj->interval;
         if(rj->nextTime < current)
-            rj->nextTime = current;
+            rj->nextTime = current + 1; /* prevent to rerun the job right now
+                                           when the repeated jobs took more time
+                                           than rj->interval */
 
         /* Keep the list sorted */
         struct RepeatedJob *prev_rj = lastNow;