Skip to content

Commit

Permalink
Add java.nio and java.awt to reflection allowlist
Browse files Browse the repository at this point in the history
  • Loading branch information
ctrueden committed Feb 16, 2024
1 parent 99ab91b commit 2a3f10c
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions configs/fiji.toml
Original file line number Diff line number Diff line change
Expand Up @@ -139,14 +139,27 @@ jvm-args = [
# net.imagej.patcher.LegacyInjector uses ClassLoader.findLoadedClass
# javassist.util.proxy.SecurityActions uses ClassLoader.defineClass
'JAVA:9+|--add-opens=java.base/java.lang=ALL-UNNAMED',

# For org.apache.arrow - TODO: document exactly why
'JAVA:9+|--add-opens=java.base/java.nio=ALL-UNNAMED',

# org.scijava.util.SizeableArrayList uses ArrayList.size
'JAVA:9+|--add-opens=java.base/java.util=ALL-UNNAMED',

# com.jogamp.nativewindow.awt.AppContextInfo uses sun.awt.AppContext
'JAVA:9+|--add-opens=java.desktop/sun.awt=ALL-UNNAMED',

# ini.trakem2.Project.openFSProject uses javax.swing.JTree.expandedState
'JAVA:9+|--add-opens=java.desktop/javax.swing=ALL-UNNAMED',

# HACK: For fiji.debugging.Object_Inspector
# The Object_Inspector could end up reflecting anything, so this doesn't
# make it work in all cases, but it helps for inspecting AWT/Swing windows.
'JAVA:9+|--add-opens=java.desktop/java.awt=ALL-UNNAMED',

# sc.fiji.compat.DefaultFijiService uses XToolkit.awtAppClassName
'JAVA:9+|OS:LINUX|--add-opens=java.desktop/sun.awt.X11=ALL-UNNAMED',

# TODO: document where this happens on macOS.
'JAVA:9+|OS:MACOSX|--add-opens=java.desktop/com.apple.eawt=ALL-UNNAMED',

Expand Down

1 comment on commit 2a3f10c

@imagesc-bot
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This commit has been mentioned on Image.sc Forum. There might be relevant details there:

https://forum.image.sc/t/jaunch-a-new-java-launcher-test-fiji-with-java-21/92058/41

Please sign in to comment.