summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2344c63)
raw | patch | inline | side by side (parent: 2344c63)
author | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Sat, 29 Aug 2009 11:58:56 +0000 (13:58 +0200) | ||
committer | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Sat, 29 Aug 2009 11:58:56 +0000 (13:58 +0200) |
Handle these cases gracefully.
src/plugin.c | patch | blob | history |
diff --git a/src/plugin.c b/src/plugin.c
index 70e0c0ffcf367e5f030e86a394fddf7e2d7c315c..6fb75206a686cecebafc78b91389901d892e1f75 100644 (file)
--- a/src/plugin.c
+++ b/src/plugin.c
}
le = llist_search (read_list, name);
+ if (le == NULL)
+ {
+ pthread_mutex_unlock (&read_lock);
+ WARNING ("plugin_unregister_read: No such read function: %s",
+ name);
+ return (-ENOENT);
+ }
+
llist_remove (read_list, le);
rf = le->value;