From: Jay Freeman (saurik) Date: Wed, 1 Dec 2010 00:27:29 +0000 (-0800) Subject: Allocate Package objects into an NSZone. X-Git-Tag: v1.1.0%b1~465 X-Git-Url: https://git.saurik.com/cydia.git/commitdiff_plain/8564efc10bfb681032fc53cf3658b01dfb4ca29f Allocate Package objects into an NSZone. --- 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 {