mirror of
https://github.com/Dinnerbone/mcstatus.git
synced 2026-04-05 19:41:24 +08:00
add destructor to TCPAsyncSocketConnection class
This commit is contained in:
@@ -277,8 +277,11 @@ class TCPAsyncSocketConnection(AsyncReadConnection):
|
|||||||
def write(self, data):
|
def write(self, data):
|
||||||
self.writer.write(data)
|
self.writer.write(data)
|
||||||
|
|
||||||
def close(self):
|
def __del__(self):
|
||||||
self.writer.close()
|
try:
|
||||||
|
self.writer.close()
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
class UDPAsyncSocketConnection(AsyncReadConnection):
|
class UDPAsyncSocketConnection(AsyncReadConnection):
|
||||||
|
|||||||
Reference in New Issue
Block a user