[Xfce4-commits] <xfce4-panel:master> Make sure version API is set.
Andrzej
noreply at xfce.org
Wed Dec 18 20:58:01 CET 2013
Updating branch refs/heads/master
to 862db2d44aed25e8a397f5314f9daab374c4e9fa (commit)
from b2b8dc7005eeebf2fc4f6d85b66423d73da04648 (commit)
commit 862db2d44aed25e8a397f5314f9daab374c4e9fa
Author: Andrzej <ndrwrdck at gmail.com>
Date: Wed Dec 18 19:55:28 2013 +0000
Make sure version API is set.
Start-up crashes of external plugins resulted in API being not set properly,
Then, the panel was trying to use a non-existing "wrapper" binary.
This prevented normal crash reporting mechanism from working and resulted
in an "empty" plugin being inserted into the panel.
panel/panel-module.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/panel/panel-module.c b/panel/panel-module.c
index dc947ba..0be7096 100644
--- a/panel/panel-module.c
+++ b/panel/panel-module.c
@@ -148,7 +148,7 @@ panel_module_init (PanelModule *module)
module->library = NULL;
module->construct_func = NULL;
module->plugin_type = G_TYPE_NONE;
- module->api = NULL;
+ module->api = g_strdup (LIBXFCE4PANEL_VERSION_API);
}
@@ -220,6 +220,7 @@ panel_module_load (GTypeModule *type_module)
/* from now on, run this plugin in a wrapper */
module->mode = WRAPPER;
+ g_free (module->api);
module->api = g_strdup (LIBXFCE4PANEL_VERSION_API);
return FALSE;
@@ -368,7 +369,8 @@ panel_module_new_from_desktop_file (const gchar *filename,
if (force_external || !xfce_rc_read_bool_entry (rc, "X-XFCE-Internal", FALSE))
{
module->mode = WRAPPER;
- module->api = g_strdup (xfce_rc_read_entry (rc, "X-XFCE-API", "1.0"));
+ g_free (module->api);
+ module->api = g_strdup (xfce_rc_read_entry (rc, "X-XFCE-API", LIBXFCE4PANEL_VERSION_API));
}
else
module->mode = INTERNAL;
More information about the Xfce4-commits
mailing list