From ad8dd9aa64a2d2a5a01a29aff84573289ba9300f Mon Sep 17 00:00:00 2001 From: Costin Manolache Date: Thu, 22 Aug 2002 17:34:06 +0000 Subject: [PATCH] Add an extra attempt to load tools.jar git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@273244 13f79535-47bb-0310-9956-ffa450edef68 --- .../ant/taskdefs/compilers/CompilerAdapterFactory.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/main/org/apache/tools/ant/taskdefs/compilers/CompilerAdapterFactory.java b/src/main/org/apache/tools/ant/taskdefs/compilers/CompilerAdapterFactory.java index 06781ce22..7548e4b2d 100644 --- a/src/main/org/apache/tools/ant/taskdefs/compilers/CompilerAdapterFactory.java +++ b/src/main/org/apache/tools/ant/taskdefs/compilers/CompilerAdapterFactory.java @@ -173,8 +173,13 @@ public class CompilerAdapterFactory { Class.forName("com.sun.tools.javac.Main"); return true; } catch (ClassNotFoundException cnfe) { - return false; + try { + CompilerAdapterFactory.class.getClassLoader().loadClass( "com.sun.tools.javac.Main" ); + return true; + } catch (ClassNotFoundException cnfe2) { + } } + return false; } /**