Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@
import java.lang.ref.SoftReference;
import java.nio.channels.FileChannel;
import java.nio.channels.FileLock;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
Expand Down Expand Up @@ -589,6 +592,15 @@ private static File determineCacheDir(Map<String,?> configMap)
// Check to see if the cache directory is specified in the storage
// configuration property.
String cacheDirStr = (String) configMap.get(Constants.FRAMEWORK_STORAGE);

Path cacheDirPath = Paths.get("cacheDirStr");
try {
Path realCacheDirPath = cacheDirPath.toRealPath();
cacheDirStr = realCacheDirPath.toString();
} catch (IOException e) {
throw new RuntimeException(e);
}

// Get the cache root directory for relative paths; the default is ".".
String rootDirStr = (String) configMap.get(CACHE_ROOTDIR_PROP);
rootDirStr = (rootDirStr == null) ? CACHE_ROOTDIR_DEFAULT : rootDirStr;
Expand Down
Loading