1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-26 01:27:28 +00:00

Don't use memmove() for simple assignment

This commit is contained in:
Mukund Sivaraman 2008-08-22 16:34:16 +00:00
parent c10a612f90
commit 318ca1fb7e

View file

@ -720,7 +720,7 @@ refillPulse( void * vtorrent )
{
case TR_ADDREQ_FULL:
case TR_ADDREQ_CLIENT_CHOKED:
memmove( peers+j, peers + --peerCount, sizeof *peers );
peers[j] = peers[--peerCount];
break;
case TR_ADDREQ_MISSING:
case TR_ADDREQ_DUPLICATE:
@ -743,7 +743,7 @@ refillPulse( void * vtorrent )
switch( val )
{
case TR_ADDREQ_FULL:
memmove( webseeds+j, webseeds + --webseedCount, sizeof *webseeds );
webseeds[j] = webseeds[--webseedCount];
break;
case TR_ADDREQ_OK:
tr_bitfieldAdd( t->requestedPieces, piece );