< prev index next >

test/hotspot/jtreg/vmTestbase/nsk/jvmti/AttachOnDemand/attach041/attach041Agent00.cpp

Print this page
rev 51942 : [mq]: refactor

@@ -50,20 +50,20 @@
     jthreadGroup* groups = NULL;
     jvmtiThreadGroupInfo groupInfo;
     int i;
     char threadGroupName[MAX_STRING_LENGTH];
 
-    if(!NSK_JVMTI_VERIFY(NSK_CPP_STUB3(GetThreadGroupInfo, jvmti, group, &groupInfo))) {
+    if(!NSK_JVMTI_VERIFY(jvmti->GetThreadGroupInfo(group, &groupInfo))) {
         return 0;
     }
 
     strcpy(threadGroupName, groupInfo.name);
     nsk_jvmti_aod_deallocate(jvmti, (unsigned char*)groupInfo.name);
 
     NSK_DISPLAY3("%s: trying to find thread '%s' in group '%s'\n", agentName, threadNameToFind, threadGroupName);
 
-    if(!NSK_JVMTI_VERIFY(NSK_CPP_STUB6(GetThreadGroupChildren, jvmti, group, &threadsCount, &threads, &groupsCount, &groups))) {
+    if(!NSK_JVMTI_VERIFY(jvmti->GetThreadGroupChildren(group, &threadsCount, &threads, &groupsCount, &groups))) {
         return 0;
     }
 
     for (i = 0; i < threadsCount; i++) {
         char threadName[MAX_STRING_LENGTH];

@@ -116,11 +116,11 @@
         int threadWasFound = 0;
         jint groupsCount = 0;
         jthreadGroup *topGroups;
         int i;
 
-        if(!NSK_JVMTI_VERIFY(NSK_CPP_STUB3(GetTopThreadGroups, jvmti, &groupsCount, &topGroups))) {
+        if(!NSK_JVMTI_VERIFY(jvmti->GetTopThreadGroups(&groupsCount, &topGroups))) {
             NSK_COMPLAIN1("%s: failed to get top thread groups\n", agentName);
             nsk_jvmti_aod_disableEventAndFinish(agentName, JVMTI_EVENT_THREAD_START, 0, jvmti, jni);
             return;
         }
 

@@ -170,11 +170,11 @@
     if (!NSK_VERIFY((jvmti = nsk_jvmti_createJVMTIEnv(vm, reserved)) != NULL))
         return JNI_ERR;
 
     memset(&eventCallbacks,0, sizeof(eventCallbacks));
     eventCallbacks.ThreadStart = threadStartHandler;
-    if (!NSK_JVMTI_VERIFY(NSK_CPP_STUB3(SetEventCallbacks, jvmti, &eventCallbacks, sizeof(eventCallbacks))) ) {
+    if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))) ) {
         return JNI_ERR;
     }
 
     if (!(nsk_jvmti_aod_enableEvent(jvmti, JVMTI_EVENT_THREAD_START))) {
         return JNI_ERR;
< prev index next >