diff options
author | Vladimír Čunát <vladimir.cunat@nic.cz> | 2024-12-20 13:27:41 +0100 |
---|---|---|
committer | Vladimír Čunát <vladimir.cunat@nic.cz> | 2024-12-20 13:27:41 +0100 |
commit | efbb03116feb37736f5dad3cd7d6a80c44b1e478 (patch) | |
tree | dc477efbd0ae5a99e52a7365ac737b9f1b34db1e /daemon | |
parent | kr_module_load(): avoid calling deinit() on errors (diff) | |
download | knot-resolver-efbb03116feb37736f5dad3cd7d6a80c44b1e478.tar.xz knot-resolver-efbb03116feb37736f5dad3cd7d6a80c44b1e478.zip |
kr_module_load(): don't pass the_engine in module->data
It was a confusing way of repurposing the field.
My comment from over five years ago (129002fc0d) said that
some external C modules might be relying on this.
But that certainly sounds moot nowadays. To get more confidence,
I rechecked all kr_module::data references (as found by libclang).
Diffstat (limited to 'daemon')
-rw-r--r-- | daemon/engine.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/daemon/engine.c b/daemon/engine.c index 509915df..a0da529b 100644 --- a/daemon/engine.c +++ b/daemon/engine.c @@ -741,8 +741,6 @@ int engine_register(const char *name, const char *precedence, const char* ref) if (!module) { return kr_error(ENOMEM); } - module->data = the_engine; /*< some outside modules may still use this value */ - int ret = kr_module_load(module, name, LIBDIR "/kres_modules"); if (ret == 0) { /* We have a C module, loaded and init() was called. |