Changeset 7607


Ignore:
Timestamp:
Jan 4, 2009, 4:37:26 AM (12 years ago)
Author:
charles
Message:

(trunk libT) don't use void* when doing pointer math.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/peer-io.c

    r7595 r7607  
    664664            break;
    665665
    666         case PEER_ENCRYPTION_RC4:
     666        case PEER_ENCRYPTION_RC4: {
     667            const uint8_t * walk = bytes;
    667668            evbuffer_expand( outbuf, byteCount );
    668669            while( byteCount > 0 ) {
    669670                const size_t thisPass = MIN( byteCount, sizeof( tmp ) );
    670                 tr_cryptoEncrypt( io->crypto, thisPass, bytes, tmp );
     671                tr_cryptoEncrypt( io->crypto, thisPass, walk, tmp );
    671672                evbuffer_add( outbuf, tmp, thisPass );
    672                 bytes += thisPass;
     673                walk += thisPass;
    673674                byteCount -= thisPass;
    674675            }
    675676            break;
     677        }
    676678
    677679        default:
Note: See TracChangeset for help on using the changeset viewer.