mirror of
https://github.com/RGBCube/serenity
synced 2025-07-24 21:27:44 +00:00
CSocket: Close the underlying socket on destruction
Otherwise we leak the file descriptor.
This commit is contained in:
parent
e58b734363
commit
948c2657d6
1 changed files with 1 additions and 0 deletions
|
@ -18,6 +18,7 @@ CSocket::CSocket(Type type, CObject* parent)
|
||||||
|
|
||||||
CSocket::~CSocket()
|
CSocket::~CSocket()
|
||||||
{
|
{
|
||||||
|
close();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool CSocket::connect(const String& hostname, int port)
|
bool CSocket::connect(const String& hostname, int port)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue