Skip to content

Commit 112b5c8

Browse files
author
woytu
committed
fixed 改变清除内存策略
1 parent 76f8a77 commit 112b5c8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

utils/SystemUtil.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ def restart_process(path):
140140
:param path: 执行脚本的全路径
141141
:return:
142142
"""
143-
if psutil.virtual_memory().percent < 80:
143+
if psutil.virtual_memory().percent >= 80:
144144
print('内存使用:', psutil.Process(os.getpid()).memory_info().rss)
145145
print("当前内存占用率:", psutil.virtual_memory().percent)
146146
# if gc.isenabled():

0 commit comments

Comments
 (0)