Summary: | Java.executeJava should install default Permissions and check ExitException code when failonerror=false for non forked calls | ||
---|---|---|---|
Product: | Ant | Reporter: | Evan <apache> |
Component: | Core tasks | Assignee: | Ant Notifications List <notifications> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | eeaston, jglick |
Priority: | P2 | ||
Version: | 1.6.1 | ||
Target Milestone: | 1.7.0 | ||
Hardware: | All | ||
OS: | All | ||
Bug Depends on: | 34229 | ||
Bug Blocks: |
Description
Evan
2005-02-02 17:19:26 UTC
The reason the security stuff only went in when failonerror was true was backwards compatibility; once a security manager is in place, things behave differently. There is nothing to stop you adding your own <permissions> entry inside to get the behaviour you want; the failonerror thing is just a shortcut, you indicating the code exits with system.exit. I know this is somewhat unsatisfactory, and am leaving this bug open. The protection is now also added when failonerror="false". This is rather unfortunate as it eliminates one of the only (admittedly poor) workarounds for http://www.netbeans.org/issues/show_bug.cgi?id=47645 and makes the bug be triggered on any <java fork="false">. The basic problem is that Ant should not be setting a global security manager without consulting an embedding environment first. I will file a separate bug for that when I get a chance. |