mirror of
https://github.com/NLnetLabs/unbound.git
synced 2025-12-20 23:00:56 -05:00
python warning suppress.
git-svn-id: file:///svn/unbound/trunk@1672 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
parent
819f9d817a
commit
790fe91662
4 changed files with 48 additions and 46 deletions
|
|
@ -6,6 +6,7 @@
|
|||
reply has an NS in the authority but no signatures. They are
|
||||
turned into minimal responses with only the (secure) answer.
|
||||
- autoconf 2.63 for configure.
|
||||
- python warnings suppress. Keep python API away from header files.
|
||||
|
||||
17 June 2009: Wouter
|
||||
- CREDITS entry for cz.nic, sponsoring a 'summer of code' that was
|
||||
|
|
|
|||
|
|
@ -44,11 +44,54 @@
|
|||
#endif
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#undef _POSIX_C_SOURCE
|
||||
#undef _XOPEN_SOURCE
|
||||
#include <Python.h>
|
||||
|
||||
#include "pythonmod/pythonmod.h"
|
||||
#include "util/module.h"
|
||||
#include "util/config_file.h"
|
||||
#include "pythonmod_utils.h"
|
||||
#include <Python.h>
|
||||
|
||||
/**
|
||||
* Global state for the module.
|
||||
*/
|
||||
struct pythonmod_env {
|
||||
|
||||
/** Python script filename. */
|
||||
const char* fname;
|
||||
|
||||
/** Python module. */
|
||||
PyObject* module;
|
||||
|
||||
/** Module init function */
|
||||
PyObject* func_init;
|
||||
/** Module deinit function */
|
||||
PyObject* func_deinit;
|
||||
/** Module operate function */
|
||||
PyObject* func_operate;
|
||||
/** Module super_inform function */
|
||||
PyObject* func_inform;
|
||||
|
||||
/** Python dictionary. */
|
||||
PyObject* dict;
|
||||
|
||||
/** Module data. */
|
||||
PyObject* data;
|
||||
|
||||
/** Module qstate. */
|
||||
struct module_qstate* qstate;
|
||||
};
|
||||
|
||||
/**
|
||||
* Per query state for the iterator module.
|
||||
*/
|
||||
struct pythonmod_qstate {
|
||||
|
||||
/** Module per query data. */
|
||||
PyObject* data;
|
||||
};
|
||||
|
||||
/* Generated */
|
||||
#ifndef S_SPLINT_S
|
||||
|
|
|
|||
|
|
@ -41,51 +41,6 @@
|
|||
#define PYTHONMOD_H
|
||||
#include "util/module.h"
|
||||
#include "services/outbound_list.h"
|
||||
#include <Python.h>
|
||||
|
||||
struct PyObject;
|
||||
#if S_SPLINT_S
|
||||
typedef struct PyObject PyObject;
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Global state for the module.
|
||||
*/
|
||||
struct pythonmod_env {
|
||||
|
||||
/** Python script filename. */
|
||||
const char* fname;
|
||||
|
||||
/** Python module. */
|
||||
PyObject* module;
|
||||
|
||||
/** Module init function */
|
||||
PyObject* func_init;
|
||||
/** Module deinit function */
|
||||
PyObject* func_deinit;
|
||||
/** Module operate function */
|
||||
PyObject* func_operate;
|
||||
/** Module super_inform function */
|
||||
PyObject* func_inform;
|
||||
|
||||
/** Python dictionary. */
|
||||
PyObject* dict;
|
||||
|
||||
/** Module data. */
|
||||
PyObject* data;
|
||||
|
||||
/** Module qstate. */
|
||||
struct module_qstate* qstate;
|
||||
};
|
||||
|
||||
/**
|
||||
* Per query state for the iterator module.
|
||||
*/
|
||||
struct pythonmod_qstate {
|
||||
|
||||
/** Module per query data. */
|
||||
PyObject* data;
|
||||
};
|
||||
|
||||
/**
|
||||
* Get the module function block.
|
||||
|
|
|
|||
|
|
@ -47,6 +47,9 @@
|
|||
#include "util/data/msgreply.h"
|
||||
#include "util/storage/slabhash.h"
|
||||
#include "util/regional.h"
|
||||
|
||||
#undef _POSIX_C_SOURCE
|
||||
#undef _XOPEN_SOURCE
|
||||
#include <Python.h>
|
||||
|
||||
/** Store the reply_info and query_info pair in message cache (qstate->msg_cache) */
|
||||
|
|
|
|||
Loading…
Reference in a new issue