< prev index next >

src/jdk.compiler/share/classes/com/sun/tools/javac/file/PathFileObject.java

Print this page

        

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 2009, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2009, 2015, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as
  * published by the Free Software Foundation.  Oracle designates this

@@ -102,12 +102,12 @@
     public static PathFileObject createJRTPathFileObject(BaseFileManager fileManager,
             final Path path) {
         return new PathFileObject(fileManager, path) {
             @Override
             public String inferBinaryName(Iterable<? extends Path> paths) {
-                // use subpath to ignore the leading component containing the module name
-                return toBinaryName(path.subpath(1, path.getNameCount()));
+                // use subpath to ignore the leading /modules/MODULE-NAME
+                return toBinaryName(path.subpath(2, path.getNameCount()));
             }
         };
     }
 
     /**
< prev index next >