Changeset 10938 in josm for trunk/src/org/openstreetmap/josm/data/cache/BufferedImageCacheEntry.java
- Timestamp:
- 2016-09-03T12:37:39+02:00 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/cache/BufferedImageCacheEntry.java
r10723 r10938 18 18 // transient to avoid serialization, volatile to avoid synchronization of whole getImage() method 19 19 private transient volatile BufferedImage img; 20 private transient volatile boolean writtenToDisk;21 20 // we need to have separate control variable, to know, if we already tried to load the image, as img might be null 22 21 // after we loaded image, as for example, when image file is malformed (eg. HTML file) … … 79 78 } 80 79 out.writeObject(this); 81 // ugly hack to wait till element will get to disk to clean the memory82 writtenToDisk = true;83 80 84 81 if (img != null) {
Note:
See TracChangeset
for help on using the changeset viewer.