mirror of
https://github.com/openjdk/jdk.git
synced 2026-07-29 12:23:39 +00:00
8372957: After JDK-8282441 JDWP might allow some invalid FrameIDs to be used
Reviewed-by: amenkov, sspitsyn
This commit is contained in:
parent
c432150397
commit
0bcef61a6d
@ -70,6 +70,7 @@ typedef struct ThreadNode {
|
||||
unsigned int popFrameEvent : 1;
|
||||
unsigned int popFrameProceed : 1;
|
||||
unsigned int popFrameThread : 1;
|
||||
unsigned int frameGeneration_accessed:1; /* true if frameGeneration accessed to produce a FrameID */
|
||||
EventIndex current_ei; /* Used to determine if we are currently handling an event on this thread. */
|
||||
jobject pendingStop; /* Object we are throwing to stop the thread (ThreadReferenceImpl.stop). */
|
||||
jint suspendCount; /* Number of outstanding suspends from the debugger. */
|
||||
@ -616,6 +617,7 @@ freeUnusedVThreadNode(JNIEnv *env, ThreadNode* node)
|
||||
!node->popFrameEvent &&
|
||||
!node->popFrameProceed &&
|
||||
!node->popFrameThread &&
|
||||
!node->frameGeneration_accessed &&
|
||||
node->pendingStop == NULL)
|
||||
{
|
||||
removeNode(node);
|
||||
@ -2683,6 +2685,7 @@ threadControl_getFrameGeneration(jthread thread)
|
||||
|
||||
if (node != NULL) {
|
||||
frameGeneration = node->frameGeneration;
|
||||
node->frameGeneration_accessed = JNI_TRUE;
|
||||
}
|
||||
}
|
||||
debugMonitorExit(threadLock);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user