Race conditions in ssh smart subtransport caused some goroutines to panic, resulting in crashing the whole controller, mostly evident in image-automation-controller CI runs. Panic recovery in the main thread do not handle goroutine panics. So, the existing panic recovery code in libgit2 Checkout() methods weren't able to handle it. This change groups the fields in ssh smart subtransport that may be accessed by multiple goroutines into a new struct with a mutex. Also adds panic recovery in the created goroutine to handle any other possible panics. Signed-off-by: Sunny <darkowlzz@protonmail.com> |
||
---|---|---|
.. | ||
const.go | ||
http.go | ||
http_test.go | ||
init.go | ||
options.go | ||
options_test.go | ||
ssh.go | ||
ssh_test.go | ||
transport.go | ||
transport_test.go |