From ff110c17f705976435ee14f2cde9c85f7334a56c Mon Sep 17 00:00:00 2001 From: Tamito Kajiyama Date: Mon, 3 Aug 2009 15:19:51 +0000 Subject: Fixed argument checking in __init__ methods of Interface1D, Predicates, Functions, and StrokeShader types. --- .../python/UnaryFunction0D/BPy_UnaryFunction0DVectorViewShape.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DVectorViewShape.cpp') diff --git a/source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DVectorViewShape.cpp b/source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DVectorViewShape.cpp index dd1854b86d8..74c8a9b9718 100644 --- a/source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DVectorViewShape.cpp +++ b/source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DVectorViewShape.cpp @@ -12,7 +12,7 @@ extern "C" { /////////////////////////////////////////////////////////////////////////////////////////// /*--------------- Python API function prototypes for UnaryFunction0DVectorViewShape instance -----------*/ -static int UnaryFunction0DVectorViewShape___init__(BPy_UnaryFunction0DVectorViewShape* self); +static int UnaryFunction0DVectorViewShape___init__(BPy_UnaryFunction0DVectorViewShape* self, PyObject *args, PyObject *kwds); static void UnaryFunction0DVectorViewShape___dealloc__(BPy_UnaryFunction0DVectorViewShape* self); static PyObject * UnaryFunction0DVectorViewShape___repr__(BPy_UnaryFunction0DVectorViewShape* self); @@ -131,8 +131,10 @@ PyMODINIT_FUNC UnaryFunction0DVectorViewShape_Init( PyObject *module ) { //------------------------INSTANCE METHODS ---------------------------------- -int UnaryFunction0DVectorViewShape___init__(BPy_UnaryFunction0DVectorViewShape* self) +int UnaryFunction0DVectorViewShape___init__(BPy_UnaryFunction0DVectorViewShape* self, PyObject *args, PyObject *kwds) { + if ( !PyArg_ParseTuple(args, "") ) + return -1; self->uf0D_vectorviewshape = new UnaryFunction0D< std::vector >(); self->uf0D_vectorviewshape->py_uf0D = (PyObject *)self; return 0; -- cgit v1.2.3