summaryrefslogtreecommitdiff
path: root/MobileCydia.mm
diff options
context:
space:
mode:
authorJay Freeman (saurik) <saurik@saurik.com>2010-12-07 02:23:24 -0800
committerJay Freeman (saurik) <saurik@saurik.com>2011-01-01 14:32:06 -0800
commitd3aa466c92e3677aca0d4e7adff3bdcba1a00030 (patch)
tree35b62857cf44e73bc709431dde6f221bba2a34ce /MobileCydia.mm
parent4905df000ad745fa65c734ea7aa4cbd53e34b595 (diff)
Reallocate ChangesController::packages_ in _reloadPackages: instead of clearing in reloadData.
Diffstat (limited to 'MobileCydia.mm')
-rw-r--r--MobileCydia.mm5
1 files changed, 3 insertions, 2 deletions
diff --git a/MobileCydia.mm b/MobileCydia.mm
index b7050fc..ec4ba25 100644
--- a/MobileCydia.mm
+++ b/MobileCydia.mm
@@ -7542,6 +7542,9 @@ freeing the view controllers on tab change */
}
- (void) _reloadPackages:(NSArray *)packages {
+ CFRelease(packages_);
+ packages_ = CFArrayCreateMutable(kCFAllocatorDefault, [packages count], NULL);
+
_trace();
for (Package *package in packages)
if ([package upgradableAndEssential:YES] || [package visible])
@@ -7556,8 +7559,6 @@ freeing the view controllers on tab change */
era_ = [database_ era];
NSArray *packages = [database_ packages];
- CFArrayRemoveAllValues(packages_);
-
[sections_ removeAllObjects];
#if 1