1. jni helper cleanup