Don't use g_warning when loading an engine fails

This causes the tests to abort if clearlooks can't be found.
This commit is contained in:
Matthias Clasen 2010-12-06 00:44:01 -05:00
parent d378470e87
commit 94c9eb72ce

View File

@ -889,19 +889,13 @@ gtk_theming_module_load (GTypeModule *type_module)
module_path = _gtk_find_module (name, "theming-engines"); module_path = _gtk_find_module (name, "theming-engines");
if (!module_path) if (!module_path)
{ return FALSE;
g_warning (_("Unable to locate theme engine in module path: \"%s\","), name);
return FALSE;
}
module = g_module_open (module_path, G_MODULE_BIND_LAZY | G_MODULE_BIND_LOCAL); module = g_module_open (module_path, G_MODULE_BIND_LAZY | G_MODULE_BIND_LOCAL);
g_free (module_path); g_free (module_path);
if (!module) if (!module)
{ return FALSE;
g_warning ("%s", g_module_error ());
return FALSE;
}
if (!g_module_symbol (module, "theme_init", if (!g_module_symbol (module, "theme_init",
(gpointer *) &theming_module->init) || (gpointer *) &theming_module->init) ||
@ -910,7 +904,6 @@ gtk_theming_module_load (GTypeModule *type_module)
!g_module_symbol (module, "create_engine", !g_module_symbol (module, "create_engine",
(gpointer *) &theming_module->create_engine)) (gpointer *) &theming_module->create_engine))
{ {
g_warning ("%s", g_module_error ());
g_module_close (module); g_module_close (module);
return FALSE; return FALSE;