Skip to content
Snippets Groups Projects
Commit 44d2d719 authored by ale's avatar ale
Browse files

Fix lint warnings

parent 9c1ac9bc
No related branches found
No related tags found
1 merge request!20Refactor the Engine with stronger guarantees
Pipeline #88147 passed
......@@ -79,6 +79,7 @@ linters-settings:
gosec:
excludes:
- "G104"
- "G114"
- "G115"
- "G204"
- "G304"
......
......@@ -122,8 +122,13 @@ func main() {
}()
signal.Notify(termCh, syscall.SIGTERM, syscall.SIGINT)
// Spawn the HTTP server on a goroutine.
go http.ListenAndServe(*addr, vmine.NewHTTPEngine(engine))
// Spawn the HTTP server on a goroutine. Errors will cause the
// process to abort (no clean shutdown).
go func() {
if err := http.ListenAndServe(*addr, vmine.NewHTTPEngine(engine)); err != nil && !errors.Is(err, http.ErrServerClosed) {
log.Fatal(err)
}
}()
engine.Wait()
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment