From 78de2878cd72973d386b3ea92a93188b6de8ec84 Mon Sep 17 00:00:00 2001 From: "Jay Freeman (saurik)" Date: Tue, 8 Mar 2011 14:24:51 -0800 Subject: Do not attempt to copy nil strings. --- MobileCydia.mm | 8 ++++++-- 1 file 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]; -- cgit v1.2.3