add ResultCode.fromInt

This commit is contained in:
Brenton Bostick
2023-01-31 12:40:59 -05:00
parent 056cef7292
commit 34ff813e2a
5 changed files with 39 additions and 65 deletions

View File

@ -656,6 +656,10 @@ JNIEXPORT jobject JNICALL Java_com_zerotier_sdk_Node_node_1init(
{
LOGE("Error creating Node: %d", rc);
resultObject = createResultObject(env, rc);
if (env->ExceptionCheck() || resultObject == NULL) {
return NULL;
}
if(node)
{
ZT_Node_delete(node);