Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/gameengine/Ketsji/KX_PythonSeq.cpp')
-rw-r--r--source/gameengine/Ketsji/KX_PythonSeq.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/gameengine/Ketsji/KX_PythonSeq.cpp b/source/gameengine/Ketsji/KX_PythonSeq.cpp
index 6b4d88709e8..f0e11645bc1 100644
--- a/source/gameengine/Ketsji/KX_PythonSeq.cpp
+++ b/source/gameengine/Ketsji/KX_PythonSeq.cpp
@@ -100,7 +100,7 @@ static Py_ssize_t KX_PythonSeq_len( PyObject *self )
}
}
-static PyObject *KX_PythonSeq_getIndex(PyObject *self, int index)
+static PyObject *KX_PythonSeq_getIndex(PyObject *self, Py_ssize_t index)
{
PyObjectPlus *self_plus= BGE_PROXY_REF(((KX_PythonSeq *)self)->base);
@@ -273,8 +273,8 @@ static PyObject * KX_PythonSeq_subscript(PyObject *self, PyObject *key)
return NULL;
}
- if (PyLong_Check(key)) {
- return KX_PythonSeq_getIndex(self, PyLong_AsSsize_t( key ));
+ if (PyIndex_Check(key)) {
+ return KX_PythonSeq_getIndex(self, PyLong_AsSsize_t(key));
}
else if ( PyUnicode_Check(key) ) {
const char *name = _PyUnicode_AsString(key);