2
0
Эх сурвалжийг харах

[threads] fixed start at time

Exilon 4 жил өмнө
parent
commit
ee974f3d03

+ 3 - 2
Quick.Threads.pas

@@ -826,8 +826,9 @@ end;
 destructor TThreadedQueueList<T>.Destroy;
 destructor TThreadedQueueList<T>.Destroy;
 begin
 begin
   DoShutDown;
   DoShutDown;
-  fQueueLock.Free;
   fQueueCondVar.Free;
   fQueueCondVar.Free;
+  fQueueLock.Free;
+  //fQueueCondVar.Free;
   fQueue.Free;
   fQueue.Free;
   inherited;
   inherited;
 end;
 end;
@@ -1879,7 +1880,7 @@ begin
   Result := Self;
   Result := Self;
   ClearSchedule;
   ClearSchedule;
   fScheduleMode := TScheduleMode.smRunOnce;
   fScheduleMode := TScheduleMode.smRunOnce;
-  fStartDate := ChangeDateOfADay(Now(),aHour,aMinute,aSecond);
+  fStartDate := ChangeTimeOfADay(Now(),aHour,aMinute,aSecond);
   fNextExecution := fStartDate;
   fNextExecution := fStartDate;
 end;
 end;