Ignore:
Timestamp:
Dec 30, 2008, 8:32:00 PM (13 years ago)
Author:
charles
Message:

(trunk libT) have a pool of reusable evbuffers

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/clients.c

    r7526 r7549  
    411411    if( !*buf )
    412412    {
    413         struct evbuffer * out = evbuffer_new( );
     413        struct evbuffer * out = tr_getBuffer( );
    414414        const char *in, *in_end;
    415415        for( in=(const char*)id, in_end=in+8; in!=in_end; ++in ) {
     
    421421
    422422        tr_strlcpy( buf, EVBUFFER_DATA( out ), buflen );
    423         evbuffer_free( out );
    424     }
    425 }
     423        tr_releaseBuffer( out );
     424    }
     425}
Note: See TracChangeset for help on using the changeset viewer.