You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bu...@apache.org on 2021/11/23 22:08:04 UTC

[Bug 65381] java task without fork=yes shows "WARNING: java.lang.System::setSecurityManager is deprecated and will be removed in a future release...." with jd17ea26

https://bz.apache.org/bugzilla/show_bug.cgi?id=65381

--- Comment #7 from Arjan Tijms <ar...@gmail.com> ---
> note that JDK 17 only deprecates the SecurityManager for future removal and except for the WARNING message in the STDERR nothing else changes in JDK 17, functionality wise

In JDK 18 this is no longer the case. Instead of an error message, an exception
is thrown, e.g:

java.lang.UnsupportedOperationException: The Security Manager is deprecated and
will be removed in a future release
     [java]     at
java.base/java.lang.System.setSecurityManager(System.java:411)
     [java]     at
org.apache.tools.ant.types.Permissions.setSecurityManager(Permissions.java:103)
     [java]     at
org.apache.tools.ant.taskdefs.ExecuteJava.run(ExecuteJava.java:216)
     [java]     at
org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:155)

This breaks the builds, obviously.

-- 
You are receiving this mail because:
You are the assignee for the bug.