]> source.dussan.org Git - aspectj.git/commitdiff
248814: perclassloaderdumpdir
authoraclement <aclement>
Sat, 27 Sep 2008 17:32:47 +0000 (17:32 +0000)
committeraclement <aclement>
Sat, 27 Sep 2008 17:32:47 +0000 (17:32 +0000)
loadtime/src/org/aspectj/weaver/loadtime/ClassLoaderWeavingAdaptor.java
loadtime/src/org/aspectj/weaver/loadtime/DefaultWeavingContext.java

index 10eaefbabc181940dcf98903babbdf9276b9c670..9bc3dd650a11726b9e82242e0a2a4cccf3e5ef32 100644 (file)
@@ -735,7 +735,7 @@ public class ClassLoaderWeavingAdaptor extends WeavingAdaptor {
        protected String getDumpDir() {
                if (dumpDirPerClassloader) {
                        StringBuffer dir = new StringBuffer();
-                       dir.append("_ajdump").append(File.separator).append(weavingContext.getClassLoaderName());
+                       dir.append("_ajdump").append(File.separator).append(weavingContext.getId());
                        return dir.toString();
                } else {
                        return super.getDumpDir();
index 6d1a878e468ca4bfdd8d7480e9034db3314bf1a6..19feeb393a7764d663304e63baa22e02bea4f7e1 100644 (file)
@@ -84,7 +84,9 @@ public class DefaultWeavingContext implements IWeavingContext {
                if (shortName == null) {
                        shortName = getClassLoaderName().replace('$','.');
                        int index = shortName.lastIndexOf(".");
-                       shortName = shortName.substring(index + 1);
+                       if (index!=-1) {
+                               shortName = shortName.substring(index + 1);
+                       }
                }
                return shortName;
        }