Skip to content

Commit

Permalink
[FLINK-23346] Avoid core dump when rethrowing the exception
Browse files Browse the repository at this point in the history
  • Loading branch information
Zakelly authored and mayuehappy committed Jun 13, 2024
1 parent 96705d2 commit 2f19182
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion java/rocksjni/flink_compactionfilterjni.cc
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@ class JniCallbackBase : public ROCKSDB_NAMESPACE::JniCallback {
protected:
inline void CheckAndRethrowException(JNIEnv* env) const {
if (env->ExceptionCheck()) {
jthrowable obj = env->ExceptionOccurred();
env->ExceptionDescribe();
env->Throw(env->ExceptionOccurred());
env->Throw(obj);
}
}
};
Expand Down

0 comments on commit 2f19182

Please sign in to comment.