diff options
author | Yann Vernier <yann@algonet.se> | 2005-01-23 23:15:06 +0300 |
---|---|---|
committer | Yann Vernier <yann@algonet.se> | 2005-01-23 23:15:06 +0300 |
commit | 7f4f5deac44376ef15f3a9d6ca4089e264dc0fd1 (patch) | |
tree | 6abf0c2ffc372939d63e03d9d0ea10d14ce3a8db /source/blender/python/api2_2x/Mathutils.c | |
parent | 79c4e8a2470ba0f0e96fe48a858f10854429d4e2 (diff) |
Separated some variable declarations from the code, for wider compiler support.
Diffstat (limited to 'source/blender/python/api2_2x/Mathutils.c')
-rw-r--r-- | source/blender/python/api2_2x/Mathutils.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/python/api2_2x/Mathutils.c b/source/blender/python/api2_2x/Mathutils.c index 3476279cd41..e52997aecd8 100644 --- a/source/blender/python/api2_2x/Mathutils.c +++ b/source/blender/python/api2_2x/Mathutils.c @@ -272,12 +272,14 @@ static PyObject *M_Mathutils_Vector( PyObject * self, PyObject * args ) goto bad_args; // Invalid vector size } for (i=0; i<size; i++) { - PyObject *v=PySequence_GetItem(listObject, i); + PyObject *v, *f; + + v=PySequence_GetItem(listObject, i); if (v==NULL) { Py_DECREF(listObject); return NULL; // Failed to read sequence } - PyObject *f=PyNumber_Float(v); + f=PyNumber_Float(v); if(f==NULL) { Py_DECREF(v); goto bad_args; |