mod: add accessor function to module list (#66)

This commit is contained in:
Alfred E. Heggestad 2017-06-29 22:32:52 +02:00 committed by Richard Aas
parent d5acb4b000
commit 9ca4ebb078
2 changed files with 12 additions and 0 deletions

View file

@ -71,4 +71,5 @@ int mod_load(struct mod **mp, const char *name);
int mod_add(struct mod **mp, const struct mod_export *me);
struct mod *mod_find(const char *name);
const struct mod_export *mod_export(const struct mod *m);
struct list *mod_list(void);
int mod_debug(struct re_printf *pf, void *unused);

View file

@ -203,6 +203,17 @@ const struct mod_export *mod_export(const struct mod *m)
}
/**
* Get the list of loaded modules
*
* @return Module list
*/
struct list *mod_list(void)
{
return &modl;
}
/**
* Debug loadable modules
*