usb_checkout.py 文件源码

python
阅读 27 收藏 0 点赞 0 评论 0

项目:DeviceNanny 作者: hudl 项目源码 文件源码
def stop_program_if_running():
    """
    Gets the group process ID from the process ID of shell script triggered by UDEV rule.
    Then calls the kill function.
    """
    pid = get_pid("[s]tart_checkout")
    print(pid)
    print(type(pid))
    pgid = os.getpgid(int(pid[0]))
    logging.debug(
        "[usb_checkout][stop_program_if_running] PGID: {}".format(pgid))
    delete_tempfile(filename)
    kill(pgid)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号