From af1c6835c8f43e93cd546b0dfcec0ee2415a0b23 Mon Sep 17 00:00:00 2001 From: deanhiller Date: Sat, 27 Jan 2007 14:02:11 +0000 Subject: fix a bug where files in the default package will cause in RuntimeException to be thrown. git-svn-id: file:///home/sven/projects/JOGL/temp/ant-contrib/svn/ant-contrib-code/trunk/ant-contrib@75 32d7a393-a5a9-423c-abd3-5d954feb1f2f --- src/java/net/sf/antcontrib/design/Design.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/java/net/sf/antcontrib/design/Design.java b/src/java/net/sf/antcontrib/design/Design.java index bd40a48..a68aebe 100644 --- a/src/java/net/sf/antcontrib/design/Design.java +++ b/src/java/net/sf/antcontrib/design/Design.java @@ -225,8 +225,12 @@ public class Design { currentAliasPackage.setUsed(true); } log.log(" class="+className, Project.MSG_VERBOSE); - - if(!className.startsWith(currentPackageName)) + + if(packageName.equals(Package.DEFAULT)) { + if(className.contains(".")) { + throw new RuntimeException("Internal Error"); + } + } else if(!className.startsWith(currentPackageName)) throw new RuntimeException("Internal Error"); if(!currentAliasPackage.getNeedDepends()) -- cgit v1.2.3