Skip to content

Commit fa92ae6

Browse files
author
ubuntu
committed
update
1 parent b254efb commit fa92ae6

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

clients/client-linux.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,10 +151,10 @@ def get_network(ip_version):
151151
HOST = "ipv6.google.com"
152152
try:
153153
s = socket.create_connection((HOST, 80), 2)
154+
s.close()
154155
return True
155156
except:
156-
pass
157-
return False
157+
return False
158158

159159
lostRate = {
160160
'10010': 0.0,

clients/client-psutil.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,10 +119,10 @@ def get_network(ip_version):
119119
HOST = "ipv6.google.com"
120120
try:
121121
s = socket.create_connection((HOST, 80), 2)
122+
s.close()
122123
return True
123124
except:
124-
pass
125-
return False
125+
return False
126126

127127
lostRate = {
128128
'10010': 0.0,

0 commit comments

Comments
 (0)