pietrobraione / jbse

A symbolic Java virtual machine for program analysis, verification and test generation
http://pietrobraione.github.io/jbse/
GNU General Public License v3.0
101 stars 29 forks source link

sun.reflect.NativeMethodAccessorImpl.invoke0 implementation does not work if the method is native #29

Closed pietrobraione closed 4 years ago

pietrobraione commented 4 years ago

The current implementation of the native method sun.reflect.NativeMethodAccessorImpl.invoke0 in class jbse.algo.meta.Algo_SUN_NATIVEMETHODACCESSORIMPL_INVOKE0 assumes that the invoked method has bytecode and creates a frame for it. It should instead behave as the invoke* bytecodes and keep into account the overridings so it can also execute native method for which an implementation exists.

pietrobraione commented 4 years ago

Fixed by commit f725b57.