8268855: Cleanup name handling in the Thread class and subclasses

Reviewed-by: lfoltan, coleenp
This commit is contained in:
David Holmes 2021-06-24 23:58:32 +00:00
parent c79034e0c9
commit 08ee7ae672
16 changed files with 71 additions and 51 deletions

View file

@ -2279,7 +2279,7 @@ C2V_VMENTRY_PREFIX(jboolean, attachCurrentThread, (JNIEnv* env, jobject c2vm, jb
JavaVMAttachArgs attach_args;
attach_args.version = JNI_VERSION_1_2;
attach_args.name = thread->name();
attach_args.name = const_cast<char*>(thread->name());
attach_args.group = NULL;
JNIEnv* peerJNIEnv;
if (runtime->GetEnv(thread, (void**) &peerJNIEnv, JNI_VERSION_1_2) == JNI_OK) {