forked from external/yambar
module: remove module_run_context
Store abort_fd directly in the module struct instead. This then allows us to pass the module pointer as-is to the modules' run functions.
This commit is contained in:
parent
acdeff3b6e
commit
76d135e257
13 changed files with 57 additions and 77 deletions
9
module.h
9
module.h
|
@ -22,18 +22,15 @@ struct module_info {
|
|||
{NULL, false, NULL}
|
||||
};
|
||||
|
||||
struct module_run_context {
|
||||
struct module *module;
|
||||
int abort_fd;
|
||||
};
|
||||
|
||||
struct module {
|
||||
const struct bar *bar;
|
||||
|
||||
int abort_fd;
|
||||
mtx_t lock;
|
||||
|
||||
void *private;
|
||||
|
||||
int (*run)(struct module_run_context *ctx);
|
||||
int (*run)(struct module *mod);
|
||||
void (*destroy)(struct module *module);
|
||||
|
||||
/*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue