changeset 10573:aa477d5b3653

8046887: JNI exception pending in jdk/src/solaris/native/sun/awt: awt_DrawingSurface.c, awt_GraphicsEnv.c, awt_InputMethod.c, sun_awt_X11_GtkFileDialogPeer.c Reviewed-by: azvegint, prr
author serb
date Thu, 14 Aug 2014 14:19:58 +0100
parents 5b16f47505d1
children e5265fc9e8c1
files src/solaris/native/sun/awt/awt_GraphicsEnv.c src/solaris/native/sun/awt/sun_awt_X11_GtkFileDialogPeer.c
diffstat 2 files changed, 11 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/solaris/native/sun/awt/awt_GraphicsEnv.c	Wed Aug 13 21:45:53 2014 +0400
+++ b/src/solaris/native/sun/awt/awt_GraphicsEnv.c	Thu Aug 14 14:19:58 2014 +0100
@@ -1348,7 +1348,9 @@
     }
 
     /* Make Color Model object for this GraphicsConfiguration */
-    colorModel = awtJNI_GetColorModel (env, adata);
+    colorModel = (*env)->ExceptionCheck(env)
+                 ? NULL : awtJNI_GetColorModel (env, adata);
+
     AWT_UNLOCK ();
 
     return colorModel;
@@ -2052,7 +2054,7 @@
 
     AWT_FLUSH_UNLOCK();
 
-    if (!success) {
+    if (!success && !(*env)->ExceptionCheck(env)) {
         JNU_ThrowInternalError(env, "Could not set display mode");
     }
 #endif /* !HEADLESS */
--- a/src/solaris/native/sun/awt/sun_awt_X11_GtkFileDialogPeer.c	Wed Aug 13 21:45:53 2014 +0400
+++ b/src/solaris/native/sun/awt/sun_awt_X11_GtkFileDialogPeer.c	Thu Aug 14 14:19:58 2014 +0100
@@ -246,8 +246,14 @@
         }
 
         str = (*env)->NewStringUTF(env, entry);
-        if (str && !(*env)->ExceptionCheck(env)) {
+        if((*env)->ExceptionCheck(env)){
+            break;
+        }
+        if (str) {
             (*env)->SetObjectArrayElement(env, array, i, str);
+            if((*env)->ExceptionCheck(env)){
+                break;
+            }
         }
     }