Changeset 12218


Ignore:
Timestamp:
Mar 24, 2011, 12:56:36 AM (11 years ago)
Author:
livings124
Message:

#4063 Adding a tracker before last failed add causes lockup

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/macosx/InfoTrackersViewController.m

    r11879 r12218  
    239239        return;
    240240   
     241    [self updateInfo];
     242   
    241243    if ([[sender cell] tagForSegment: [sender selectedSegment]] == TRACKER_REMOVE_TAG)
    242244        [self removeTrackers];
     
    331333    }
    332334   
    333     NSAssert(removeCount > 0, @"Trying to remove no trackers.");
     335    //we might have no trackers if remove right after a failed add (race condition ftw)
     336    #warning look into having a failed add apply right away, so that this can become an assert
     337    if (removeCount == 0)
     338        return;
    334339   
    335340    if ([[NSUserDefaults standardUserDefaults] boolForKey: @"WarningRemoveTrackers"])
Note: See TracChangeset for help on using the changeset viewer.