mirror of
https://github.com/nextcloud/android.git
synced 2024-11-30 08:25:21 +03:00
Fix for NPE caused by Log.d in ThumbnailsCacheManager
Log.d does not like null. Fixes #4542 Signed-off-by: Chris Narkiewicz <hello@ezaquarii.com>
This commit is contained in:
parent
6f8c91e446
commit
ed704c632e
1 changed files with 2 additions and 1 deletions
|
@ -74,6 +74,7 @@ import java.io.InputStream;
|
||||||
import java.lang.ref.WeakReference;
|
import java.lang.ref.WeakReference;
|
||||||
import java.net.URLEncoder;
|
import java.net.URLEncoder;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.Locale;
|
||||||
|
|
||||||
import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
|
import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
|
||||||
|
|
||||||
|
@ -142,7 +143,7 @@ public final class ThumbnailsCacheManager {
|
||||||
mThumbnailCache = new DiskLruImageCache(diskCacheDir, DISK_CACHE_SIZE, mCompressFormat,
|
mThumbnailCache = new DiskLruImageCache(diskCacheDir, DISK_CACHE_SIZE, mCompressFormat,
|
||||||
mCompressQuality);
|
mCompressQuality);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
Log_OC.d(TAG, e.getMessage());
|
Log_OC.d(TAG, String.format(Locale.US, "Disk cache init failed: %s", e.getMessage()));
|
||||||
mThumbnailCache = null;
|
mThumbnailCache = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue