On Feb 17, 4:27 pm, guich <[email protected]> wrote: > Hi, > > When the user press the home key, the onPause method is called. At > this time, the application is supposed to save its state so it can be > properly recovered later. > > However, and if the state is taking too much time? For example, > issuing a closeAllNetworkConnections that was waiting a feedback from > the server, or just if the amount of information we're writting to > disk is a lot of info... what would happen? > > In my tests, i'm getting from 300-500 ms of time until the process is > killed. > > Is there a safer place to put a "save everything and quit" code so > that it can safely save everything before a "kill the activity" task > is issued? > > thanks! > > guich
in normal scenario your process is not killed everytime you finish your activity, it's killed only when OS is short of resources. if you observe your process to be killed by OS you dont have to care about system resources like Sockets - they are going to be closed by OS pskink -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

