Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在编写一个与用户进程交换数据的 linux 模块。如果模块尝试向终止的用户进程发送数据,系统可能会崩溃。为了避免崩溃,我们可以使用 kill() 函数来检查 pid 的可用性。但它不会每次都起作用,因为在 kill() 函数成功返回后可能会关闭用户进程。我想知道“是否存在可以处理这种情况的任何信号和信号处理机制?”。如果是,那么请解释一下。
谢谢..