fix jni_mate_sw.c memory free bugs