8212824: Remove unnecessary spaces before/after comparison in vmTestbase
authorjcbeyler
Mon, 14 Jan 2019 15:40:22 -0800
changeset 53554 005bcf879e09
parent 53553 d68e38b01cf0
child 53555 606b80182f64
child 57122 15acbc1030ec
8212824: Remove unnecessary spaces before/after comparison in vmTestbase Summary: Remove extra spaces around comparisons Reviewed-by: phh, amenkov
test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI02/bi02t001/bi02t001.cpp
test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI02/bi02t002/bi02t002.cpp
test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI03/bi03t001/bi03t001.cpp
test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI03/bi03t002/bi03t002.cpp
test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS201/hs201t001/hs201t001.cpp
test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS201/hs201t002/hs201t002.cpp
test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS202/hs202t001/hs202t001.cpp
test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS203/hs203t003/hs203t003.cpp
test/hotspot/jtreg/vmTestbase/nsk/jvmti/unit/FollowReferences/followref003/followref003.cpp
test/hotspot/jtreg/vmTestbase/nsk/monitoring/share/ThreadController.cpp
test/hotspot/jtreg/vmTestbase/nsk/share/jvmti/aod/jvmti_aod.cpp
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI02/bi02t001/bi02t001.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI02/bi02t001/bi02t001.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -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,8 +69,7 @@
             }
 
             if (!NSK_JNI_VERIFY(jni_env, (*new_class_data = (unsigned char*)
-                    jni_env->GetByteArrayElements(classBytes, NULL))
-                        != NULL)) {
+                    jni_env->GetByteArrayElements(classBytes, NULL)) != NULL)) {
                 nsk_jvmti_setFailStatus();
                 return;
             }
@@ -97,8 +96,7 @@
         return NSK_FALSE;
 
     if (!NSK_JNI_VERIFY(jni, (classBytes = (jbyteArray)
-            jni->GetStaticObjectField(debugeeClass, field))
-                != NULL))
+            jni->GetStaticObjectField(debugeeClass, field)) != NULL))
         return NSK_FALSE;
 
     if (!NSK_JNI_VERIFY(jni, (classBytes = (jbyteArray)jni->NewGlobalRef(classBytes)) != NULL))
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI02/bi02t002/bi02t002.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI02/bi02t002/bi02t002.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -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
@@ -63,8 +63,7 @@
         return NSK_FALSE;
 
     if (!NSK_JNI_VERIFY(jni, (classBytes = (jbyteArray)
-            jni->GetStaticObjectField(debugeeClass, field))
-                != NULL))
+            jni->GetStaticObjectField(debugeeClass, field)) != NULL))
         return NSK_FALSE;
 
     if (!NSK_JNI_VERIFY(jni, (classBytes = (jbyteArray)jni->NewGlobalRef(classBytes)) != NULL))
@@ -91,8 +90,7 @@
         return NSK_TRUE;
 
     if (!NSK_JNI_VERIFY(jni, (class_def.class_bytes = (unsigned char*)
-            jni->GetByteArrayElements(classBytes, NULL))
-                != NULL))
+            jni->GetByteArrayElements(classBytes, NULL)) != NULL))
         return NSK_TRUE;
 
     class_def.klass = testedClass;
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI03/bi03t001/bi03t001.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI03/bi03t001/bi03t001.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -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,8 +69,7 @@
             }
 
             if (!NSK_JNI_VERIFY(jni_env, (*new_class_data = (unsigned char*)
-                    jni_env->GetByteArrayElements(classBytes, NULL))
-                        != NULL)) {
+                    jni_env->GetByteArrayElements(classBytes, NULL)) != NULL)) {
                 nsk_jvmti_setFailStatus();
                 return;
             }
@@ -97,8 +96,7 @@
         return NSK_FALSE;
 
     if (!NSK_JNI_VERIFY(jni, (classBytes = (jbyteArray)
-            jni->GetStaticObjectField(debugeeClass, field))
-                != NULL))
+            jni->GetStaticObjectField(debugeeClass, field)) != NULL))
         return NSK_FALSE;
 
     if (!NSK_JNI_VERIFY(jni, (classBytes = (jbyteArray)jni->NewGlobalRef(classBytes)) != NULL))
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI03/bi03t002/bi03t002.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/bcinstr/BI03/bi03t002/bi03t002.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -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
@@ -63,8 +63,7 @@
         return NSK_FALSE;
 
     if (!NSK_JNI_VERIFY(jni, (classBytes = (jbyteArray)
-            jni->GetStaticObjectField(debugeeClass, field))
-                != NULL))
+            jni->GetStaticObjectField(debugeeClass, field)) != NULL))
         return NSK_FALSE;
 
     if (!NSK_JNI_VERIFY(jni, (classBytes = (jbyteArray)jni->NewGlobalRef(classBytes)) != NULL))
@@ -91,8 +90,7 @@
         return NSK_TRUE;
 
     if (!NSK_JNI_VERIFY(jni, (class_def.class_bytes = (unsigned char*)
-            jni->GetByteArrayElements(classBytes, NULL))
-                != NULL))
+            jni->GetByteArrayElements(classBytes, NULL)) != NULL))
         return NSK_TRUE;
 
     class_def.klass = testedClass;
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS201/hs201t001/hs201t001.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS201/hs201t001/hs201t001.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -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
@@ -190,9 +190,7 @@
         return;
     }
 
-    if (strcmp(className, EXPECTED_CLASS_SIGN)
-                        == 0) {
-
+    if (strcmp(className, EXPECTED_CLASS_SIGN) == 0) {
         NSK_DISPLAY1("\n\n>>>> Class loaded: %s", className);
         NSK_DISPLAY0(", activating breakpoint\n");
         setBreakPoint(jvmti_env, jni_env, klass);
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS201/hs201t002/hs201t002.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS201/hs201t002/hs201t002.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -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
@@ -190,9 +190,7 @@
         return;
     }
 
-    if (strcmp(className, EXPECTED_CLASS_SIGN)
-                        == 0) {
-
+    if (strcmp(className, EXPECTED_CLASS_SIGN) == 0) {
         NSK_DISPLAY1("\n\n>>>> Class loaded: %s", className);
         NSK_DISPLAY0(", activating breakpoint\n");
         setBreakPoint(jvmti_env, jni_env, klass);
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS202/hs202t001/hs202t001.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS202/hs202t001/hs202t001.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -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
@@ -116,8 +116,7 @@
         jlocation location) {
     jvmtiError err;
     err = JVMTI_ERROR_NONE;
-    if (nsk_jvmti_enableNotification(jvmti,JVMTI_EVENT_SINGLE_STEP, NULL)
-            == NSK_TRUE) {
+    if (nsk_jvmti_enableNotification(jvmti,JVMTI_EVENT_SINGLE_STEP, NULL) == NSK_TRUE) {
         nsk_printf(" Enabled.. notification event ..");
     }
     err= jvmti->SetEventNotificationMode(JVMTI_DISABLE,
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS203/hs203t003/hs203t003.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/hotswap/HS203/hs203t003/hs203t003.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -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
@@ -155,10 +155,8 @@
             nsk_printf("#error Agent :: while setting event callbacks.\n");
             return JNI_ERR;
         }
-        if ((nsk_jvmti_enableNotification(jvmti,JVMTI_EVENT_CLASS_PREPARE, NULL)
-                    == NSK_TRUE) &&
-                (nsk_jvmti_enableNotification(jvmti,JVMTI_EVENT_FIELD_ACCESS, NULL)
-                  == NSK_TRUE)) {
+        if ((nsk_jvmti_enableNotification(jvmti,JVMTI_EVENT_CLASS_PREPARE, NULL) == NSK_TRUE) &&
+                (nsk_jvmti_enableNotification(jvmti,JVMTI_EVENT_FIELD_ACCESS, NULL) == NSK_TRUE)) {
             nsk_printf(" Agent :: Notifications are enabled.\n");
         } else {
             nsk_printf("#error Agent :: Eanableing Notifications.\n");
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/unit/FollowReferences/followref003/followref003.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/unit/FollowReferences/followref003/followref003.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -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
@@ -533,7 +533,7 @@
     for (idx = 1; idx <= curr_local_idx; idx++) {
         loc = &locDesc[idx];
         if (loc->frame_id == frame_id &&
-            loc->slot     == slot) {
+            loc->slot == slot) {
             if (first_followref) {
                 /* Do this check on the first FollowReferences call only */
                 FrameDesc *fr = &frameDesc[frame_id];
--- a/test/hotspot/jtreg/vmTestbase/nsk/monitoring/share/ThreadController.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/monitoring/share/ThreadController.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 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
@@ -486,20 +486,15 @@
         jstring stateName;
         jint state;
 
-        if (!NSK_VERIFY(
-             env->GetJavaVM(&vm) == 0)) {
+        if (!NSK_VERIFY(env->GetJavaVM(&vm) == 0)) {
             return NULL;
         }
 
-        if (!NSK_VERIFY(
-             vm->GetEnv((void **)&jvmti, JVMTI_VERSION_1)
-                    == JNI_OK)) {
+        if (!NSK_VERIFY(vm->GetEnv((void **)&jvmti, JVMTI_VERSION_1) == JNI_OK)) {
             return NULL;
         }
 
-        if (!NSK_VERIFY(
-             jvmti->GetThreadState((jthread)thread, &state)
-             == JVMTI_ERROR_NONE)) {
+        if (!NSK_VERIFY(jvmti->GetThreadState((jthread)thread, &state) == JVMTI_ERROR_NONE)) {
             return NULL;
         }
 
--- a/test/hotspot/jtreg/vmTestbase/nsk/share/jvmti/aod/jvmti_aod.cpp	Tue Jan 29 12:12:27 2019 -0500
+++ b/test/hotspot/jtreg/vmTestbase/nsk/share/jvmti/aod/jvmti_aod.cpp	Mon Jan 14 15:40:22 2019 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008, 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
@@ -166,7 +166,7 @@
         return NULL;
     }
     if (!NSK_JNI_VERIFY(jni,
-            (threadConstructor = jni->GetMethodID(klass, "<init>", "()V"))  != NULL)) {
+            (threadConstructor = jni->GetMethodID(klass, "<init>", "()V")) != NULL)) {
         NSK_COMPLAIN0("Failed to get java.lang.Thread constructor\n");
         return NULL;
     }
@@ -199,7 +199,7 @@
         return NULL;
     }
     if (!NSK_JNI_VERIFY(jni,
-            (threadConstructor = jni->GetMethodID(klass, "<init>", "(Ljava/lang/String;)V"))  != NULL)) {
+            (threadConstructor = jni->GetMethodID(klass, "<init>", "(Ljava/lang/String;)V")) != NULL)) {
         NSK_COMPLAIN0("Failed to get java.lang.Thread constructor\n");
         return NULL;
     }