8228998: Remove the testing against NSK_FALSE from tests

Remove the testing against NSK_FALSE from tests

Reviewed-by: cjplummer, sspitsyn
This commit is contained in:
Jean Christophe Beyler 2019-08-02 11:24:59 -07:00
parent f84231bfbd
commit 76b7c9a0ce
39 changed files with 339 additions and 361 deletions

View File

@ -114,27 +114,27 @@ getStaticObjField(const char* className, const char* objFieldName,
/* ============================================================================= */
static int prepare() {
static bool prepare() {
ExceptionCheckingJniEnvPtr ec_jni(jni);
mainThread = findThread(MAIN_THREAD_NAME);
if (!NSK_VERIFY(mainThread != NULL)) {
NSK_COMPLAIN1("<%s> thread not found\n", MAIN_THREAD_NAME);
return NSK_FALSE;
return false;
}
/* make thread accessable for a long time */
mainThread = ec_jni->NewGlobalRef(mainThread, TRACE_JNI_CALL);
startObject = getStaticObjField(DEBUGEE_CLASS_NAME, START_FIELD_NAME, OBJECT_FIELD_SIG);
if (!NSK_VERIFY(startObject != NULL))
return NSK_FALSE;
return false;
/*make object accessable for a long time*/
startObject = ec_jni->NewGlobalRef(startObject, TRACE_JNI_CALL);
endObject = getStaticObjField(DEBUGEE_CLASS_NAME, END_FIELD_NAME, OBJECT_FIELD_SIG);
if (!NSK_VERIFY(endObject != NULL))
return NSK_FALSE;
return false;
/*make object accessable for a long time*/
endObject = ec_jni->NewGlobalRef(endObject, TRACE_JNI_CALL);
@ -143,17 +143,16 @@ static int prepare() {
THREAD_FIELD_NAME,
THREAD_FIELD_SIG);
if (!NSK_VERIFY(debuggeeThread != NULL))
return NSK_FALSE;
return false;
/* make thread accessable for a long time */
debuggeeThread = ec_jni->NewGlobalRef(debuggeeThread, TRACE_JNI_CALL);
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
clean() {
static bool clean() {
ExceptionCheckingJniEnvPtr ec_jni(jni);
/* disable MonitorContendedEnter event */
@ -173,7 +172,7 @@ clean() {
debuggeeThread = NULL;
mainThread = NULL;
return NSK_TRUE;
return true;
}
/* ========================================================================== */
@ -224,10 +223,10 @@ changeCount(jvmtiEvent event, int *currentCounts) {
/* ============================================================================= */
int checkEvents(int step) {
bool checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -243,7 +242,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -277,14 +276,14 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value is 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
if (currentCounts[i] > 0) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -546,7 +545,7 @@ cbNewMonitorContendedEnter(jvmtiEnv* jvmti, JNIEnv* jni_env, jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_MONITOR_CONTENDED_ENTER)
@ -557,22 +556,22 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
static int enableEventList() {
static bool enableEventList() {
int i;
int result = NSK_TRUE;
bool result = true;
NSK_DISPLAY0("Enable events\n");
@ -588,18 +587,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -659,9 +657,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2004, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -69,12 +69,12 @@ showEventStatistics(int step /*int *currentCounts*/) {
* Testcase: check tested events.
* - check if expected events received for each method
*
* Returns NSK_TRUE if test may continue; or NSK_FALSE for test break.
* Returns true if test may continue; or false for test break.
*/
int checkEvents(int step) {
bool checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -93,7 +93,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
if (currentCounts[ind_start] != currentCounts[ind_fnsh]) {
@ -103,7 +103,7 @@ int checkEvents(int step) {
currentCounts[ind_start]);
NSK_COMPLAIN1("\tGARBAGE_COLLECTION_FINISH:\t%6d\n",
currentCounts[ind_fnsh]);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -132,14 +132,14 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
if (currentCounts[i] > 0) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -338,7 +338,7 @@ cbNewGarbageCollectionFinish(jvmtiEnv *jvmti_env) {
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_GARBAGE_COLLECTION_START)
@ -347,22 +347,22 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
static int enableEventList() {
static bool enableEventList() {
int i;
int result = NSK_TRUE;
bool result = true;
NSK_DISPLAY0("Enable events\n");
@ -378,18 +378,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -447,9 +446,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2004, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -67,10 +67,10 @@ showEventStatistics(int step) {
/* ========================================================================== */
int checkEvents(int step) {
bool checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -86,7 +86,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -113,7 +113,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
@ -122,7 +122,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -372,7 +372,7 @@ cbNewCompiledMethodUnload(jvmtiEnv *jvmti_env, jmethodID method,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_COMPILED_METHOD_LOAD)
@ -381,25 +381,25 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i;
int result = NSK_TRUE;
bool result = true;
NSK_DISPLAY0("Enable events\n");
@ -415,18 +415,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -485,9 +484,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2004, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -82,10 +82,10 @@ showEventStatistics(int step) {
/* ========================================================================== */
int checkEvents(int step) {
bool checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -101,7 +101,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -128,14 +128,14 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
if (currentCounts[i] > 0) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -382,7 +382,7 @@ cbNewNativeMethodBind(jvmtiEnv *jvmti_env, JNIEnv* jni_env,jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_NATIVE_METHOD_BIND)) {
@ -390,25 +390,25 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i;
int result = NSK_TRUE;
bool result = true;
NSK_DISPLAY0("Enable events\n");
@ -424,18 +424,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -492,9 +491,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2004, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -70,7 +70,7 @@ showEventStatistics(int step) {
int checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -86,7 +86,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -113,7 +113,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be non-negative\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
@ -122,7 +122,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -374,7 +374,7 @@ cbNewVMObjectAlloc(jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_VM_OBJECT_ALLOC)) {
@ -382,23 +382,23 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i, result;
@ -414,18 +414,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -479,9 +478,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2004, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -59,9 +59,9 @@ Java_nsk_jvmti_scenarios_events_EM02_em02t006_setTag(JNIEnv *env,
if (!NSK_JVMTI_VERIFY(jvmti->SetTag(object, tag))) {
NSK_COMPLAIN0("TEST FAILED: unable to set tag for a tested object\n");
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
static void
@ -86,7 +86,7 @@ showEventStatistics(int step) {
int checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -102,7 +102,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -129,7 +129,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
@ -137,7 +137,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -323,7 +323,7 @@ cbVMObjectAlloc(jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_OBJECT_FREE)) {
@ -331,23 +331,23 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i, result;
@ -363,18 +363,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -428,9 +427,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2004, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -71,7 +71,7 @@ showEventStatistics(int step) {
int checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -87,7 +87,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -114,7 +114,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
@ -122,7 +122,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -352,7 +352,7 @@ cbVMObjectAlloc(jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_SINGLE_STEP)) {
@ -360,23 +360,23 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i, result;
@ -392,18 +392,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -464,9 +463,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2004, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -68,7 +68,7 @@ showEventStatistics(int step) {
int checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -84,7 +84,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -113,7 +113,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
@ -121,7 +121,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -371,7 +371,7 @@ cbVMObjectAlloc(jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_EXCEPTION)
@ -380,23 +380,23 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i, result;
@ -412,18 +412,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -478,9 +477,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2004, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -69,7 +69,7 @@ showEventStatistics(int step) {
int checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -85,7 +85,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -115,7 +115,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
if (currentCounts[i] != NUMBER_OF_INVOCATIONS) {
@ -123,7 +123,7 @@ int checkEvents(int step) {
TranslateEvent(curr),
currentCounts[i],
NUMBER_OF_INVOCATIONS);
result = NSK_FALSE;
result = false;
}
}
} else {
@ -132,7 +132,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -378,7 +378,7 @@ cbVMObjectAlloc(jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_METHOD_ENTRY)
@ -387,23 +387,23 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i, result;
@ -419,18 +419,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -485,9 +484,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -73,7 +73,7 @@ showEventStatistics(int step) {
int checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -89,7 +89,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -121,14 +121,14 @@ int checkEvents(int step) {
TranslateEvent(curr),
currentCounts[i],
NUMBER_OF_INVOCATIONS);
result = NSK_FALSE;
result = false;
}
} else {
if (currentCounts[i] < 1) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
}
@ -138,7 +138,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -334,7 +334,7 @@ cbVMObjectAlloc(jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_FIELD_MODIFICATION)
@ -343,23 +343,23 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i, result;
@ -375,18 +375,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -441,9 +440,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -72,7 +72,7 @@ showEventStatistics(int step) {
int checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -88,7 +88,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -116,7 +116,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
} else {
if (currentCounts[i] != NUMBER_OF_INVOCATIONS) {
@ -124,7 +124,7 @@ int checkEvents(int step) {
TranslateEvent(curr),
currentCounts[i],
NUMBER_OF_INVOCATIONS);
result = NSK_FALSE;
result = false;
}
}
@ -134,7 +134,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -321,7 +321,7 @@ cbVMObjectAlloc(jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_BREAKPOINT)) {
@ -329,23 +329,23 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i, result;
@ -361,18 +361,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -426,9 +425,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -75,10 +75,10 @@ showEventStatistics(int step) {
/* ========================================================================== */
int checkEvents(int step) {
bool checkEvents(int step) {
int i;
jvmtiEvent curr;
int result = NSK_TRUE;
bool result = true;
int *currentCounts;
int isExpected = 0;
@ -94,7 +94,7 @@ int checkEvents(int step) {
default:
NSK_COMPLAIN1("Unexpected step no: %d\n", step);
return NSK_FALSE;
return false;
}
for (i = 0; i < JVMTI_EVENT_COUNT; i++) {
@ -123,14 +123,14 @@ int checkEvents(int step) {
TranslateEvent(curr),
currentCounts[i],
NUMBER_OF_INVOCATIONS);
result = NSK_FALSE;
result = false;
}
} else {
if (currentCounts[i] < 1) {
NSK_COMPLAIN2("Unexpected events number %7d for %s\n\texpected value must be greater than 1\n",
currentCounts[i],
TranslateEvent(curr));
result = NSK_FALSE;
result = false;
}
}
@ -140,7 +140,7 @@ int checkEvents(int step) {
NSK_COMPLAIN2("Unexpected event %s was sent %d times\n",
TranslateEvent(curr),
currentCounts[i]);
result = NSK_FALSE;
result = false;
}
}
}
@ -325,7 +325,7 @@ cbVMObjectAlloc(jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread,
/* ============================================================================= */
static int enableEvent(jvmtiEvent event) {
static bool enableEvent(jvmtiEvent event) {
if (nsk_jvmti_isOptionalEvent(event)
&& (event != JVMTI_EVENT_FRAME_POP)) {
@ -333,23 +333,23 @@ static int enableEvent(jvmtiEvent event) {
jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
} else {
if (!NSK_JVMTI_VERIFY(jvmti->SetEventNotificationMode(JVMTI_ENABLE, event, NULL))) {
NSK_COMPLAIN1("Unexpected error enabling %s\n",
TranslateEvent(event));
return NSK_FALSE;
return false;
}
}
return NSK_TRUE;
return true;
}
/**
* Enable or disable tested events.
*/
static int enableEventList() {
static bool enableEventList() {
int i, result;
@ -365,18 +365,17 @@ static int enableEventList() {
result = result && enableEvent(event);
}
if (result == NSK_FALSE) {
if (!result) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
}
/* ============================================================================= */
static int
setCallBacks(int step) {
static bool setCallBacks(int step) {
int i;
@ -430,9 +429,9 @@ setCallBacks(int step) {
}
if (!NSK_JVMTI_VERIFY(jvmti->SetEventCallbacks(&eventCallbacks, sizeof(eventCallbacks))))
return NSK_FALSE;
return false;
return NSK_TRUE;
return true;
}
/* ============================================================================= */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -117,7 +117,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
return JNI_ERR;
} else {
jvmtiCapabilities caps;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -81,7 +81,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -54,7 +54,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
return JNI_ERR;
} else {
jvmtiCapabilities caps;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -151,7 +151,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
memset(&caps, 0, sizeof(caps));
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -103,7 +103,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
memset(&caps, 0, sizeof(caps));
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -145,7 +145,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -146,7 +146,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -134,7 +134,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("#error Agent :: Failed to parse options.\n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -151,7 +151,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
memset(&caps, 0, sizeof(caps));
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
NSK_DISPLAY0("#error Agent :: Failed to parse options.\n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -55,7 +55,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options.\n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -57,7 +57,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
return JNI_ERR;
} else {
jvmtiCapabilities caps;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf(" Agent:: ## error agent Failed to parse options.\n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -75,7 +75,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options.\n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -76,7 +76,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -73,7 +73,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -73,7 +73,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -76,7 +76,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -77,7 +77,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -73,7 +73,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -75,7 +75,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -74,7 +74,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -71,7 +71,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -74,7 +74,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -74,7 +74,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -73,7 +73,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -74,7 +74,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -76,7 +76,7 @@ jint Agent_Initialize(JavaVM *vm, char *options, void *reserved) {
} else {
jvmtiCapabilities caps;
jvmtiEventCallbacks eventCallbacks;
if (nsk_jvmti_parseOptions(options) == NSK_FALSE) {
if (!nsk_jvmti_parseOptions(options)) {
nsk_printf("# error agent Failed to parse options \n");
return JNI_ERR;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -101,8 +101,7 @@ static const char* ref_kind_str[28] = {
/* ============================================================================= */
static int get_reference_index(jvmtiHeapReferenceKind reference_kind,
const jvmtiHeapReferenceInfo* reference_info)
{
const jvmtiHeapReferenceInfo* reference_info) {
int referrer_index = 0;
switch (reference_kind) {
@ -132,11 +131,10 @@ static int get_reference_index(jvmtiHeapReferenceKind reference_kind,
/** Initialize objectDescList. */
static int initObjectDescList(jvmtiEnv* jvmti,
int chainLength,
int* objectsCount,
ObjectDesc** objectDescList)
{
static bool initObjectDescList(jvmtiEnv* jvmti,
int chainLength,
int* objectsCount,
ObjectDesc** objectDescList) {
/* root object + reachable and unreachable object chains */
*objectsCount = 1 + 2 * chainLength;
@ -145,7 +143,7 @@ static int initObjectDescList(jvmtiEnv* jvmti,
if (!NSK_JVMTI_VERIFY(jvmti->Allocate((*objectsCount * sizeof(ObjectDesc)),
(unsigned char**) objectDescList))) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
printf(" ... allocated array: 0x%p\n", (void*)objectDescList);
fflush(0);
@ -166,21 +164,20 @@ static int initObjectDescList(jvmtiEnv* jvmti,
(*objectDescList)[chainLength].exp_found = 1;
return NSK_TRUE;
return true;
} /* initObjectDescList */
/** Find and tag classes. */
static int getAndTagClasses(jvmtiEnv* jvmti,
JNIEnv* jni,
jclass* debugeeClass,
jclass* rootObjectClass,
jclass* chainObjectClass)
{
static bool getAndTagClasses(jvmtiEnv* jvmti,
JNIEnv* jni,
jclass* debugeeClass,
jclass* rootObjectClass,
jclass* chainObjectClass) {
if (!NSK_JNI_VERIFY(jni, (*debugeeClass = jni->FindClass(DEBUGEE_CLASS_NAME)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
printf("\nFound debugee class: 0x%p\n %s\n",
(void*) *debugeeClass, DEBUGEE_CLASS_NAME);
@ -189,7 +186,7 @@ static int getAndTagClasses(jvmtiEnv* jvmti,
if (!NSK_JNI_VERIFY(jni, (*rootObjectClass =
jni->FindClass(ROOT_OBJECT_CLASS_NAME)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
if (!NSK_JVMTI_VERIFY(jvmti->SetTag(*rootObjectClass, ROOT_CLASS_TAG))) {
@ -205,7 +202,7 @@ static int getAndTagClasses(jvmtiEnv* jvmti,
if (!NSK_JNI_VERIFY(jni, (*chainObjectClass =
jni->FindClass(CHAIN_OBJECT_CLASS_NAME)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
if (!NSK_JVMTI_VERIFY(jvmti->SetTag(*chainObjectClass, CHAIN_CLASS_TAG))) {
@ -216,27 +213,26 @@ static int getAndTagClasses(jvmtiEnv* jvmti,
CHAIN_OBJECT_CLASS_NAME);
fflush(0);
return NSK_TRUE;
return true;
} /* getAndTagClasses */
/** Obtain chain of tested objects and tag them recursively. */
static int getFieldsAndObjects(jvmtiEnv* jvmti,
JNIEnv* jni,
jclass debugeeClass,
jclass rootObjectClass,
jclass chainObjectClass,
jobject* rootObjectPtr,
jfieldID* reachableChainField,
jfieldID* unreachableChainField,
jfieldID* nextField)
{
static bool getFieldsAndObjects(jvmtiEnv* jvmti,
JNIEnv* jni,
jclass debugeeClass,
jclass rootObjectClass,
jclass chainObjectClass,
jobject* rootObjectPtr,
jfieldID* reachableChainField,
jfieldID* unreachableChainField,
jfieldID* nextField) {
jfieldID rootObjectField = NULL;
if (!NSK_JNI_VERIFY(jni, (rootObjectField =
jni->GetStaticFieldID(debugeeClass, OBJECT_FIELD_NAME, ROOT_OBJECT_CLASS_SIG)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
printf("\nFound fieldID: 0x%p - \'%s\' static field in debugee class\n",
(void*) rootObjectField, OBJECT_FIELD_NAME);
@ -245,7 +241,7 @@ static int getFieldsAndObjects(jvmtiEnv* jvmti,
if (!NSK_JNI_VERIFY(jni, (*reachableChainField =
jni->GetFieldID(rootObjectClass, REACHABLE_CHAIN_FIELD_NAME, CHAIN_OBJECT_CLASS_SIG)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
printf("\nFound fieldID: 0x%p - \'%s\' field in root object class\n",
(void*) reachableChainField, REACHABLE_CHAIN_FIELD_NAME);
@ -254,7 +250,7 @@ static int getFieldsAndObjects(jvmtiEnv* jvmti,
if (!NSK_JNI_VERIFY(jni, (*unreachableChainField =
jni->GetFieldID(rootObjectClass, UNREACHABLE_CHAIN_FIELD_NAME, CHAIN_OBJECT_CLASS_SIG)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
printf("\nFound fieldID: 0x%p - \'%s\' field in root object class\n",
@ -264,7 +260,7 @@ static int getFieldsAndObjects(jvmtiEnv* jvmti,
if (!NSK_JNI_VERIFY(jni, (*nextField =
jni->GetFieldID(chainObjectClass, NEXT_FIELD_NAME, CHAIN_OBJECT_CLASS_SIG)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
printf("\nFound fieldID: 0x%p - \'%s\' field in chain object class\n",
(void*) nextField, NEXT_FIELD_NAME);
@ -273,24 +269,24 @@ static int getFieldsAndObjects(jvmtiEnv* jvmti,
if (!NSK_JNI_VERIFY(jni, (*rootObjectPtr =
jni->GetStaticObjectField(debugeeClass, rootObjectField)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
printf("\nFound root object: 0x%p\n", (void*) *rootObjectPtr);
fflush(0);
if (!NSK_JNI_VERIFY(jni, (*rootObjectPtr = jni->NewGlobalRef(*rootObjectPtr)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
printf("Created root object global ref: 0x%p\n", (void*)*rootObjectPtr);
fflush(0);
return NSK_TRUE;
return true;
} /* getFieldsAndObjects */
/** Obtain chain of tested objects and tag them recursively. */
static int getAndTagChainObjects(
static bool getAndTagChainObjects(
jvmtiEnv* jvmti,
JNIEnv* jni,
jobject currObj,
@ -299,13 +295,12 @@ static int getAndTagChainObjects(
int count,
ObjectDesc objectDescList[],
jlong tag,
int reachable)
{
bool reachable) {
jobject nextObj = NULL;
jlong objTag = (reachable ? tag : -tag);
if (count <= 0) {
return NSK_TRUE;
return true;
}
count--;
@ -313,7 +308,7 @@ static int getAndTagChainObjects(
if (!NSK_JNI_VERIFY(jni, (nextObj = jni->GetObjectField(currObj, refField)) != NULL)) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
objectDescList[count].tag = objTag;
@ -338,12 +333,12 @@ static int getAndTagChainObjects(
tag,
reachable)
) {
return NSK_FALSE;
return false;
}
NSK_TRACE(jni->DeleteLocalRef(nextObj));
return NSK_TRUE;
return true;
} /* getAndTagChainObjects */
/** Obtain all tested objects from debugee class and tag them recursively. */
@ -363,31 +358,31 @@ static int getAndTagTestedObjects(
jfieldID unreachableChainField = NULL;
jfieldID nextField = NULL;
if (initObjectDescList(jvmti,
chainLength,
objectsCount,
objectDescList) == NSK_FALSE) {
return NSK_FALSE;
if (!initObjectDescList(jvmti,
chainLength,
objectsCount,
objectDescList)) {
return false;
}
if (getAndTagClasses(jvmti,
jni,
&debugeeClass,
&rootObjectClass,
&chainObjectClass) == NSK_FALSE) {
return NSK_FALSE;
if (!getAndTagClasses(jvmti,
jni,
&debugeeClass,
&rootObjectClass,
&chainObjectClass)) {
return false;
}
if (getFieldsAndObjects(jvmti,
jni,
debugeeClass,
rootObjectClass,
chainObjectClass,
rootObjectPtr,
&reachableChainField,
&unreachableChainField,
&nextField) == NSK_FALSE) {
return NSK_FALSE;
if (!getFieldsAndObjects(jvmti,
jni,
debugeeClass,
rootObjectClass,
chainObjectClass,
rootObjectPtr,
&reachableChainField,
&unreachableChainField,
&nextField)) {
return false;
}
printf("\nObtain and tag chain objects:\n");
@ -411,10 +406,10 @@ static int getAndTagTestedObjects(
chainLength,
(*objectDescList) + 1,
CHAIN_OBJECT_TAG,
NSK_TRUE) /* reachable objects */
true) /* reachable objects */
) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
printf(" unreachable objects chain: %d objects\n", chainLength);
@ -426,22 +421,22 @@ static int getAndTagTestedObjects(
chainLength,
(*objectDescList) + 1 + chainLength,
CHAIN_OBJECT_TAG,
NSK_FALSE) /* unreachable objects */
false) /* unreachable objects */
) {
nsk_jvmti_setFailStatus();
return NSK_FALSE;
return false;
}
return NSK_TRUE;
return true;
} /* getAndTagTestedObjects */
/** Check if tagged objects were iterated. */
static int checkTestedObjects(jvmtiEnv* jvmti,
JNIEnv* jni,
int chainLength,
ObjectDesc objectDescList[])
static bool checkTestedObjects(jvmtiEnv* jvmti,
JNIEnv* jni,
int chainLength,
ObjectDesc objectDescList[])
{
int success = NSK_TRUE;
bool success = true;
int i, idx;
printf("Following tagged objects were iterated:\n");
@ -498,16 +493,16 @@ static int checkTestedObjects(jvmtiEnv* jvmti,
fflush(0);
}
return NSK_TRUE;
return true;
} /* checkTestedObjects */
/** Release references to the tested objects and free allocated memory. */
static int releaseTestedObjects(jvmtiEnv* jvmti,
JNIEnv* jni,
int chainLength,
ObjectDesc* objectDescList,
jobject rootObject)
static void releaseTestedObjects(jvmtiEnv* jvmti,
JNIEnv* jni,
int chainLength,
ObjectDesc* objectDescList,
jobject rootObject)
{
if (rootObject != NULL) {
printf("Release object reference to root tested object: 0x%p\n", rootObject);
@ -522,7 +517,6 @@ static int releaseTestedObjects(jvmtiEnv* jvmti,
}
fflush(0);
return NSK_TRUE;
} /* releaseTestedObjects */
@ -784,10 +778,7 @@ agentProc(jvmtiEnv* jvmti, JNIEnv* jni, void* arg) {
printf(">>> Clean used data\n");
fflush(0);
if (!NSK_VERIFY(releaseTestedObjects(jvmti, jni, chainLength,
objectDescList, rootObject))) {
return;
}
releaseTestedObjects(jvmti, jni, chainLength, objectDescList, rootObject);
printf(">>> Let debugee to finish\n");
fflush(0);