platformutils.py 文件源码

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

项目:xpybuild 作者: xpybuild 项目源码 文件源码
def lowerCurrentProcessPriority():
    if buildcommon.isWindows():
        import win32process, win32api,win32con
        win32process.SetPriorityClass(win32api.GetCurrentProcess(), win32process.BELOW_NORMAL_PRIORITY_CLASS)
    else:
        # on unix, people may run nice before executing the process, so 
        # only change the priority unilaterally if it's currently at its 
        # default value
        if os.nice(0) == 0:
            os.nice(1) # change to 1 below the current level
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号