mirror of https://github.com/cppla/ServerStatus
				
				
				
			修复一个大bug, 网络不稳线程反复创建
							parent
							
								
									1eddbfe6e8
								
							
						
					
					
						commit
						b1166a540c
					
				|  | @ -224,6 +224,7 @@ if __name__ == '__main__': | |||
|         elif 'INTERVAL' in argc: | ||||
|             INTERVAL = int(argc.split('INTERVAL=')[-1]) | ||||
|     socket.setdefaulttimeout(30) | ||||
|     get_packetLostRate() | ||||
|     while 1: | ||||
|         try: | ||||
|             print("Connecting...") | ||||
|  | @ -256,7 +257,6 @@ if __name__ == '__main__': | |||
| 
 | ||||
|             traffic = Traffic() | ||||
|             traffic.get() | ||||
|             get_packetLostRate() | ||||
|             while 1: | ||||
|                 CPU = get_cpu() | ||||
|                 NetRx, NetTx = traffic.get() | ||||
|  |  | |||
|  | @ -193,6 +193,7 @@ if __name__ == '__main__': | |||
|         elif 'INTERVAL' in argc: | ||||
|             INTERVAL = int(argc.split('INTERVAL=')[-1]) | ||||
|     socket.setdefaulttimeout(30) | ||||
|     get_packetLostRate() | ||||
|     while 1: | ||||
|         try: | ||||
|             print("Connecting...") | ||||
|  | @ -225,7 +226,6 @@ if __name__ == '__main__': | |||
| 
 | ||||
|             traffic = Traffic() | ||||
|             traffic.get() | ||||
|             get_packetLostRate() | ||||
|             while 1: | ||||
|                 CPU = get_cpu() | ||||
|                 NetRx, NetTx = traffic.get() | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	 ubuntu
						ubuntu