From 8564efc10bfb681032fc53cf3658b01dfb4ca29f Mon Sep 17 00:00:00 2001 From: "Jay Freeman (saurik)" Date: Tue, 30 Nov 2010 16:27:29 -0800 Subject: [PATCH] Allocate Package objects into an NSZone. --- MobileCydia.mm | 26 ++++++++++++++++++++------ 1 file changed, 20 insertions(+), 6 deletions(-) diff --git a/MobileCydia.mm b/MobileCydia.mm index da729a89..249c15d9 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -2295,12 +2295,26 @@ struct PackageNameOrdering : if (version.end()) return nil; - return [[[Package alloc] - initWithVersion:version - withZone:zone - inPool:pool - database:database - ] autorelease]; + Package *package; + + _profile(Package$packageWithIterator$Allocate) + package = [Package allocWithZone:zone]; + _end + + _profile(Package$packageWithIterator$Initialize) + package = [package + initWithVersion:version + withZone:zone + inPool:pool + database:database + ]; + _end + + _profile(Package$packageWithIterator$Autorelease) + package = [package autorelease]; + _end + + return package; } - (pkgCache::PkgIterator) iterator { -- 2.47.2