Changeset 5153


Ignore:
Timestamp:
Feb 27, 2008, 8:16:01 PM (14 years ago)
Author:
charles
Message:

#740 fix tr_torrentParse() leak when adding duplicate torrents.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/torrent.c

    r5143 r5153  
    423423
    424424    err = tr_metainfoParse( setmeInfo, metainfo, handle->tag );
    425     doFree = !err && ( setmeInfo == &tmp );
    426425
    427426    if( !err && hashExists( handle, setmeInfo->hash ) )
    428427        err = TR_EDUPLICATE;
     428
     429    doFree = ( !err || err==TR_EDUPLICATE ) && ( setmeInfo == &tmp );
    429430
    430431    if( doFree )
Note: See TracChangeset for help on using the changeset viewer.