If I'm constantly writing to a file located either in internal memory or SD card, there's a possibility that at some point there will be no more free space. This could throw an exception and create a corrupt file, depending on the way the file is written.
Can Android notify that it is running out of space, so that I can gracefully close the file?
The ACTION_DEVICE_STORAGE_LOW
intent does not work for the SD card as far as I know.