Permalink
Browse files

compile_problems2

===================================================================
  • Loading branch information...
1 parent 07a4f40 commit d09a842601015f1f6e08efd7fcb8be3cc65a6cce SZALAY Attila committed Feb 2, 2012
Showing with 68 additions and 294 deletions.
  1. +6 −24 lib/pyattach.c
  2. +18 −72 lib/pydict.c
  3. +6 −24 lib/pydispatch.c
  4. +8 −24 lib/pystream.c
  5. +30 −120 lib/pyx509.c
  6. +0 −30 lib/zorp/zpython.h
View
@@ -295,30 +295,12 @@ PyMethodDef z_policy_attach_funcs[] =
static PyTypeObject z_policy_attach_type =
{
- PyObject_HEAD_INIT(&PyType_Type)
- 0,
- "ZPolicyAttach",
- sizeof(ZPolicyAttach),
- 0,
- (destructor) z_policy_attach_free,
- 0,
- (getattrfunc) z_policy_attach_getattr,
- 0,
- 0,
- 0, /*(reprfunc) z_policy_attach_repr,*/
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- "ZPolicyAttach class for Zorp",
- 0, 0, 0, 0,
- Z_PYTYPE_TRAILER
+ PyVarObject_HEAD_INIT(&PyType_Type,0)
+ .tp_name = "ZPolicyAttach",
+ .tp_basicsize = sizeof(ZPolicyAttach),
+ .tp_dealloc = (destructor) z_policy_attach_free,
+ .tp_getattr = (getattrfunc) z_policy_attach_getattr,
+ .tp_doc = "ZPolicyAttach class for Zorp"
};
View
@@ -599,30 +599,12 @@ z_policy_method_free(ZPolicyMethod *self)
static PyTypeObject z_policy_method_type =
{
- PyObject_HEAD_INIT(&PyType_Type)
- 0,
- "ZPolicyMethod",
- sizeof(ZPolicyMethod),
- 0,
- (destructor) z_policy_method_free,
- 0, /* tp_print */
- 0, /* tp_getattr */
- 0, /* tp_setattr */
- 0, /* tp_compare */
- 0, /* tp_repr */
- 0, /* tp_as_number */
- 0, /* tp_as_sequence */
- 0, /* tp_as_mapping */
- 0, /* tp_hash */
- (ternaryfunc) z_policy_method_call,/* tp_call */
- 0, /* tp_str */
- 0, /* tp_getattro */
- 0, /* tp_setattro */
- 0, /* tp_as_buffer */
- 0, /* flags */
- "ZPolicyMethod class for Zorp", /* docstring */
- 0, 0, 0, 0,
- Z_PYTYPE_TRAILER
+ PyVarObject_HEAD_INIT(&PyType_Type, 0)
+ .tp_name = "ZPolicyMethod",
+ .tp_basicsize = sizeof(ZPolicyMethod),
+ .tp_dealloc = (destructor) z_policy_method_free,
+ .tp_call = (ternaryfunc) z_policy_method_call,
+ .tp_doc = "ZPolicyMethod class for Zorp"
};
/**
@@ -1132,30 +1114,12 @@ PyMappingMethods z_policy_hash_mapping =
PyTypeObject z_policy_hash_type =
{
- PyObject_HEAD_INIT(&PyType_Type)
- 0,
- "Zorp hash",
- sizeof(ZPolicyHash),
- 0,
- (destructor) z_policy_hash_free,
- 0, /* tp_print */
- 0, /* tp_getattr */
- 0, /* tp_setattr */
- 0, /* tp_compare */
- 0, /* tp_repr */
- 0, /* tp_as_number */
- 0, /* tp_as_sequence */
- &z_policy_hash_mapping, /* tp_as_mapping */
- 0, /* tp_hash */
- 0, /* tp_call */
- 0, /* tp_str */
- 0, /* tp_getattro */
- 0, /* tp_setattro */
- 0, /* tp_as_buffer */
- 0, /* flags */
- "ZPolicyHash class for Zorp", /* docstring */
- 0, 0, 0, 0,
- Z_PYTYPE_TRAILER
+ PyVarObject_HEAD_INIT(&PyType_Type, 0)
+ .tp_name = "Zorp hash",
+ .tp_basicsize = sizeof(ZPolicyHash),
+ .tp_dealloc = (destructor) z_policy_hash_free,
+ .tp_as_mapping = &z_policy_hash_mapping,
+ .tp_doc = "ZPolicyHash class for Zorp"
};
void
@@ -1441,30 +1405,12 @@ PyMappingMethods z_policy_dim_hash_mapping =
PyTypeObject z_policy_dim_hash_type =
{
- PyObject_HEAD_INIT(&PyType_Type)
- 0,
- "Zorp Multidimensional hash",
- sizeof(ZPolicyDimHash),
- 0,
- (destructor) z_policy_dim_hash_free,
- 0, /* tp_print */
- 0, /* tp_getattr */
- 0, /* tp_setattr */
- 0, /* tp_compare */
- 0, /* tp_repr */
- 0, /* tp_as_number */
- 0, /* tp_as_sequence */
- &z_policy_dim_hash_mapping, /* tp_as_mapping */
- 0, /* tp_hash */
- 0, /* tp_call */
- 0, /* tp_str */
- 0, /* tp_getattro */
- 0, /* tp_setattro */
- 0, /* tp_as_buffer */
- 0, /* flags */
- "ZPolicyDimHash class for Zorp", /* docstring */
- 0, 0, 0, 0,
- Z_PYTYPE_TRAILER
+ PyVarObject_HEAD_INIT(&PyType_Type, 0)
+ .tp_name = "Zorp Multidimensional hash",
+ .tp_basicsize = sizeof(ZPolicyDimHash),
+ .tp_dealloc = (destructor) z_policy_dim_hash_free,
+ .tp_as_mapping = &z_policy_dim_hash_mapping,
+ .tp_doc = "ZPolicyDimHash class for Zorp"
};
static void
View
@@ -614,30 +614,12 @@ static PyMethodDef z_policy_dispatch_methods[] =
static PyTypeObject z_policy_dispatch_type =
{
- PyObject_HEAD_INIT(&PyType_Type)
- 0,
- "ZPolicyDispatch",
- sizeof(ZPolicyDispatch),
- 0,
- (destructor) z_policy_dispatch_free,
- 0,
- (getattrfunc) z_policy_dispatch_getattr,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- "ZPolicyDispatch class for Zorp",
- 0, 0, 0, 0,
- Z_PYTYPE_TRAILER
+ PyVarObject_HEAD_INIT(&PyType_Type, 0)
+ .tp_name = "ZPolicyDispatch",
+ .tp_basicsize = sizeof(ZPolicyDispatch),
+ .tp_dealloc = (destructor) z_policy_dispatch_free,
+ .tp_getattr =(getattrfunc) z_policy_dispatch_getattr,
+ .tp_doc = "ZPolicyDispatch class for Zorp",
};
/**
View
@@ -69,30 +69,14 @@ static PyMethodDef py_zorp_stream_methods[] =
PyTypeObject z_policy_stream_type =
{
- PyObject_HEAD_INIT(&PyType_Type)
- 0,
- "ZPolicyStream",
- sizeof(ZPolicyStream),
- 0,
- (destructor) z_policy_stream_destroy,
- 0,
- (getattrfunc) z_policy_stream_getattr,
- (setattrfunc) z_policy_stream_setattr,
- 0,
- (reprfunc) z_policy_stream_repr,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- "ZPolicyStream class for Zorp",
- 0, 0, 0, 0,
- Z_PYTYPE_TRAILER
+ PyVarObject_HEAD_INIT(&PyType_Type, 0)
+ .tp_name = "ZPolicyStream",
+ .tp_basicsize = sizeof(ZPolicyStream),
+ .tp_dealloc = (destructor) z_policy_stream_destroy,
+ .tp_getattr = (getattrfunc) z_policy_stream_getattr,
+ .tp_setattr = (setattrfunc) z_policy_stream_setattr,
+ .tp_repr = (reprfunc) z_policy_stream_repr,
+ .tp_doc = "ZPolicyStream class for Zorp",
};
/**
Oops, something went wrong.

0 comments on commit d09a842

Please sign in to comment.