mirror of
https://github.com/geometer/FBReaderJ.git
synced 2025-10-05 10:49:24 +02:00
fixed NPE
This commit is contained in:
parent
2a08b9fd31
commit
45b4890d64
1 changed files with 3 additions and 0 deletions
|
@ -496,6 +496,9 @@ public final class Library {
|
|||
private static final WeakReference<ZLImage> NULL_IMAGE = new WeakReference<ZLImage>(null);
|
||||
|
||||
public static ZLImage getCover(ZLFile file) {
|
||||
if (file == null) {
|
||||
return null;
|
||||
}
|
||||
synchronized(ourCoverMap) {
|
||||
final String path = file.getPath();
|
||||
final WeakReference<ZLImage> ref = ourCoverMap.get(path);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue