This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH] python/py-unwind.c (unwind_infopy_str): Fix use of VEC_iterate.
- From: Doug Evans <dje at google dot com>
- To: gdb-patches at sourceware dot org
- Date: Thu, 03 Nov 2016 17:55:48 +0000
- Subject: [PATCH] python/py-unwind.c (unwind_infopy_str): Fix use of VEC_iterate.
- Authentication-results: sourceware.org; auth=none
Hi.
I happened to notice this while reading the code.
2016-11-03 Doug Evans <dje@google.com>
* python/py-unwind.c (unwind_infopy_str): Fix use of VEC_iterate.
diff --git a/gdb/python/py-unwind.c b/gdb/python/py-unwind.c
index cc685ae..92ce138 100644
--- a/gdb/python/py-unwind.c
+++ b/gdb/python/py-unwind.c
@@ -212,9 +212,7 @@ unwind_infopy_str (PyObject *self)
get_user_print_options (&opts);
fprintf_unfiltered (strfile, "\nSaved registers: (");
- for (i = 0;
- i < VEC_iterate (saved_reg, unwind_info->saved_regs, i, reg);
- i++)
+ for (i = 0; VEC_iterate (saved_reg, unwind_info->saved_regs, i, reg);
i++)
{
struct value *value = value_object_to_value (reg->value);