plugins/python/python_plugin_common: close can get custom arguments
For the audit plugin. Ensure we do not fail if plugin_ctx->py_instance is NULL (because plugin init has failed).
This commit is contained in:

committed by
Todd C. Miller

parent
a7eb9d3412
commit
36694fce86
@@ -125,7 +125,8 @@ void
|
||||
python_plugin_io_close(struct IOPluginContext *io_ctx, int exit_status, int error)
|
||||
{
|
||||
debug_decl(python_plugin_io_close, PYTHON_DEBUG_CALLBACKS);
|
||||
python_plugin_close(BASE_CTX(io_ctx), CALLBACK_PYNAME(close), exit_status, error);
|
||||
python_plugin_close(BASE_CTX(io_ctx), CALLBACK_PYNAME(close),
|
||||
Py_BuildValue("(ii)", error == 0 ? exit_status : -1, error));
|
||||
debug_return;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user