8168417: Pending exceptions in java.base/windows/native/libnio
Reviewed-by: chegar, alanb
--- a/jdk/src/java.base/windows/native/libnio/ch/FileDispatcherImpl.c Fri Oct 21 14:52:04 2016 +0530
+++ b/jdk/src/java.base/windows/native/libnio/ch/FileDispatcherImpl.c Fri Oct 21 12:31:50 2016 +0100
@@ -202,6 +202,7 @@
if ((h == INVALID_HANDLE_VALUE) || (result == 0)) {
JNU_ThrowIOExceptionWithLastError(env, "Write failed");
+ return IOS_THROWN;
}
return convertReturnVal(env, (jint)written, JNI_FALSE);
@@ -250,6 +251,7 @@
if ((h == INVALID_HANDLE_VALUE) || (result == 0)) {
JNU_ThrowIOExceptionWithLastError(env, "Write failed");
+ return IOS_THROWN;
}
return convertLongReturnVal(env, totalWritten, JNI_FALSE);