python 信号量处理

https://www.jianshu.com/p/7d1855cd916f


def signal(sig, action): # real signature unknown; restored from __doc__
"""
signal(sig, action) -> action

Set the action for the given signal. The action can be SIG_DFL,
SIG_IGN, or a callable Python object. The previous action is
returned. See getsignal() for possible return values.

*** IMPORTANT NOTICE ***
A signal handler function is called with two arguments:
the first is the signal number, the second is the interrupted stack frame.
"""
pass

注意 the first is the signal number, the second is the interrupted stack frame.

posted @ 2020-08-11 17:37  峡谷恶霸  阅读(188)  评论(0编辑  收藏  举报