Receiving memory warning in my iphone application. - iphone

I am using ios camera and upload the image to our server when i cross more then 40 images i got memory warning, also my application quits automatically, i cant to solve this problem anybody help me how to resolve this issue.
Thanks in advance.

check out these links:
I received memory warning and my app crashed. Does it kill autorelease objects?
How to catch warning in app for Crash reporting: Received Memory Warning
Memory warning and crash: how to handle it
http://www.neglectedpotential.com/2012/04/testing-memory-warnings-in-ios-applications/

Related

malloc: Heap corruption detected, free list is damaged

My app is running fine till iOS 12. After updating my iOS version to iOS 13 beta, the app is crashing in random places and with the same error. Following is the Xcode console.
MyApp(618,0x10cebd800) malloc: Heap corruption detected, free list is damaged at 0x28ea33ff0
*** Incorrect guard value: 5276115984
MyApp(618,0x10cebd800) malloc: *** set a breakpoint in malloc_error_break to debug
Any lead to debug/solve this will be appreciated. Thanks in advance.
As you stated, your app crashes in random places, I would also add in random times, this might be a clear sign of a retain cycle (could be because you forgot to capture a weak self inside a closure) somewhere in your code that led the heap to get saturated. At this point the system will certainly decide to terminate you app process and free up memory for other tasks.
In order to see this more clearly, try to profile your app (launch it with Instruments) with the Leaks profiling template, play around with the app and try to reproduce the scenario that led to the crash until it gets stopped (terminated), at this point Instruments will provide you with more details.

Iphone App Memory leak due to UIKeyboardInputManager

Memory leaks occurred in my app due to UIKeyboardInputManager. How can i solve ? please help me
If you are using the simulator, donĀ“t worry. It is not a good indicator of how memory would work on a real device. Repeat your test with a real device.
Furthermore, it seems there is a bug with UITextField memory management.

crashing application in simulator

I am new to iPhone SDK. I have activated zombie and guard Malloc also. When I am playing with my application for 10 or 15 minutes, it crashes.
Now when my application crashed, console gives me some useful output, but I am not able to understand what it wants to say. So please help me.
Here is output of console :
GuardMalloc[GNG-4042]: Failed to VM allocate 400000 bytes
GuardMalloc[GNG-4042]: Explicitly trapping into debugger!!!
Now what should i do? Please help me. Thanking you.
Try profiling your code with the Instruments tool of Xcode to detect and fix memory leaks. Here is a good tutorial on using this tool: http://www.raywenderlich.com/2696/how-to-debug-memory-leaks-with-xcode-and-instruments-tutorial

Terminating in response to SpringBoard's termination

I got this error in console .can any one tell me What kind of error is this.."Terminating in response to SpringBoard's termination".
that's when the app gets terminated by the ios for high memory usage or the springboard crashes( springboard is application that manages the other applications...aka..home screen), or you quit the app
if you have the device jailbroken you can get that pretty often
did you get the springboard restart alert?
I had the same problem and accidentally it appeared that my code was still trying to do some action (in my case it was generating data for AudioUnit buffer) when I was quitting my app. I have just quit this generating in dealloc method and all looks much better. No warning.

Iphone main thread crashes but app still running - "program received signal 0"

so when i'm running my app using XCode and I can see that my app gets "program received signal 0".
However , the background thread are still running. why is that ?
Second, I can't seem to find any solution to this problem.
I assumed it might be memory leak, but I see nothing special using LEAKS (instrument).
When I run the app on the device(without XCode) and then try to see the device crash inside the organizer, most of the times there is no log (I guess maybe because the app is still running and only the main thread crashed) and while there is a log, my app function are only hex addresses without names.
What other options do I have to solve this issues ?
Thanks!!
I've found that sometimes these errors are caused by trying to access deallocated memory. One great tool to debug these issues is NSZombieEnabled. Here's a link to a good explanation of how to use NSZombieEnabled: CocoaDev: NSZombieEnabled