diff options
author | Philippe Waroquiers <philippe.waroquiers@skynet.be> | 2018-05-19 08:54:44 +0200 |
---|---|---|
committer | Philippe Waroquiers <philippe.waroquiers@skynet.be> | 2018-05-19 08:54:44 +0200 |
commit | 59f66be3aca7ef310c1d4464e93b251fe87135e0 (patch) | |
tree | 4f1e657e7ddcdc56f3b3fb28df74f191bed03810 /gdb | |
parent | 50c65c2d60b371b8b85a804a5a71bf967ba9b355 (diff) | |
download | gdb-59f66be3aca7ef310c1d4464e93b251fe87135e0.zip gdb-59f66be3aca7ef310c1d4464e93b251fe87135e0.tar.gz gdb-59f66be3aca7ef310c1d4464e93b251fe87135e0.tar.bz2 |
Remove useless variable int i in backtrace_command_1
value of int i was not used in the loop or after the loop.
Pushed as obvious.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 4 | ||||
-rw-r--r-- | gdb/stack.c | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 4c213ae..b15d8d1 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,9 @@ 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be> + * stack.c (backtrace_command_1): Remove useless variable int i. + +2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be> + * stack.c (print_frame_info): Fix comment. 2018-05-18 Tom Tromey <tom@tromey.com> diff --git a/gdb/stack.c b/gdb/stack.c index c44423c..74c9253 100644 --- a/gdb/stack.c +++ b/gdb/stack.c @@ -1696,7 +1696,6 @@ backtrace_command_1 (const char *count_exp, frame_filter_flags flags, { struct frame_info *fi; int count; - int i; int py_start = 0, py_end = 0; enum ext_lang_bt_status result = EXT_LANG_BT_ERROR; @@ -1779,7 +1778,7 @@ backtrace_command_1 (const char *count_exp, frame_filter_flags flags, count = -1; } - for (i = 0, fi = trailing; fi && count--; i++, fi = get_prev_frame (fi)) + for (fi = trailing; fi && count--; fi = get_prev_frame (fi)) { QUIT; |