aboutsummaryrefslogtreecommitdiff
path: root/gdb/python
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/python')
-rw-r--r--gdb/python/py-linetable.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/python/py-linetable.c b/gdb/python/py-linetable.c
index 8c01a0ee..e0449a6 100644
--- a/gdb/python/py-linetable.c
+++ b/gdb/python/py-linetable.c
@@ -215,7 +215,7 @@ ltpy_has_line (PyObject *self, PyObject *args)
return NULL;
}
- for (index = 0; index <= LINETABLE (symtab)->nitems; index++)
+ for (index = 0; index < LINETABLE (symtab)->nitems; index++)
{
struct linetable_entry *item = &(symtab->linetable->item[index]);
if (item->line == py_line)
@@ -252,7 +252,7 @@ ltpy_get_all_source_lines (PyObject *self, PyObject *args)
if (source_dict == NULL)
return NULL;
- for (index = 0; index <= LINETABLE (symtab)->nitems; index++)
+ for (index = 0; index < LINETABLE (symtab)->nitems; index++)
{
item = &(LINETABLE (symtab)->item[index]);