element-android-Github/matrix-sdk-android/src
SpiritCroc 4ef1f5c90f Avoid incomplete downloads in cache
Previously, when a download was aborted (e.g. due to a bad internet
connection), a partly downloaded file was remaining in cache, which
would then be delivered upon later requests.
This can lead e.g. to chats where images aren't loading.

To avoid this, first download files to a temporary file that is not the
final cache file, and only rename/move it on finish.

Note that if you already have broken downloads, you still need to clear
cache once to get rid of them after this commit, but it should not
occur anymore afterwards.
2021-07-10 11:12:15 +02:00
..
androidTest/java/org/matrix/android/sdk Dnd enhancement 2021-06-17 15:53:35 +02:00
debug/java/org/matrix/android/sdk/internal/network/interceptors Move interface to correct location 2021-01-07 18:28:05 +01:00
main Avoid incomplete downloads in cache 2021-07-10 11:12:15 +02:00
release/java/org/matrix/android/sdk/internal/network/interceptors Fix Copyright mention in SDK code 2020-10-08 15:04:55 +02:00
sharedTest/java/org/matrix/android/sdk/test/shared Fix Copyright mention in SDK code 2020-10-08 15:04:55 +02:00
test/java/org/matrix/android/sdk Use Junit import 2021-05-04 10:50:31 +02:00