参见sigaction:http
:
//pubs.opengroup.org/onlinepubs/009695399/functions/sigaction.html
SA_RESTART This flag affects the behavior of interruptible functions; that is, those specified to fail with errno set to EINTR. If set, and a function specified as interruptible is interrupted by this signal, the function shall restart and shall not fail with EINTR unless otherwise specified. If the flag is not set, interruptible functions interrupted by this signal shall fail with errno set to EINTR.
默认情况下,您具有SA_RESTART行为,因此,如果您不使用信号,则不必担心EINTR。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)