the perils of pause(2) (www.cipht.net)
from tedu@azorius.net to programming@azorius.net on 04 Mar 2024 05:32
https://azorius.net/g/programming/p/KR4lt38GG4Kd8VXBxL-the-perils-of-pause2

I recently had a bug in a simple program that has a form I've seen a lot in the last few years: loops and signal handling without masking. The worst thing about these kinds of bugs is that they don't rear their heads immediately – they fall into the class of "huh, it's blocked in a syscall and I'm sure it should have woken up" bugs. Let's look at the problem and then how to lint it.

#c #programming #unix

threaded - newest