No warnings, no errors, unit tests works, looks good to me. Pushed. Thanks!
On Monday 22 of April 2013 13:39:16 Martin Milata wrote:
Related to rhbz#951541.
Signed-off-by: Martin Milata <mmilata(a)redhat.com>
---
python/py_cluster.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/python/py_cluster.c b/python/py_cluster.c
index f5924a1..52ccf7e 100644
--- a/python/py_cluster.c
+++ b/python/py_cluster.c
@@ -158,7 +158,7 @@ sr_py_dendrogram_get_merge_level(PyObject *self,
PyObject *args) if (!PyArg_ParseTuple(args, "i", &i))
return NULL;
- if (i < 0 || i + 1 >= this->dendrogram->size)
+ if (i < 0 || i > this->dendrogram->size)
{
PyErr_SetString(PyExc_ValueError, "Merge level position out of
range"); return NULL;