The JVMTI internal JvmtiHandshake and JvmtiUnitedHandshakeClosure classes were introduced in the JDK 22 to unify/simplify the JVMTI functions supporting implementation of the virtual threads. The JVMTI internal function JvmtiEnvThreadState::reset_current_location should be also refactored on the base of JvmtiHandshake/JvmtiUnitedHandshakeClosure classes.