8139801: Error message from validation check has wrong order on Windows
Summary: Added flushing stdout and stderr before exit or abort
Reviewed-by: coleenp, cjplummer
--- a/hotspot/src/share/vm/prims/jni.cpp Fri Oct 23 14:33:19 2015 +0300
+++ b/hotspot/src/share/vm/prims/jni.cpp Mon Oct 26 08:34:25 2015 -0700
@@ -4061,6 +4061,10 @@
OrderAccess::release_store(&vm_created, 0);
}
+ // Flush stdout and stderr before exit.
+ fflush(stdout);
+ fflush(stderr);
+
return result;
}
--- a/hotspot/src/share/vm/runtime/java.cpp Fri Oct 23 14:33:19 2015 +0300
+++ b/hotspot/src/share/vm/runtime/java.cpp Mon Oct 26 08:34:25 2015 -0700
@@ -575,6 +575,11 @@
void vm_abort(bool dump_core) {
vm_perform_shutdown_actions();
os::wait_for_keypress_at_exit();
+
+ // Flush stdout and stderr before abort.
+ fflush(stdout);
+ fflush(stderr);
+
os::abort(dump_core);
ShouldNotReachHere();
}