arranged for per-host classloaders
[org.ibex.jinetd.git] / src / org / ibex / jinetd / Main.java
index 037527e..cdbba4b 100644 (file)
@@ -69,6 +69,14 @@ public class Main {
         System.exit(0);
     }
 
+    private static TreeClassLoader rootClassLoader;
+    public static TreeClassLoader getRootClassLoader() {
+        if (rootClassLoader==null)
+            rootClassLoader = new TreeClassLoader(new File(ROOT + File.separatorChar + "lib"),
+                                                  Main.class.getClassLoader());
+        return rootClassLoader;
+    }
+
     public static void main(String[] s) throws Exception {
         init();
         Root root = new Root(ROOT);