diff test/hotspot/jtreg/vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretbase/earlyretbase.cpp @ 53610:9cfc8b0c45fd

8214149: Move out assignments when not using NSK*VERIFY macros Summary: Move out the assignments from ifs Reviewed-by: sspitsyn, cjplummer
author jcbeyler
date Wed, 21 Nov 2018 10:46:45 -0800
parents 1ebe04845112
children f6005102c6ef
line wrap: on
line diff
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretbase/earlyretbase.cpp	Wed Nov 21 18:44:11 2018 +0000
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/unit/ForceEarlyReturn/earlyretbase/earlyretbase.cpp	Wed Nov 21 10:46:45 2018 -0800
@@ -85,8 +85,8 @@
     }
 
     printf(">>>>>>>> Invoke SuspendThread()\n");
-    if ((err = (jvmti->SuspendThread(earlyretThr)))
-                                         != JVMTI_ERROR_NONE) {
+    err = jvmti->SuspendThread(earlyretThr);
+    if (err != JVMTI_ERROR_NONE) {
         printf("%s: Failed to call SuspendThread(): error=%d: %s\n",
             __FILE__, err, TranslateError(err));
         return JNI_ERR;
@@ -106,8 +106,8 @@
     }
 
     printf(">>>>>>>> Invoke ResumeThread()\n");
-    if ((err = (jvmti->ResumeThread(earlyretThr)))
-                                        != JVMTI_ERROR_NONE) {
+    err = jvmti->ResumeThread(earlyretThr);
+    if (err != JVMTI_ERROR_NONE) {
         printf("%s: Failed to call ResumeThread(): error=%d: %s\n",
             __FILE__, err, TranslateError(err));
         return JNI_ERR;
@@ -168,8 +168,8 @@
     }
     printf("After call to GetMethodID(%s, %s)\n", name_exp, sig_exp);
 
-    if ((err = (jvmti->ForceEarlyReturnLong(earlyretThr, valToRet)))
-                                                          != JVMTI_ERROR_NONE) {
+    err = jvmti->ForceEarlyReturnLong(earlyretThr, valToRet);
+    if (err != JVMTI_ERROR_NONE) {
         printf("TEST FAILED: the function ForceEarlyReturn()"
                " returned the error %d: %s\n",
                err, TranslateError(err));