Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGrant Gayed2011-03-23 19:45:23 +0000
committerGrant Gayed2011-03-23 19:45:23 +0000
commitaa8b43b03fe23f1aa811f829b70f14fe4b3c985c (patch)
tree8aeed188b37c9d267f04e5db20c6da012aa3464c /bundles/org.eclipse.swt/Eclipse SWT WebKit
parent55a22ab9240db91b3cefd3f1694927c9a71b6ad8 (diff)
downloadeclipse.platform.swt-aa8b43b03fe23f1aa811f829b70f14fe4b3c985c.tar.gz
eclipse.platform.swt-aa8b43b03fe23f1aa811f829b70f14fe4b3c985c.tar.xz
eclipse.platform.swt-aa8b43b03fe23f1aa811f829b70f14fe4b3c985c.zip
340799 - WebKit on Windows crashes with IBM JRE
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT WebKit')
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp33
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_custom.cpp31
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java2
3 files changed, 33 insertions, 33 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp
index 2e8ed2c777..21a0b6cc0f 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2009, 2010 IBM Corporation and others. All rights reserved.
+ * Copyright (c) 2009, 2011 IBM Corporation and others. All rights reserved.
* The contents of this file are made available under the terms
* of the GNU Lesser General Public License (LGPL) Version 2.1 that
* accompanies this distribution (lgpl-v21.txt). The LGPL is also
@@ -752,37 +752,6 @@ fail:
}
#endif
-#ifndef NO_WebKitCreateInstance
-extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(WebKitCreateInstance)(JNIEnv *env, jclass that, jbyteArray arg0, jintLong arg1, jbyteArray arg2, jintLongArray arg3);
-JNIEXPORT jint JNICALL WebKit_win32_NATIVE(WebKitCreateInstance)
- (JNIEnv *env, jclass that, jbyteArray arg0, jintLong arg1, jbyteArray arg2, jintLongArray arg3)
-{
- jbyte *lparg0=NULL;
- jbyte *lparg2=NULL;
- jintLong *lparg3=NULL;
- jint rc = 0;
- WebKit_win32_NATIVE_ENTER(env, that, WebKitCreateInstance_FUNC);
- if (arg0) if ((lparg0 = env->GetByteArrayElements(arg0, NULL)) == NULL) goto fail;
- if (arg2) if ((lparg2 = env->GetByteArrayElements(arg2, NULL)) == NULL) goto fail;
- if (arg3) if ((lparg3 = env->GetIntLongArrayElements(arg3, NULL)) == NULL) goto fail;
-/*
- rc = (jint)WebKitCreateInstance(lparg0, arg1, lparg2, lparg3);
-*/
- {
- LOAD_FUNCTION(fp, WebKitCreateInstance)
- if (fp) {
- rc = (jint)((jint (CALLING_CONVENTION*)(jbyte *, jintLong, jbyte *, jintLong *))fp)(lparg0, arg1, lparg2, lparg3);
- }
- }
-fail:
- if (arg3 && lparg3) env->ReleaseIntLongArrayElements(arg3, lparg3, 0);
- if (arg2 && lparg2) env->ReleaseByteArrayElements(arg2, lparg2, 0);
- if (arg0 && lparg0) env->ReleaseByteArrayElements(arg0, lparg0, 0);
- WebKit_win32_NATIVE_EXIT(env, that, WebKitCreateInstance_FUNC);
- return rc;
-}
-#endif
-
#ifndef NO_kCFCopyStringDictionaryKeyCallBacks
extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(kCFCopyStringDictionaryKeyCallBacks)(JNIEnv *env, jclass that);
JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(kCFCopyStringDictionaryKeyCallBacks)
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_custom.cpp b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_custom.cpp
index 71f8535e2c..a979a11aa2 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_custom.cpp
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_custom.cpp
@@ -70,3 +70,34 @@ JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(JSObjectHasPropertyProc_1CALLBACK
return (jintLong)JSObjectHasPropertyProc;
}
#endif
+
+#ifndef NO_WebKitCreateInstance
+extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(WebKitCreateInstance)(JNIEnv *env, jclass that, jbyteArray arg0, jintLong arg1, jbyteArray arg2, jintLongArray arg3);
+JNIEXPORT jint JNICALL WebKit_win32_NATIVE(WebKitCreateInstance)
+ (JNIEnv *env, jclass that, jbyteArray arg0, jintLong arg1, jbyteArray arg2, jintLongArray arg3)
+{
+ jbyte *lparg0=NULL;
+ jbyte *lparg2=NULL;
+ jintLong *lparg3=NULL;
+ jint rc = 0;
+ WebKit_win32_NATIVE_ENTER(env, that, WebKitCreateInstance_FUNC);
+ if (arg0) if ((lparg0 = env->GetByteArrayElements(arg0, NULL)) == NULL) goto fail;
+ if (arg2) if ((lparg2 = env->GetByteArrayElements(arg2, NULL)) == NULL) goto fail;
+ if (arg3) if ((lparg3 = env->GetIntLongArrayElements(arg3, NULL)) == NULL) goto fail;
+/*
+ rc = (jint)WebKitCreateInstance(lparg0, arg1, lparg2, lparg3);
+*/
+ {
+ LOAD_FUNCTION(fp, WebKitCreateInstance)
+ if (fp) {
+ rc = (jint)((jint (*)(jbyte *, jintLong, jbyte *, jintLong *))fp)(lparg0, arg1, lparg2, lparg3);
+ }
+ }
+fail:
+ if (arg3 && lparg3) env->ReleaseIntLongArrayElements(arg3, lparg3, 0);
+ if (arg2 && lparg2) env->ReleaseByteArrayElements(arg2, lparg2, 0);
+ if (arg0 && lparg0) env->ReleaseByteArrayElements(arg0, lparg0, 0);
+ WebKit_win32_NATIVE_EXIT(env, that, WebKitCreateInstance_FUNC);
+ return rc;
+}
+#endif
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java
index c4fe3c7aec..f76ea9f2c4 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java
@@ -344,7 +344,7 @@ public static final native int JSClassDefinition_sizeof ();
* @param size cast=(size_t)
*/
public static final native void memmove (int /*long*/ dest, JSClassDefinition src, int /*long*/ size);
-/** @method flags=dynamic*/
+/** @method flags=no_gen */
public static final native int WebKitCreateInstance (byte[] rclsid, int /*long*/ pUnkOuter, byte[] refiid, int /*long*/[] ppvObject);
public static final int WebKitCreateInstance (GUID clsid, int /*long*/ pUnkOuter, GUID iid, int /*long*/[] ppvObject) {
byte[] rclsid = new byte[GUID.sizeof];

Back to the top