xcode4.5 EXC_BAD_ACCESS调试

1.进入Edit Scheme设置页面。

2.在Diagnostics面板中选中Enable Zombie Objects和Malloc Stack选项。

3.把xcode4.5默认的Debugger设置为GDB。

4.当出现message sent to deallocated instance ******,键入info malloc-history ******。

5.根据堆栈信息,定位到内存泄漏的代码。

猜你喜欢

转载自perfectcheer.iteye.com/blog/1776144