mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-20 23:47:23 -06:00
Manually abort lookup on class destruction
Some lookup might take longer so instead of waiting them, we abort them manually.
This commit is contained in:
committed by
sledgehammer999
parent
4006818520
commit
000a726e20
@@ -52,6 +52,9 @@ ReverseResolution::ReverseResolution(QObject *parent)
|
|||||||
|
|
||||||
ReverseResolution::~ReverseResolution()
|
ReverseResolution::~ReverseResolution()
|
||||||
{
|
{
|
||||||
|
// abort on-going lookups instead of waiting them
|
||||||
|
for (auto iter = m_lookups.cbegin(); iter != m_lookups.cend(); ++iter)
|
||||||
|
QHostInfo::abortHostLookup(iter.key());
|
||||||
}
|
}
|
||||||
|
|
||||||
void ReverseResolution::resolve(const QHostAddress &ip)
|
void ReverseResolution::resolve(const QHostAddress &ip)
|
||||||
|
|||||||
Reference in New Issue
Block a user