开发者

memory leaks this code

htmPath = [[NSBundle mainBundle] pathForResource:@"barcode" ofType:@"html"];
params = [[NSString alloc] initWithFormat:@"?data=%@",numberTextField.text];
fileURL = [NSURL URLWithString:[[[NSURL fileURLWithPath:htmPath] absoluteString] stringByAppendingString:params]];

[self.barView loadRequest:[NSURLRequest requestWithURL:fileURL]];

////htmpath,params are strings.

///fileurl is nsurl and in this i m calling appending two strings for the result. ///numberTextField.text is the textfield that will use this html for further f开发者_如何学Cunctionality.


you have allocated the "params" and did not released it.

params = [[NSString alloc] initWithFormat:@"?data=%@",numberTextField.text];

you should release every allocated object.

[params release];
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜