From bd75b5af0161013b26e2feda9cfcc1e152926071 Mon Sep 17 00:00:00 2001 From: Christopher Vogt Date: Sat, 26 Mar 2016 16:20:50 -0400 Subject: Early classloading improvements - Changed launcher to already load zinc - use code generation to generate necessary dependencies - changed resolver to linearize dependency DAG in a way that guarantees that every transitive dependee of a node in the DAG is a transitive dependee of that node in the linear sequence - move exit code trapping code into java so it can be used for zinc early There seems to be a bug in this version, where CBT crashes about half of the time with a "object is not an instance of declaring class" Exception during running the task from the build object via reflection. --- nailgun_launcher/TrapSecurityManager.java | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 nailgun_launcher/TrapSecurityManager.java (limited to 'nailgun_launcher/TrapSecurityManager.java') diff --git a/nailgun_launcher/TrapSecurityManager.java b/nailgun_launcher/TrapSecurityManager.java new file mode 100644 index 0000000..ed00582 --- /dev/null +++ b/nailgun_launcher/TrapSecurityManager.java @@ -0,0 +1,19 @@ +package cbt; +import java.security.*; +public class TrapSecurityManager extends SecurityManager{ + public void checkPermission( Permission permission ){ + /* + NOTE: is it actually ok, to just make these empty? + Calling .super leads to ClassNotFound exteption for a lambda. + Calling to the previous SecurityManager leads to a stack overflow + */ + } + public void checkPermission( Permission permission, Object context ){ + /* Does this methods need to be overidden? */ + } + @Override + public void checkExit( int status ){ + super.checkExit(status); + throw new TrappedExitCode(status); + } +} -- cgit v1.2.3