karlpauls commented on code in PR #154:
URL: https://github.com/apache/felix-dev/pull/154#discussion_r882438910


##########
framework/src/main/java/org/apache/felix/framework/cache/DirectoryContent.java:
##########
@@ -48,16 +49,27 @@ public class DirectoryContent implements Content
     private final File m_rootDir;
     private final File m_dir;
     private Map m_nativeLibMap;
+    private final String m_canonicalRoot;
 
     public DirectoryContent(Logger logger, Map configMap,
-        WeakZipFileFactory zipFactory, Object revisionLock, File rootDir, File 
dir)
+                            WeakZipFileFactory zipFactory, Object 
revisionLock, File rootDir, File dir)
     {
         m_logger = logger;
         m_configMap = configMap;
         m_zipFactory = zipFactory;
         m_revisionLock = revisionLock;
         m_rootDir = rootDir;
         m_dir = dir;
+        String canonicalPath = null;
+        try {
+            canonicalPath = 
BundleCache.getSecureAction().getCanonicalPath(m_dir);
+        } catch (IOException e) {
+            throw new UncheckedIOException(e);
+        }
+        if (!canonicalPath.endsWith(File.separator)) {
+            canonicalPath = canonicalPath + "/";

Review Comment:
   @chadlwilson, yes, I think you are right - I'll create a JIRA issue.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to