Skip to content

Commit

Permalink
ignore UnsupportedOperationException thrown by jdk>18 zhen trying to …
Browse files Browse the repository at this point in the history
…setup the SystemExitSecurityManager (fixes #1455)
  • Loading branch information
vboulaye committed Jun 10, 2024
1 parent f3a5c50 commit 16bde2b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/fitnesse/slim/instructions/SystemExitSecurityManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@ private static void tryUpdateSecurityManager(SecurityManager securityManager) {
System.setSecurityManager(securityManager);
} catch (SecurityException e) {
System.err.println("Security manager could not be updated");
} catch (UnsupportedOperationException e) {
System.err.println("Security manager could not be updated. If you are usin a JDK version >=18, you need to set " +
"-Djava.security.manager=allow to allow this. Or use -Dprevent.system.exit=false to disable this feature inside " +
"fitnesse. Exception was :" + e.getMessage());
}
}

Expand Down

0 comments on commit 16bde2b

Please sign in to comment.