aboutsummaryrefslogtreecommitdiff
path: root/src/rc/rc-plugin.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/rc/rc-plugin.c')
-rw-r--r--src/rc/rc-plugin.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/rc/rc-plugin.c b/src/rc/rc-plugin.c
index 635e52fb..29bd43c2 100644
--- a/src/rc/rc-plugin.c
+++ b/src/rc/rc-plugin.c
@@ -111,15 +111,15 @@ void rc_plugin_load (void)
dlclose (h);
} else {
if (plugin) {
- plugin->next = xmalloc (sizeof (plugin_t));
+ plugin->next = xmalloc (sizeof (*plugin->next));
plugin = plugin->next;
} else
- plugin = plugins = xmalloc (sizeof (plugin_t));
+ plugin = plugins = xmalloc (sizeof (*plugin));
- memset (plugin, 0, sizeof (plugin_t));
plugin->name = xstrdup (d->d_name);
plugin->handle = h;
plugin->hook = fptr;
+ plugin->next = NULL;
}
}
closedir (dp);