mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-11-23 18:36:50 +01:00
fix crash in FileUTils.copyURItoFile() if source and destination are the same file.
This allows to install pbw files from the pbw-cache manually though a file manager.
This commit is contained in:
parent
804621aa14
commit
8b87e97f51
@ -6,6 +6,7 @@
|
||||
* Pebble: Support installing .pbl (language files) on firmware 3.x
|
||||
* Pebble: Correct setting the timezone on firmware 3.x (pebble expects the "ID" eg. Europe/Berlin)
|
||||
* Pebble: Show correct icon for activity tracker and watchfaces in app installer (language and fw icons still missing)
|
||||
* Pebble: Fix crash when trying to install files though a file manager which are located inside the pbw-cache on firmware 3.x
|
||||
|
||||
####Version 0.6.8
|
||||
* Mi Band support for Firmware upgrade/downgrade on Mi Band 1A (white LEDs, no heartrate sensor)
|
||||
|
@ -48,6 +48,10 @@ public class FileUtils {
|
||||
}
|
||||
|
||||
public static void copyURItoFile(Context ctx, Uri uri, File destFile) throws IOException {
|
||||
if (uri.getPath().equals(destFile.getPath())) {
|
||||
return;
|
||||
}
|
||||
|
||||
ContentResolver cr = ctx.getContentResolver();
|
||||
InputStream fin;
|
||||
try {
|
||||
|
Loading…
Reference in New Issue
Block a user