Using JNA within GlassFish Application Client Container (GF ACC)

255 views
Skip to first unread message

ka...@quipsy.de

unread,
Jul 18, 2011, 10:21:48 AM7/18/11
to Java Native Access
I am using JNA inside of a client application running inside of
GlassFish v3's Application Client Container.

In GFv2ur2 this was working really well. I just copied jna.jar and
platform.jar into /lib inside of my EAR, and could use it.

In GFv3.1.x this is not working anymore. When I try to call
Advapi32Util.registryKeyExists at runtime it says "IllegalAccess":
tried to access method com.sun.jna.Pointer.<init>(J)V from class
com.sun.jna.platform.win32.WinReg$HKEY.

Has anybody an idea how I can convince the GF ACC that it shall not
complain but just execute the call?

Timothy Wall

unread,
Jul 19, 2011, 10:30:36 AM7/19/11
to jna-...@googlegroups.com
Make sure both jna.jar and platform.jar are from the same release, that you're not mixing between two versions of JNA.
Reply all
Reply to author
Forward
0 new messages