Bug 420581 - I20131028-2000 hangs in
WebKitGTK._webkit_web_view_get_type(Native Method) when creating Browser
widget
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/library/webkitgtk.h b/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/library/webkitgtk.h
index 894340c..b902301 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/library/webkitgtk.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/library/webkitgtk.h
@@ -25,10 +25,12 @@
static int initialized = 0; \
static void *var = NULL; \
if (!initialized) { \
- void* handle ; \
- if (getenv("SWT_GTK3")) { \
+ void* handle = 0; \
+ char *gtk3 = getenv("SWT_GTK3"); \
+ if (gtk3 == NULL || strcmp(gtk3, "1") == 0) { \
handle = dlopen("libwebkitgtk-3.0.so.0", LOAD_FLAGS); /* webkitgtk >= 3.x lib */ \
- } else { \
+ } \
+ if (!handle) { \
handle = dlopen("libwebkit-1.0.so.2", LOAD_FLAGS); /* webkitgtk 1.2.x lib */ \
if (!handle) { \
handle = dlopen("libwebkitgtk-1.0.so.0", LOAD_FLAGS); /* webkitgtk >= 1.4.x lib */ \