Files
Velocity/native/src/main/c/jni_util.c
2018-08-01 22:22:09 -04:00

12 lines
250 B
C

#include <jni.h>
#include "jni_util.h"
JNIEXPORT void JNICALL
throwException(JNIEnv *env, const char *type, const char *msg)
{
jclass klazz = (*env)->FindClass(env, type);
if (klazz != 0) {
(*env)->ThrowNew(env, klazz, msg);
}
}