diff src/share/vm/prims/jvmtiEnv.cpp @ 9596:825cee2cd7a6

8139040: Fix initializations before ShouldNotReachHere() etc. and enable -Wuninitialized on linux. Reviewed-by: stuefe, coleenp, roland
author goetz
date Thu, 22 Oct 2015 13:07:10 -0400
parents a37aac88925c
children 4535697211eb
line wrap: on
line diff
--- a/src/share/vm/prims/jvmtiEnv.cpp	Mon Oct 19 15:03:58 2015 +0200
+++ b/src/share/vm/prims/jvmtiEnv.cpp	Thu Oct 22 13:07:10 2015 -0400
@@ -3064,7 +3064,7 @@
     // in thread.cpp.
     JvmtiPendingMonitors::enter(rmonitor);
   } else {
-    int r;
+    int r = 0;
     Thread* thread = Thread::current();
 
     if (thread->is_Java_thread()) {
@@ -3127,7 +3127,7 @@
       err = JVMTI_ERROR_NOT_MONITOR_OWNER;
     }
   } else {
-    int r;
+    int r = 0;
     Thread* thread = Thread::current();
 
     if (thread->is_Java_thread()) {
@@ -3161,7 +3161,7 @@
 // rmonitor - pre-checked for validity
 jvmtiError
 JvmtiEnv::RawMonitorWait(JvmtiRawMonitor * rmonitor, jlong millis) {
-  int r;
+  int r = 0;
   Thread* thread = Thread::current();
 
   if (thread->is_Java_thread()) {
@@ -3220,7 +3220,7 @@
 // rmonitor - pre-checked for validity
 jvmtiError
 JvmtiEnv::RawMonitorNotify(JvmtiRawMonitor * rmonitor) {
-  int r;
+  int r = 0;
   Thread* thread = Thread::current();
 
   if (thread->is_Java_thread()) {
@@ -3251,7 +3251,7 @@
 // rmonitor - pre-checked for validity
 jvmtiError
 JvmtiEnv::RawMonitorNotifyAll(JvmtiRawMonitor * rmonitor) {
-  int r;
+  int r = 0;
   Thread* thread = Thread::current();
 
   if (thread->is_Java_thread()) {