Merge sudo_module_register_loghandler and sudo_module_set_default_loghandler.
We now create the LogHandler class for each interpreter in python_plugin_init() instead of just once in sudo_module_init(). This fixes the crash seen in Py_EndInterpreter() with Python 3.12 and significantly reduces the number of leaked objects tracked by MemorySanitizer.
This commit is contained in:
@@ -45,9 +45,6 @@ int sudo_module_ConvMessages_to_c(PyObject *py_tuple, Py_ssize_t *num_msgs, stru
|
||||
CPYCHECKER_NEGATIVE_RESULT_SETS_EXCEPTION
|
||||
int sudo_module_register_baseplugin(PyObject *py_module);
|
||||
|
||||
CPYCHECKER_NEGATIVE_RESULT_SETS_EXCEPTION
|
||||
int sudo_module_register_loghandler(PyObject *py_module);
|
||||
|
||||
CPYCHECKER_NEGATIVE_RESULT_SETS_EXCEPTION
|
||||
int sudo_module_set_default_loghandler(void);
|
||||
|
||||
|
Reference in New Issue
Block a user