Lines Matching refs:peer_atom
84 /* use for bitwise operations w/peer_atom.flags2 */
87 /* use for bitwise operations w/peer_atom.flags2 */
118 struct peer_atom
147 tr_isAtom( const struct peer_atom * atom )
157 tr_atomAddrStr( const struct peer_atom * atom )
187 tr_ptrArray pool; /* struct peer_atom */
313 const struct peer_atom * a = va;
321 const struct peer_atom * b = vb;
353 static struct peer_atom*
363 peerIsInUse( const Torrent * ct, const struct peer_atom * atom )
383 peerNew( struct peer_atom * atom )
395 getPeer( Torrent * torrent, struct peer_atom * atom )
629 struct peer_atom * atom = tr_ptrArrayNth( &t->pool, i );
636 isAtomBlocklisted( tr_session * session, struct peer_atom * atom )
651 atomSetSeedProbability( struct peer_atom * atom, int seedProbability )
665 atomIsSeed( const struct peer_atom * atom )
671 atomSetSeed( const Torrent * t, struct peer_atom * atom )
688 const struct peer_atom * atom = getExistingAtom( t, addr );
699 struct peer_atom * atom = getExistingAtom( tor->torrentPeers, addr );
708 struct peer_atom * atom = getExistingAtom( tor->torrentPeers, addr );
1548 struct peer_atom * atom = peer->atom;
1903 struct peer_atom * a;
1913 a = tr_new0( struct peer_atom, 1 );
1995 struct peer_atom * atom = getExistingAtom( t, addr );
2010 struct peer_atom * atom;
2147 struct peer_atom ** it = (struct peer_atom**) tr_ptrArrayBase( &t->pool );
2148 struct peer_atom ** end = it + n;
2281 const struct peer_atom * a = * (const struct peer_atom**) va;
2282 const struct peer_atom * b = * (const struct peer_atom**) vb;
2298 isAtomInteresting( const tr_torrent * tor, struct peer_atom * atom )
2327 struct peer_atom ** atoms = NULL;
2347 atoms = tr_new( struct peer_atom *, atomCount );
2354 struct peer_atom ** atomBase = (struct peer_atom**) tr_ptrArrayBase( &t->pool );
2356 atoms = tr_new( struct peer_atom *, n );
2362 qsort( atoms, atomCount, sizeof( struct peer_atom * ), compareAtomsByUsefulness );
2373 const struct peer_atom * atom = atoms[i];
2662 const struct peer_atom * atom = peer->atom;
2732 const struct peer_atom * atom = peer->atom;
3042 getRate( const tr_torrent * tor, struct peer_atom * atom, uint64_t now )
3100 struct peer_atom * atom = peer->atom;
3219 const struct peer_atom * atom = peer->atom;
3279 getReconnectIntervalSecs( const struct peer_atom * atom, const time_t now )
3317 struct peer_atom * atom = peer->atom;
3336 struct peer_atom * atom;
3650 const struct peer_atom * a = * (const struct peer_atom**) va;
3651 const struct peer_atom * b = * (const struct peer_atom**) vb;
3665 const struct peer_atom * a = * (const struct peer_atom**) va;
3666 const struct peer_atom * b = * (const struct peer_atom**) vb;
3708 struct peer_atom ** atoms = (struct peer_atom**) tr_ptrArrayPeek( &t->pool, &atomCount );
3715 struct peer_atom ** keep = tr_new( struct peer_atom*, atomCount );
3716 struct peer_atom ** test = tr_new( struct peer_atom*, atomCount );
3720 struct peer_atom * atom = atoms[i];
3730 qsort( test, testCount, sizeof( struct peer_atom * ), compareAtomPtrsByShelfDate );
3742 qsort( keep, keepCount, sizeof( struct peer_atom * ), compareAtomPtrsByAddress );
3766 isPeerCandidate( const tr_torrent * tor, struct peer_atom * atom, const time_t now )
3795 struct peer_atom * atom;
3814 getPeerCandidateScore( const tr_torrent * tor, const struct peer_atom * atom, uint8_t salt )
3998 struct peer_atom ** atoms;
4011 atoms = (struct peer_atom**) tr_ptrArrayPeek( &tor->torrentPeers->pool, &nAtoms );
4014 struct peer_atom * atom = atoms[i];
4037 initiateConnection( tr_peerMgr * mgr, Torrent * t, struct peer_atom * atom )