mirror of
https://github.com/transmission/transmission
synced 2025-02-23 14:40:43 +00:00
(trunk libT) fix assertion error reported by Rolcol earlier today in #transmission
This commit is contained in:
parent
fc8ac40bfc
commit
de24179d05
1 changed files with 9 additions and 7 deletions
|
@ -1348,16 +1348,18 @@ tr_peerMgrAddPex( tr_peerMgr * manager,
|
|||
uint8_t from,
|
||||
const tr_pex * pex )
|
||||
{
|
||||
Torrent * t;
|
||||
managerLock( manager );
|
||||
if( tr_isPex( pex ) ) /* safeguard against corrupt data */
|
||||
{
|
||||
Torrent * t;
|
||||
managerLock( manager );
|
||||
|
||||
assert( tr_isPex( pex ) );
|
||||
|
||||
t = getExistingTorrent( manager, torrentHash );
|
||||
if( !tr_sessionIsAddressBlocked( t->manager->session, &pex->addr ) )
|
||||
ensureAtomExists( t, &pex->addr, pex->port, pex->flags, from );
|
||||
t = getExistingTorrent( manager, torrentHash );
|
||||
if( !tr_sessionIsAddressBlocked( t->manager->session, &pex->addr ) )
|
||||
ensureAtomExists( t, &pex->addr, pex->port, pex->flags, from );
|
||||
|
||||
managerUnlock( manager );
|
||||
managerUnlock( manager );
|
||||
}
|
||||
}
|
||||
|
||||
tr_pex *
|
||||
|
|
Loading…
Reference in a new issue