aboutsummaryrefslogtreecommitdiffstats
path: root/trace-util.c
diff options
context:
space:
mode:
authorSteven Rostedt <srostedt@redhat.com>2010-06-01 11:28:44 -0400
committerSteven Rostedt <rostedt@goodmis.org>2010-06-01 11:28:44 -0400
commitc123207585e1a51b728667c8b661ce39113d0e46 (patch)
treef384dc97e65a7e9d0c897e2621f065999898ddf7 /trace-util.c
parentb530a23f0442be322b1717e6dbce2bd502634cb4 (diff)
trace-cmd: Only C plugins that end with .so
In order to put python plugins in the plugin directory, we must keep the dlopen from opening them. Use the extensions to denote the type of plugin they are. The compiled C plugins should end with .so. The python plugins will end with .py. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'trace-util.c')
-rw-r--r--trace-util.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/trace-util.c b/trace-util.c
index 4fd1d38..6007fb8 100644
--- a/trace-util.c
+++ b/trace-util.c
@@ -324,6 +324,10 @@ static int load_plugins(struct pevent *pevent, struct plugin_list **list,
324 strcmp(name, "..") == 0) 324 strcmp(name, "..") == 0)
325 continue; 325 continue;
326 326
327 /* Only load plugins that end in '.so' */
328 if (strcmp(name + (strlen(name) - 3), ".so") != 0)
329 continue;
330
327 *list = load_plugin(pevent, *list, path, name); 331 *list = load_plugin(pevent, *list, path, name);
328 } 332 }
329 333