summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--service/reload/service.go3
-rw-r--r--service/reload/watcher.go3
2 files changed, 2 insertions, 4 deletions
diff --git a/service/reload/service.go b/service/reload/service.go
index 73e20085..9c615e0b 100644
--- a/service/reload/service.go
+++ b/service/reload/service.go
@@ -6,7 +6,6 @@ import (
"github.com/spiral/roadrunner"
"github.com/spiral/roadrunner/service"
"os"
- "runtime"
"strings"
"time"
)
@@ -144,7 +143,7 @@ func (s *Service) Serve() error {
}
case <-s.stopc:
ticker.Stop()
- runtime.Goexit()
+ return
}
}
}()
diff --git a/service/reload/watcher.go b/service/reload/watcher.go
index a3b8fe1f..027d2d0d 100644
--- a/service/reload/watcher.go
+++ b/service/reload/watcher.go
@@ -5,7 +5,6 @@ import (
"io/ioutil"
"os"
"path/filepath"
- "runtime"
"sync"
"time"
)
@@ -228,7 +227,7 @@ func (w *Watcher) waitEvent(d time.Duration) error {
ticker.Stop()
// just exit
// no matter for the pollEvents
- runtime.Goexit()
+ return nil
case <-ticker.C:
// this is not very effective way
// because we have to wait on Lock