1.1 --- a/src/share/vm/prims/whitebox.hpp Fri Feb 28 09:10:55 2014 -0800 1.2 +++ b/src/share/vm/prims/whitebox.hpp Wed Feb 12 12:01:45 2014 -0800 1.3 @@ -36,6 +36,22 @@ 1.4 #define WB_END JNI_END 1.5 #define WB_METHOD_DECLARE(result_type) extern "C" result_type JNICALL 1.6 1.7 +#define CHECK_JNI_EXCEPTION_(env, value) \ 1.8 + do { \ 1.9 + if (env->ExceptionCheck()) { \ 1.10 + env->ExceptionClear(); \ 1.11 + return(value); \ 1.12 + } \ 1.13 + } while (0) 1.14 + 1.15 +#define CHECK_JNI_EXCEPTION(env) \ 1.16 + do { \ 1.17 + if (env->ExceptionCheck()) { \ 1.18 + env->ExceptionClear(); \ 1.19 + return; \ 1.20 + } \ 1.21 + } while (0) 1.22 + 1.23 class WhiteBox : public AllStatic { 1.24 private: 1.25 static bool _used;