mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-04-21 16:31:58 +02:00
Be more careful when accessing cc->socket() in Servent::claimOffer().
This commit is contained in:
parent
4554757bbf
commit
0ddad1c0ed
@ -1135,7 +1135,11 @@ Servent::claimOffer( ControlConnection* cc, const QString &nodeid, const QString
|
||||
QMutexLocker locker( &d->controlconnectionsMutex );
|
||||
foreach ( ControlConnection* cc, d->controlconnections )
|
||||
{
|
||||
tLog( LOGVERBOSE ) << Q_FUNC_INFO << "Probing:" << cc->name() << cc->socket()->peerAddress();
|
||||
if ( cc->socket() )
|
||||
tLog( LOGVERBOSE ) << Q_FUNC_INFO << "Probing:" << cc->name() << cc->socket()->peerAddress();
|
||||
else
|
||||
tLog( LOGVERBOSE ) << Q_FUNC_INFO << "Probing error:" << cc->name() << "has invalid socket";
|
||||
|
||||
// Always compare IPv6 addresses as IPv4 address are sometime simply IPv4 addresses, sometimes mapped IPv6 addresses
|
||||
if ( cc->socket() && equalByIPv6Address( cc->socket()->peerAddress(), peer ) )
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user