Changeset 13136


Ignore:
Timestamp:
Jan 7, 2012, 5:40:18 PM (10 years ago)
Author:
livings124
Message:

more block usage when removing previous piece info

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/macosx/Controller.m

    r13135 r13136  
    21582158            }];
    21592159           
    2160             if (index == NSNotFound)
    2161                 [(Torrent *)objDisplay setPreviousFinishedPieces: nil];
     2160            if (index == NSNotFound){NSLog(@"%@",objDisplay);
     2161                [(Torrent *)objDisplay setPreviousFinishedPieces: nil];}
    21622162            else
    21632163                [unusedIndexesInAll removeIndex: index];
     
    21652165       
    21662166        if ([[fDisplayedTorrents objectAtIndex: 0] isKindOfClass: [TorrentGroup class]])
    2167             for (TorrentGroup * group in fDisplayedTorrents)
    2168                 [[group torrents] enumerateObjectsWithOptions: NSEnumerationConcurrent usingBlock: removePreviousFinishedPieces];
     2167            [fDisplayedTorrents enumerateObjectsWithOptions: NSEnumerationConcurrent usingBlock: ^(id obj, NSUInteger idx, BOOL * stop) {
     2168                [[(TorrentGroup *)obj torrents] enumerateObjectsWithOptions: NSEnumerationConcurrent usingBlock: removePreviousFinishedPieces];
     2169            }];
    21692170        else
    21702171            [fDisplayedTorrents enumerateObjectsWithOptions: NSEnumerationConcurrent usingBlock: removePreviousFinishedPieces];
Note: See TracChangeset for help on using the changeset viewer.