Lines 450-457
PyObject* PyUNO_getattr (PyObject* self, char* name)
Link Here
|
450 |
{ |
450 |
{ |
451 |
PyUNO* me; |
451 |
PyUNO* me; |
452 |
|
452 |
|
453 |
#if PY_VERSION_HEX >= 0x03030000 |
453 |
#if PY_VERSION_HEX < 0x03030000 |
454 |
char *name = PyUnicode_AsUTF8(attr_name); |
454 |
cconst char *name = PyUnicode_AsUTF8(attr_name); |
455 |
#elif PY_MAJOR_VERSION >= 3 |
455 |
#elif PY_MAJOR_VERSION >= 3 |
456 |
PyRef pUtf8(PyUnicode_AsUTF8String(attr_name), SAL_NO_ACQUIRE); |
456 |
PyRef pUtf8(PyUnicode_AsUTF8String(attr_name), SAL_NO_ACQUIRE); |
457 |
char *name = PyBytes_AsString(pUtf8.get()); |
457 |
char *name = PyBytes_AsString(pUtf8.get()); |
Lines 568-574
int PyUNO_setattr (PyObject* self, char* name, PyObjec
Link Here
|
568 |
{ |
568 |
{ |
569 |
PyUNO* me; |
569 |
PyUNO* me; |
570 |
|
570 |
|
571 |
#if PY_VERSION_HEX >= 0x03030000 |
571 |
#if PY_VERSION_HEX < 0x03030000 |
572 |
char *name = PyUnicode_AsUTF8(attr_name); |
572 |
char *name = PyUnicode_AsUTF8(attr_name); |
573 |
#elif PY_MAJOR_VERSION >= 3 |
573 |
#elif PY_MAJOR_VERSION >= 3 |
574 |
PyRef pUtf8(PyUnicode_AsUTF8String(attr_name), SAL_NO_ACQUIRE); |
574 |
PyRef pUtf8(PyUnicode_AsUTF8String(attr_name), SAL_NO_ACQUIRE); |
Lines 818-824
static PyTypeObject PyUNOType =
Link Here
|
818 |
NULL, |
818 |
NULL, |
819 |
NULL, |
819 |
NULL, |
820 |
(destructor)0 |
820 |
(destructor)0 |
821 |
#if PY_VERSION_HEX >= 0x02060000 |
821 |
#if PY_VERSION_HEX < 0x02060000 |
822 |
, 0 |
822 |
, 0 |
823 |
#endif |
823 |
#endif |
824 |
}; |
824 |
}; |