Ignore:
Timestamp:
Jun 14, 2009, 1:00:36 AM (12 years ago)
Author:
charles
Message:

(trunk libT) remove the last calls to tr_getBuffer() and tr_releaseBuffer()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/rpc-server.c

    r8599 r8685  
    125125{
    126126    const char *      code_text = tr_webGetResponseStr( code );
    127     struct evbuffer * body = tr_getBuffer( );
     127    struct evbuffer * body = evbuffer_new( );
    128128
    129129    evbuffer_add_printf( body, "<h1>%d: %s</h1>", code, code_text );
     
    132132    evhttp_send_reply( req, code, code_text, body );
    133133
    134     tr_releaseBuffer( body );
     134    evbuffer_free( body );
    135135}
    136136
     
    416416
    417417            errno = error;
    418             out = tr_getBuffer( );
     418            out = evbuffer_new( );
    419419            evhttp_add_header( req->output_headers, "Content-Type", mimetype_guess( filename ) );
    420420            add_time_header( req->output_headers, "Date", now );
     
    423423            evhttp_send_reply( req, HTTP_OK, "OK", out );
    424424
    425             tr_releaseBuffer( out );
     425            evbuffer_free( out );
    426426            tr_free( content );
    427427        }
     
    490490{
    491491    struct rpc_response_data * data = user_data;
    492     struct evbuffer * buf = tr_getBuffer( );
     492    struct evbuffer * buf = evbuffer_new( );
    493493
    494494    add_response( data->req, data->server, buf, response, response_len );
     
    497497    evhttp_send_reply( data->req, HTTP_OK, "OK", buf );
    498498
    499     tr_releaseBuffer( buf );
     499    evbuffer_free( buf );
    500500    tr_free( data );
    501501}
Note: See TracChangeset for help on using the changeset viewer.