The following leaks:
CFStringRef labelName = ABAddressBookCopyLocalizedLabel(ABMultiValueCopyLabelAtIndex(aMultiRef, indexPath.row));
cell.textLabel.text = (NSString *)labelName;
CFRelease(labelName);
Wondering if there a way to rewrite it so it doesn't leak without breaking out & assigning ABMultiValueCopyLabelAtIndex(aMultiRef, indexPath.row)
to a CFStringRef
that I then need to manually CFRelease
2 lines later? Of course, it's not a big deal to do just that...I'm just curious.
Edit: Would CFAutoRelease
work? see my comment below