Objective-C Memory Question

Posted by Winder on Stack Overflow See other posts from Stack Overflow or by Winder
Published on 2010-04-11T17:00:24Z Indexed on 2010/04/11 17:03 UTC
Read the original article Hit count: 389

Filed under:

Is it a leak if I have a view controller and allocate the view like this:

self.view = [[UIView alloc] initWithFrame:frame];

Do I need to do something like this:

UIView *v = [[UIView alloc] initWithFrame:frame];
self.view = v;
[v release];

© Stack Overflow or respective owner

Related posts about objective-c