diff options
| author | Julian Andres Klode <jak@debian.org> | 2010-02-27 17:31:39 +0100 |
|---|---|---|
| committer | Julian Andres Klode <jak@debian.org> | 2010-02-27 17:31:39 +0100 |
| commit | a169fd15520d61303639c0dfa2aabec3f6446fb6 (patch) | |
| tree | 7e791c9c63df5bddae36c4734164a24618bc95b0 /python/generic.h | |
| parent | 523c71a6c9b722804c65efdb79daafc56248488f (diff) | |
| download | python-apt-a169fd15520d61303639c0dfa2aabec3f6446fb6.tar.gz | |
* python:
- Handle deprecated attributes and methods in the tp_gettattro slot, this
allows us to easily warn if a deprecated function is used.
Diffstat (limited to 'python/generic.h')
| -rw-r--r-- | python/generic.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/python/generic.h b/python/generic.h index 7d2d6d3e..31c1bc2d 100644 --- a/python/generic.h +++ b/python/generic.h @@ -227,4 +227,10 @@ PyObject *HandleErrors(PyObject *Res = 0); const char **ListToCharChar(PyObject *List,bool NullTerm = false); PyObject *CharCharToList(const char **List,unsigned long Size = 0); +# ifdef COMPAT_0_7 +PyObject *_PyAptObject_getattro(PyObject *self, PyObject *attr); +# else +# define _PyAptObject_getattro 0 +# endif + #endif |
