3 ms·
You're right, but I think it's an acceptable risk. pact wakes up every second to check that every process is still there. If the process is gone, it sets the p
by nickodell 11y ago
You're right, but I think it's an acceptable risk.
pact wakes up every second to check that every process is still there. If the process is gone, it sets the procChanged field in the struct, and it won't kill it later.
- int0x80 11y agoStill, what you are doing is inherently racy. The very moment you pass the PIDs to your program, they can already be gone and reused. You can end up kill()ing a different PID. I don't think you can use this for anything serious. In what situation do you think it might be acceptable? EDIT: You are trying to implement process groups in user space.