[Lldb-commits] [lldb] r164156 - /lldb/trunk/examples/summaries/cocoa/objc_runtime.py

Enrico Granata egranata at apple.com
Tue Sep 18 11:34:14 PDT 2012


Author: enrico
Date: Tue Sep 18 13:34:14 2012
New Revision: 164156

URL: http://llvm.org/viewvc/llvm-project?rev=164156&view=rev
Log:
<rdar://problem/11398693> Making sure we do not attempt to run code on zombie objects when attempting to format them

Modified:
    lldb/trunk/examples/summaries/cocoa/objc_runtime.py

Modified: lldb/trunk/examples/summaries/cocoa/objc_runtime.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/examples/summaries/cocoa/objc_runtime.py?rev=164156&r1=164155&r2=164156&view=diff
==============================================================================
--- lldb/trunk/examples/summaries/cocoa/objc_runtime.py (original)
+++ lldb/trunk/examples/summaries/cocoa/objc_runtime.py Tue Sep 18 13:34:14 2012
@@ -104,9 +104,8 @@
 			return class_data,wrapper
 		if class_data.is_kvo():
 			class_data = class_data.get_superclass()
-		if class_data.is_valid() == 0:
-			statistics.metric_hit('invalid_isa',valobj)
-			wrapper = InvalidISA_Description()
+		if class_data.class_name() == '_NSZombie_OriginalClass':
+			wrapper = ThisIsZombie_Description()
 			return class_data,wrapper
 		return class_data,None
 
@@ -789,3 +788,6 @@
 	def message(self):
 		return '<not an Objective-C object>'
 
+class ThisIsZombie_Description(SpecialSituation_Description):
+	def message(self):
+		return '<freed object>'
\ No newline at end of file





More information about the lldb-commits mailing list