Hi, I have a small doubt.
I have one file handler, which is created by opening a file on SD card. If i listen to SD card unmount broad cast. Can i close the file handler without my appliaction is being closed by android system ? Is there any grace period of time when we receive SD card unmount broad cast to close any file handlers related to SD card? Thanks in advance ... On Dec 21, 3:52 am, Dianne Hackborn <hack...@android.com> wrote: > Yes when the sd card is unmounted any processes that have open files on it > need to be killed so the filesystem can be cleanly shut down. > > You can listen for the external storage status broadcasts as per > android.os.Environment to find out when it is being unmounted. > > > > > > On Mon, Dec 20, 2010 at 11:53 AM, John <jo-d...@hotmail.com> wrote: > > My app has an open file handle on the sdcard. If it's plugged into the > > PC via USB, I can mount the sdcard on the PC and my app closes. > > > The logcat info has this line: KillProcessesWithOpenFiles /sdcard > > > Is this expected behavior? Is there some event I can capture to > > gracefully close? > > > -- > > You received this message because you are subscribed to the Google > > Groups "Android Developers" group. > > To post to this group, send email to android-developers@googlegroups.com > > To unsubscribe from this group, send email to > > android-developers+unsubscr...@googlegroups.com<android-developers%2bunsubscr...@googlegroups.com> > > For more options, visit this group at > >http://groups.google.com/group/android-developers?hl=en > > -- > Dianne Hackborn > Android framework engineer > hack...@android.com > > Note: please don't send private questions to me, as I don't have time to > provide private support, and so won't reply to such e-mails. All such > questions should be posted on public forums, where I and others can see and > answer them.- Hide quoted text - > > - Show quoted text - -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en