Autorelease pool page corrupted

Whenever I am using ASIHTTPRequest for making webservice calls I am randomly getting the following crash:

autorelease pool page 0x9418000 corrupted  
  magic a1a1a100 4f545541 454c4552 21455341  
  pthread 0xb0103000 

My code is ARC-fied and used -fno-objc-arc for the .m files of ASIHTTP class.

Does anybody have an idea about this or did anybody face this kind of issue before? Thanks in advance!


This likely indicates that you're stomping memory somewhere else. I'd start by turning on memory diagnostics and looking for mistakes. The most likely place to cause these kinds of mistakes is in C code, particularly when using C arrays or C strings. You're probably writing outside of your allocated memory, or writing into memory after you freed it.

There have at times been compiler bugs that would cause this kind of problem, but these are very rare, and I would strongly suspect your code first.


As Rob pointed out, this is likely an indication that you're misusing memory elsewhere. To turn on memory management diagnostics as of Xcode 8:

  • Click the scheme menu in Xcode and choose "Edit Scheme..." at the bottom.
  • In the Run step, go to the Diagnostics tab.
  • Under Memory Management, turn on all four options. I generally find Guard Malloc to uncover the most problems but they can all be useful.
  • 链接地址: http://www.djcxy.com/p/12624.html

    上一篇: 弱引用和`OutOfMemoryError`s

    下一篇: 自动释放池页面已损坏