]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
chg: dev: provide more context when registering plugins
authorColin Vidal <colin@isc.org>
Wed, 1 Oct 2025 09:52:14 +0000 (11:52 +0200)
committerColin Vidal <colin@isc.org>
Wed, 1 Oct 2025 09:52:14 +0000 (11:52 +0200)
Add a new type, `ns_pluginregister_ctx_t`, which is passed to `plugin_register()` in place of the `source` parameter. The source value is now just part of the structure, which also holds a pointer to the zone origin if the plugin is loaded at a zone level.

This provides more contextual information, enabling the plugin to make specific configuration decisions based on the name of the zone for which it is loaded.

It's also flexible if more contextual data are needed in the future: add a new field to `ns_pluginregister_ctx_t`, and new plugins can use it without affecting compatibility with existing plugins.

Closes #5533

Merge branch '5533-plugin-register-ctx' into 'main'

See merge request isc-projects/bind9!11019


Trivial merge