Skip to content

Commit

Permalink
Fix memory 'leak' (fix #240)
Browse files Browse the repository at this point in the history
  • Loading branch information
ireun committed Dec 9, 2024
1 parent 560c930 commit 3dbee78
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@
import org.openstreetmap.josm.plugins.mapillary.utils.MapillarySequenceUtils;
import org.openstreetmap.josm.plugins.mapillary.utils.MapillaryUtils;
import org.openstreetmap.josm.plugins.mapillary.utils.OffsetUtils;
import org.openstreetmap.josm.spi.preferences.Config;
import org.openstreetmap.josm.tools.ExifReader;
import org.openstreetmap.josm.tools.JosmRuntimeException;
import org.openstreetmap.josm.tools.Logging;
Expand All @@ -83,8 +84,8 @@
*/
public class MapillaryImageEntry
implements IImageEntry<MapillaryImageEntry>, BiConsumer<Long, Collection<ImageDetection<?>>> {
private static final CacheAccess<Long, MapillaryImageEntry> CACHE = JCSCacheManager
.getCache("mapillary:mapillaryimageentry");
private static final CacheAccess<Long, MapillaryImageEntry> CACHE =
JCSCacheManager.getCache("mapillary:mapillaryimageentry", Config.getPref().getInt("mapillary.jcs.cache.max_objects_in_memory", 10), 0, null);
private static final String MESSAGE_SEPARATOR = " — ";
private INode image;
private final List<ImageDetection<?>> imageDetections = new ArrayList<>();
Expand Down

0 comments on commit 3dbee78

Please sign in to comment.