On Sat, May 22, 2021 at 5:53 AM Manlio Perillo <manlio.peri...@gmail.com> wrote: > > I'm curious to know if sigprocmask is safe/convenient to use in a Go program.
It's possible, of course, but it's not particularly convenient. sigprocmask isn't a good fit for multi-threaded programs, and most Go programs are multi-threaded. For cases where C programs use sigprocmask Go programs normally use signal.Notify. signal.Notify already lets the Go program handle the signal at a convenient time, which is the main benefit of using sigprocmask in a single-threaded C program. Ian -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/CAOyqgcW6XVG_os3Qn%3DDDETFWkUjKbzSzPEoUwWZcCS49t%3DT4Cg%40mail.gmail.com.