On 2020-Sep-03, Tom Lane wrote: > As for the question of SIGQUIT handling, I see that postgres.c > does "PG_SETMASK(&BlockSig)" immediately after applying the sigdelset > change, so there probably isn't any harm in having the background > processes do likewise. I wonder though why bgworkers are not > applying the same policy.
It's quite likely that it's the way it is more by accident than because I was thinking extremely carefully about signal handling when originally writing that code. Some parts of that code I was copying from others' patches, and I could easily have missed a detail like this. (I didn't "git blame" to verify that these parts are mine, though). -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services