IPhone: Can I leak an application to harm other applications?

So, I finished writing my first iPhone app, and I sent it to a group of beta testers. Everyone is happy, except for this guy who noticed that after starting my application, another application no longer starts.

Not knowing too much about memory management, I began to study Leaks graphs in tools and noticed that there were some leaks in my application.

Three questions:

  • Are leaks always bad? The largest leak is 15 thousand. On the allocated memory of 5.1 MB.
  • Will Apple abandon my app due to leaks?
  • Isn't all memory automatically freed up as soon as my application terminates? Maybe my leaky application is harmful to other applications?

Thanks Sjakelien

+4
source share
5 answers

Each application should run in its own “sandbox” and by design should not affect any other application installed on the phone. If your reviewer has found a case where your application really influenced another application, this is definitely not your fault, although I would like to know how it was done;).

My guess, however, is that your reviewer application has completely broken down completely regardless of your application, and he / she falsely attributes the error to your application. Ask him to try to reproduce the problem (uninstall both applications, install another application, install the application).

+8
source

that the other two answers say that I agree, but no one answered the first question ("Are there leaks always bad") directly. I would say yes. it is true that your program can work with them for a long period of time without any problems. and the OS should clear the memory after completion (if no error was detected in the OS, as mentioned earlier). but ultimately the leak will become a problem for someone at some point when they will work long enough. also, even if this does not become a problem, it is probably best to always fix the memory leaks that you are aware of.

+5
source

Any leak that persists outside of your application is an OS error and therefore an Apple issue.

It would be unfair to reject your application on this basis.
I don’t know if it was comfortable for you.

For recording, my application causes a leak in the media server.
In 3.0GM, the leak is a little less.

Another misuse of the API with the mediaserverd error.
Also 3.0GM. Nastya. I would prefer an error code, however, this could theoretically be used to fix a leak.

+3
source

It depends on what kind of “memory” you are leaking. Do you use file storage space for caching? Theoretically, it is possible that you have used enough space, another application cannot start, because it requires a certain amount of free space.

If we are talking about physical memory, then no. When your application is dead, it is dead. You can ask them to reboot the device and see if they have the same problem.

+1
source

Apple favors apps with memory leaks.

However, we carefully check that none of "our code" leaks before sending it to Apple, because users do not like it when the application suddenly closes on them. I say "our code" because there are memory leaks in the structure that you do not. Thus, Apple claims apps with memory leaks.

In addition, I doubt that your application has adversely affected another user application. I have not seen this behavior.

+1
source

All Articles