UILabel release textContent crash

When I saw a crash, I analyzed the stack and found that the contents of the release UILabel crashed, but the contents of the UILabel is an NSString, which is a constant, how could crash be triggered?

Thread 0 Crashed: 0 libobjc.A.dylib objc_release + 16

1 libobjc.A.dylib object_cxxDestructFromClass(objc_object*, objc_class*) + 112

2 libobjc.A.dylib objc_destructInstance + 88

3 libobjc.A.dylib _objc_rootDealloc + 52

4 UIKitCore -[UILabel .cxx_destruct] + 232

5 libobjc.A.dylib object_cxxDestructFromClass(objc_object*, objc_class*) + 112

6 libobjc.A.dylib objc_destructInstance + 88

7 libobjc.A.dylib _objc_rootDealloc + 52

8 UIKitCore -[UIResponder dealloc] + 152

9 UIKitCore -[UIView dealloc] + 872

10 UIKitCore -[UILabel dealloc] + 172

11 libobjc.A.dylib AutoreleasePoolPage::releaseUntil(objc_object**) + 180

12 libobjc.A.dylib objc_autoreleasePoolPop + 224

13 UIKitCore -[UIView dealloc] + 844

14 libobjc.A.dylib AutoreleasePoolPage::releaseUntil(objc_object**) + 180

15 libobjc.A.dylib objc_autoreleasePoolPop + 224

16 UIKitCore -[UIView dealloc] + 844

17 UIKitCore -[UITableViewCellContentView dealloc] + 76

18 UIKitCore -[UITableViewCell .cxx_destruct] + 600

19 libobjc.A.dylib object_cxxDestructFromClass(objc_object*, objc_class*) + 112

20 libobjc.A.dylib objc_destructInstance + 88

21 libobjc.A.dylib _objc_rootDealloc + 52

22 UIKitCore -[UIResponder dealloc] + 152

23 UIKitCore -[UIView dealloc] + 872

24 UIKitCore -[UITableViewCell dealloc] + 236

25 homebrew -[CKBubbleCell dealloc] (CKBubbleCell.m:222)

26 CoreFoundation RELEASE_OBJECTS_IN_THE_ARRAY + 112

27 CoreFoundation -[__NSArrayM dealloc] + 272

28 UIKitCore -[UITableView .cxx_destruct] + 1524

29 libobjc.A.dylib object_cxxDestructFromClass(objc_object*, objc_class*) + 112

30 libobjc.A.dylib objc_destructInstance + 88

31 libobjc.A.dylib _objc_rootDealloc + 52

32 UIKitCore -[UIResponder dealloc] + 152

33 UIKitCore -[UIView dealloc] + 872

34 UIKitCore -[UIScrollView dealloc] + 852

35 UIKitCore -[UITableView dealloc] + 364

It’s hard to offer any insight based on just a backtrace. Can you post the full crash report?

See Posting a Crash Report for advice on how to do that.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

UILabel release textContent crash
 
 
Q