summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a052e2b)
raw | patch | inline | side by side (parent: a052e2b)
author | Sebastian Harl <sh@tokkee.org> | |
Fri, 18 Apr 2014 12:42:08 +0000 (14:42 +0200) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Fri, 18 Apr 2014 12:42:08 +0000 (14:42 +0200) |
src/core/plugin.c | patch | blob | history |
diff --git a/src/core/plugin.c b/src/core/plugin.c
index 6f6beeb13935e5fff22610aa5d62c599ce2f8cfc..18ea82c77fc8475d73dfb9e4a37b8a7a693443fc 100644 (file)
--- a/src/core/plugin.c
+++ b/src/core/plugin.c
}
}
- sdb_log(SDB_LOG_INFO, "core: Unloading module %s", plugin_name);
obj = sdb_llist_remove_by_name(all_plugins, plugin_name);
+ if (obj->ref_cnt <= 1)
+ sdb_log(SDB_LOG_INFO, "core: Unloading module %s", plugin_name);
+ /* else: other callbacks still reference it */
sdb_object_deref(obj);
} /* plugin_unregister_by_name */