Kaydet (Commit) 22ffe948 authored tarafından Caolán McNamara's avatar Caolán McNamara

Related: rhbz#906137 g_module_symbol returned nothing

for gdk_screen_get_primary_monitor but osl_getAsciiFunctionSymbol does the
right thing

Change-Id: Ibf1a17724a9393d95c4fbe0d26aa82148eea33a9
üst 67aae198
...@@ -18,7 +18,6 @@ ...@@ -18,7 +18,6 @@
*/ */
#include <string.h> #include <string.h>
#include <gmodule.h>
#include <gtk/gtk.h> #include <gtk/gtk.h>
#include <unx/gtk/gtkinst.hxx> #include <unx/gtk/gtkinst.hxx>
#include <unx/gtk/gtksys.hxx> #include <unx/gtk/gtksys.hxx>
...@@ -201,11 +200,8 @@ static int _get_primary_monitor (GdkScreen *pScreen) ...@@ -201,11 +200,8 @@ static int _get_primary_monitor (GdkScreen *pScreen)
// Perhaps we have a newer gtk+ with this symbol: // Perhaps we have a newer gtk+ with this symbol:
if (!get_fn) if (!get_fn)
{ {
GModule *module = g_module_open (NULL, (GModuleFlags) 0); get_fn = (int(*)(GdkScreen*))osl_getAsciiFunctionSymbol(NULL,
if (!g_module_symbol (module, "gdk_screen_get_primary_monitor", "gdk_screen_get_primary_monitor");
(gpointer *)&get_fn))
get_fn = NULL;
g_module_close (module);
} }
#if GTK_CHECK_VERSION(2,14,0) #if GTK_CHECK_VERSION(2,14,0)
if (!get_fn) if (!get_fn)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment