mirror of
https://github.com/samba-team/samba.git
synced 2025-01-08 21:18:16 +03:00
samba:python - Py_RETURN_NONE remove compatibility code for releases < 2.4
http://www.python.org/doc//current/c-api/none.html Reviewed-By: Jelmer Vernooij <jelmer@samba.org> Autobuild-User(master): Matthias Dieter Wallnöfer <mdw@samba.org> Autobuild-Date(master): Thu Jan 9 16:27:47 CET 2014 on sn-devel-104
This commit is contained in:
parent
d1dacd62bb
commit
0c2fbe5a0c
@ -28,10 +28,6 @@
|
||||
#include "replace.h"
|
||||
#include "system/filesys.h"
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
/* Include tdb headers */
|
||||
#include <tdb.h>
|
||||
|
||||
|
@ -64,10 +64,6 @@ typedef inquiry lenfunc;
|
||||
typedef intargfunc ssizeargfunc;
|
||||
#endif
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
#define SIGN(a) (((a) == 0)?0:((a) < 0?-1:1))
|
||||
|
||||
|
||||
|
@ -36,11 +36,6 @@ typedef inquiry lenfunc;
|
||||
typedef intargfunc ssizeargfunc;
|
||||
#endif
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
|
||||
/**
|
||||
* Find out PyTypeObject in ldb module for a given typename
|
||||
*/
|
||||
|
@ -29,10 +29,6 @@
|
||||
#include "replace.h"
|
||||
#include "system/filesys.h"
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
/* Include ntdb headers */
|
||||
#include <ntdb.h>
|
||||
|
||||
|
@ -52,10 +52,6 @@ typedef inquiry lenfunc;
|
||||
typedef intargfunc ssizeargfunc;
|
||||
#endif
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
#ifndef Py_TYPE /* Py_TYPE is only available on Python > 2.6 */
|
||||
#define Py_TYPE(ob) (((PyObject*)(ob))->ob_type)
|
||||
#endif
|
||||
|
@ -28,10 +28,6 @@
|
||||
#include "replace.h"
|
||||
#include "system/filesys.h"
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
/* Include tdb headers */
|
||||
#include <tdb.h>
|
||||
|
||||
|
@ -26,10 +26,6 @@
|
||||
|
||||
void initnetbios(void);
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
extern PyTypeObject nbt_node_Type;
|
||||
|
||||
typedef struct {
|
||||
|
@ -25,10 +25,6 @@
|
||||
|
||||
void init_glue(void);
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
static PyObject *py_generate_random_str(PyObject *self, PyObject *args)
|
||||
{
|
||||
int len;
|
||||
|
@ -33,10 +33,6 @@ typedef inquiry lenfunc;
|
||||
typedef intargfunc ssizeargfunc;
|
||||
#endif
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
#ifndef Py_TYPE /* Py_TYPE is only available on Python > 2.6 */
|
||||
#define Py_TYPE(ob) (((PyObject*)(ob))->ob_type)
|
||||
#endif
|
||||
|
@ -43,10 +43,6 @@ typedef inquiry lenfunc;
|
||||
typedef intargfunc ssizeargfunc;
|
||||
#endif
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
static PyObject *PyAuthSession_FromSession(struct auth_session_info *session)
|
||||
{
|
||||
return py_return_ndr_struct("samba.dcerpc.auth", "session_info", session, session);
|
||||
|
@ -38,10 +38,6 @@
|
||||
#include "libcli/security/security_descriptor.h"
|
||||
#include "librpc/rpc/pyrpc_util.h"
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
staticforward PyTypeObject PySMB;
|
||||
|
||||
void initsmb(void);
|
||||
|
@ -26,10 +26,6 @@
|
||||
#include "auth/credentials/pycredentials.h"
|
||||
#include "librpc/rpc/pyrpc_util.h"
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
static void PyType_AddGetSet(PyTypeObject *type, PyGetSetDef *getset)
|
||||
{
|
||||
PyObject *dict;
|
||||
|
@ -20,10 +20,6 @@
|
||||
#include <Python.h>
|
||||
#include "librpc/gen_ndr/misc.h"
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
static int py_GUID_cmp(PyObject *py_self, PyObject *py_other)
|
||||
{
|
||||
int ret;
|
||||
|
@ -20,10 +20,6 @@
|
||||
#include <Python.h>
|
||||
#include "libcli/security/security.h"
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
static void PyType_AddMethods(PyTypeObject *type, PyMethodDef *methods)
|
||||
{
|
||||
PyObject *dict;
|
||||
|
@ -19,10 +19,6 @@
|
||||
|
||||
#include <Python.h>
|
||||
|
||||
#ifndef Py_RETURN_NONE
|
||||
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
|
||||
#endif
|
||||
|
||||
static void PyType_AddMethods(PyTypeObject *type, PyMethodDef *methods)
|
||||
{
|
||||
PyObject *dict;
|
||||
|
Loading…
Reference in New Issue
Block a user