diff options
author | Jay Freeman (saurik) <saurik@saurik.com> | 2011-03-08 14:24:51 -0800 |
---|---|---|
committer | Jay Freeman (saurik) <saurik@saurik.com> | 2011-03-08 14:24:51 -0800 |
commit | 78de2878cd72973d386b3ea92a93188b6de8ec84 (patch) | |
tree | f0c5f679044f0dde102b6ec78f1870832394db9a | |
parent | 7be3eb3270fb2a03788c01abf3a5f270eda54531 (diff) |
Do not attempt to copy nil strings.
-rw-r--r-- | MobileCydia.mm | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/MobileCydia.mm b/MobileCydia.mm index 0d22a11..11127ac 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -5092,15 +5092,19 @@ bool DepSubstrate(const pkgCache::VerIterator &iterator) { Source *source = [package source]; icon_ = [package icon]; - name_ = [NSString stringWithString:[package name]]; + + if (NSString *name = [package name]) + name_ = [NSString stringWithString:name]; NSString *description(nil); + if (description == nil && IsWildcat_) description = [package longDescription]; if (description == nil) description = [package shortDescription]; - description_ = [NSString stringWithString:description]; + if (description != nil) + description_ = [NSString stringWithString:description]; commercial_ = [package isCommercial]; |