- Timestamp:
- 2026-01-14T21:41:37+01:00 (43 hours ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/cache/JCSCacheManager.java
r19108 r19462 51 51 52 52 private static final AuxiliaryCacheFactory DISK_CACHE_FACTORY = getDiskCacheFactory(); 53 private static FileChannel cacheDirChannel; 53 54 private static FileLock cacheDirLock; 54 55 … … 118 119 Logging.warn("Cannot create cache dir lock file"); 119 120 } 120 cacheDirLock = FileChannel.open(cacheDirLockPath.toPath(), StandardOpenOption.WRITE).tryLock(); 121 cacheDirChannel = FileChannel.open(cacheDirLockPath.toPath(), StandardOpenOption.WRITE); 122 cacheDirLock = cacheDirChannel.tryLock(); 121 123 122 124 if (cacheDirLock == null) … … 220 222 */ 221 223 public static void shutdown() { 224 try { 225 if (cacheDirLock != null) 226 cacheDirLock.release(); 227 if (cacheDirChannel != null) 228 cacheDirChannel.close(); 229 } catch (IOException e) { 230 Logging.error(e); 231 } 222 232 JCS.shutdown(); 223 233 }
Note:
See TracChangeset
for help on using the changeset viewer.
