You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2022/11/01 08:45:19 UTC
[GitHub] [doris] zhangstar333 commented on a diff in pull request #13854: [javaudf](string) Fix string format in java udf
zhangstar333 commented on code in PR #13854:
URL: https://github.com/apache/doris/pull/13854#discussion_r1010212812
##########
be/src/vec/functions/function_java_udf.cpp:
##########
@@ -93,6 +93,10 @@ Status JavaFunctionCall::prepare(FunctionContext* context,
RETURN_IF_ERROR(SerializeThriftMsg(env, &ctor_params, &ctor_params_bytes));
jni_ctx->executor = env->NewObject(executor_cl_, executor_ctor_id_, ctor_params_bytes);
+
+ jbyte* pBytes = env->GetByteArrayElements(ctor_params_bytes, nullptr);
+ env->ReleaseByteArrayElements(ctor_params_bytes, pBytes, JNI_ABORT);
+ env->DeleteLocalRef(ctor_params_bytes);
Review Comment:
have checked udaf ctor new object as same way, would you add delete ref together
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org