From: Philippe Proulx Date: Mon, 10 Apr 2017 19:18:14 +0000 (-0400) Subject: bt_plugin_create_append_all_from_dir(): use printf_verbose() instead of error X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=47e56665e2bd1ef11ff703a04bee9857aa7ced4f;p=deliverable%2Fbabeltrace.git bt_plugin_create_append_all_from_dir(): use printf_verbose() instead of error It's not a fatal error when this function cannot open a directory: it can simply mean that this directory does not exist, but that's okay because the function does not load plugins in this case, and it returns an error code. Signed-off-by: Philippe Proulx Signed-off-by: Jérémie Galarneau --- diff --git a/lib/plugin/plugin.c b/lib/plugin/plugin.c index 0651ae72f..7b9644d3e 100644 --- a/lib/plugin/plugin.c +++ b/lib/plugin/plugin.c @@ -329,7 +329,8 @@ enum bt_plugin_status bt_plugin_create_append_all_from_dir( directory = opendir(file_path); if (!directory) { - perror("Failed to open plug-in directory"); + printf_verbose("Failed to open plugin directory \"%s\"\n", + file_path); ret = BT_PLUGIN_STATUS_ERROR; goto end; }