From f059882742042da64093edeb8e4fa1ee813e7457 Mon Sep 17 00:00:00 2001 From: Christian Dywan Date: Sat, 20 Dec 2008 00:25:31 +0100 Subject: [PATCH] Show even broken (not linking) extensions in the panel --- midori/main.c | 23 ++++++++++------------- 1 file changed, 10 insertions(+), 13 deletions(-) diff --git a/midori/main.c b/midori/main.c index e4d29ac4..19c07047 100644 --- a/midori/main.c +++ b/midori/main.c @@ -2020,20 +2020,17 @@ main (int argc, fullname = g_build_filename (extension_path, filename, NULL); module = g_module_open (fullname, G_MODULE_BIND_LOCAL); g_free (fullname); - if (!module) - { - g_warning ("%s", g_module_error ()); - continue; - } - ; - if (!g_module_symbol (module, "extension_init", - (gpointer) &extension_init)) - { - g_warning ("%s", g_module_error ()); - continue; - } - extension = extension_init (); + + if (module && g_module_symbol (module, "extension_init", + (gpointer) &extension_init)) + extension = extension_init (); + else + extension = g_object_new (MIDORI_TYPE_EXTENSION, + "name", filename, + "description", g_module_error (), + NULL); katze_array_add_item (extensions, extension); + g_object_unref (extension); } g_dir_close (extension_dir); } -- 2.39.5