mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
Merge branch 'master' of https://github.com/cgrates/cgrates
This commit is contained in:
@@ -40,11 +40,10 @@ func NewScheduler() *Scheduler {
|
||||
|
||||
func (s *Scheduler) Loop() {
|
||||
for {
|
||||
s.Lock()
|
||||
for len(s.queue) == 0 { //hang here if empty
|
||||
s.Unlock()
|
||||
<-s.restartLoop
|
||||
}
|
||||
s.Lock()
|
||||
a0 := s.queue[0]
|
||||
now := time.Now()
|
||||
if a0.GetNextStartTime().Equal(now) || a0.GetNextStartTime().Before(now) {
|
||||
|
||||
Reference in New Issue
Block a user