Memory leak in root UIViewController of tab bar
For the UIVIewController which is released and pushed on the navigation stack, memory allocated to it gets deallocated when view is popped.
But wh开发者_开发技巧at about viewcontroller which is rootview controller i.e the first member on navigation stack which in turn bound to tab bar? How to trace memory leak in it??If it's never removed during the course of the app running, you don't need to worry about it leaking its member variables, because they'll always be required while the app is open.
When the app closes, the OS cleans up all the memory allocated to the app, even if it has leaked, so there's nothing to worry about.
For testing purpose I pushed the viewController from some dummy viewController...
精彩评论