Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Lots of confusion here... let's see if this helps:</p> <blockquote> <p>What I can't understand is why the system is trying to message this controller even though it has been deallocated and is there a way to tell the system that the controller doesn't exist any longer.</p> </blockquote> <p>While deallocation destroys the instance of an object, it doesn't destroy the references to the instances. With Zombie detection enabled, deallocation causes the runtime to substitute a zombie for the instance. The zombie then detects and logs when it is messaged.</p> <p>The reason why this happens is because the object has been deallocated without also removing all references to the object from the application's object graph. In this case, it looks like the deallocated controller was never unset as the controller from the UIWindow instance.</p> <p>That is, <strong><em>the processing of the notification is a red herring</em></strong>. In that backtrace, the notification has already been delivered and UIWindow is in the midst of processing it. Thus, the problem is somewhere between the UIWindow and your application. Most likely, your object has been deallocated <em>before</em> being removed from the window as its controller or delegate.</p> <p>Before your program is truly done with an object -- before you send the last <code>-release</code> call that balances the last existing <code>-retain</code> your application caused or called -- you must make sure that all weak references to the object are destroyed. For example, if your object is the delegate of a UIWindow, make sure you set the delegate of the window to <code>nil</code> (or some other object) before sending that last <code>-release</code>.</p> <p>Now, in this case, it may also simply be that you have over-released the object. You might still need the object around, but an extra <code>-release</code> or <code>-autorelease</code> somewhere is causing it to be destroyed before you were done with it.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload