Changeset 2890


Ignore:
Timestamp:
Aug 21, 2007, 3:12:09 PM (15 years ago)
Author:
charles
Message:

(0.8x) backport r2872's leak fix for 0.81. update the NEWS file.

Location:
branches/0.8x
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/0.8x/NEWS

    r2647 r2890  
    11NEWS file for Transmission <http://transmission.m0k.org/>
     2
     30.81 (2007/xx/yy)
     4 - Fix 0.80 assertion crashes.
     5 - Fix a bug which miscounted how many peers Transmission wants connected
     6 - Memory leaks fixed.
     7 - OS X:
     8   + Multiple fixes to creating torrents and adding new torrents
     9   + Updated Russian translation
     10 - GTK:
     11   + Updated Dutch, Portuguese, French, and Slovakian translations
     12 - CLI:
     13   + Better support for cli-driven torrent creation.
     14   + Fix a bug which misparsed command-line arguments.
    215
    3160.80 (2007/08/07)
  • branches/0.8x/libtransmission/torrent.c

    r2650 r2890  
    360360                 tr_info_t          * setme_info )
    361361{
    362     int ret;
     362    int ret, doFree;
    363363    tr_info_t tmp;
    364364
     
    368368    memset( setme_info, 0, sizeof( tr_info_t ) );
    369369    ret = tr_metainfoParseFile( setme_info, h->tag, path, FALSE );
     370    doFree = !ret && (setme_info == &tmp);
    370371
    371372    if( ret == TR_OK )
    372373        ret = infoCanAdd( h, destination, setme_info );
    373374
    374     /* if we allocated a temporary info, free it */
    375     if( !ret && ( setme_info == &tmp ) )
     375    if( doFree )
    376376        tr_metainfoFree( &tmp );
    377377
     
    411411                     tr_info_t          * setme_info )
    412412{
    413     int ret;
     413    int ret, doFree;
    414414    tr_info_t tmp;
    415415
     
    419419    memset( setme_info, 0, sizeof( tr_info_t ) );
    420420    ret = tr_metainfoParseHash( setme_info, h->tag, hashStr );
     421    doFree = !ret && (setme_info == &tmp);
    421422
    422423    if( ret == TR_OK )
    423424        ret = infoCanAdd( h, destination, setme_info );
    424425
    425     if( setme_info == &tmp )
     426    if( doFree )
    426427        tr_metainfoFree( &tmp );
    427428
     
    463464                     tr_info_t          * setme_info )
    464465{
    465     int ret;
     466    int ret, doFree;
    466467    tr_info_t tmp;
    467468
     
    471472    memset( setme_info, 0, sizeof( tr_info_t ) );
    472473    ret = tr_metainfoParseData( setme_info, h->tag, data, size, FALSE );
     474    doFree = !ret && (setme_info == &tmp);
    473475
    474476    if( ret == TR_OK )
    475477        ret = infoCanAdd( h, destination, setme_info );
    476478
    477     if( setme_info == &tmp )
     479    if( doFree )
    478480        tr_metainfoFree( &tmp );
    479481
Note: See TracChangeset for help on using the changeset viewer.