mirror of
https://github.com/NLnetLabs/unbound.git
synced 2025-12-24 00:29:58 -05:00
- Remove memory leak on pythonmod python2 script file init.
- Remove swig gcc8 python function cast warnings, they are ignored. git-svn-id: file:///svn/unbound/trunk@5127 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
parent
ba0cad0bc3
commit
a62c1135fe
4 changed files with 24 additions and 0 deletions
|
|
@ -1,3 +1,7 @@
|
||||||
|
28 February 2019: Wouter
|
||||||
|
- Remove memory leak on pythonmod python2 script file init.
|
||||||
|
- Remove swig gcc8 python function cast warnings, they are ignored.
|
||||||
|
|
||||||
27 February 2019: Wouter
|
27 February 2019: Wouter
|
||||||
- Fix #4229: Unbound man pages lack information, about access-control
|
- Fix #4229: Unbound man pages lack information, about access-control
|
||||||
order and local zone tags, and elements in views.
|
order and local zone tags, and elements in views.
|
||||||
|
|
|
||||||
|
|
@ -33,8 +33,16 @@
|
||||||
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||||
* POSSIBILITY OF SUCH DAMAGE.
|
* POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
%begin %{
|
||||||
|
/* store state of warning output, restored at later pop */
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
/* ignore gcc8 METH_NOARGS function cast warnings for swig function pointers */
|
||||||
|
#pragma GCC diagnostic ignored "-Wcast-function-type"
|
||||||
|
%}
|
||||||
%module unbound
|
%module unbound
|
||||||
%{
|
%{
|
||||||
|
/* restore state of warning output, remove the functioncast ignore */
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#ifdef HAVE_SYS_SOCKET_H
|
#ifdef HAVE_SYS_SOCKET_H
|
||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,16 @@
|
||||||
/*
|
/*
|
||||||
* interface.i: unbound python module
|
* interface.i: unbound python module
|
||||||
*/
|
*/
|
||||||
|
%begin %{
|
||||||
|
/* store state of warning output, restored at later pop */
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
/* ignore gcc8 METH_NOARGS function cast warnings for swig function pointers */
|
||||||
|
#pragma GCC diagnostic ignored "-Wcast-function-type"
|
||||||
|
%}
|
||||||
%module unboundmodule
|
%module unboundmodule
|
||||||
%{
|
%{
|
||||||
|
/* restore state of warning output, remove the functioncast ignore */
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
/**
|
/**
|
||||||
* \file
|
* \file
|
||||||
* This is the interface between the unbound server and a python module
|
* This is the interface between the unbound server and a python module
|
||||||
|
|
|
||||||
|
|
@ -354,7 +354,11 @@ int pythonmod_init(struct module_env* env, int id)
|
||||||
PyGILState_Release(gil);
|
PyGILState_Release(gil);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
#if PY_MAJOR_VERSION < 3
|
||||||
|
Py_XDECREF(PyFileObject);
|
||||||
|
#else
|
||||||
fclose(script_py);
|
fclose(script_py);
|
||||||
|
#endif
|
||||||
|
|
||||||
if ((pe->func_init = PyDict_GetItemString(pe->dict, "init_standard")) == NULL)
|
if ((pe->func_init = PyDict_GetItemString(pe->dict, "init_standard")) == NULL)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue