Use range-based for loop in remote_add_target_side_commands
gdb/ChangeLog: * remote.c (remote_add_target_side_commands): Use range-based for loop.
This commit is contained in:
parent
7d45f3df96
commit
df97be551f
@ -1,3 +1,8 @@
|
|||||||
|
2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
|
||||||
|
|
||||||
|
* remote.c (remote_add_target_side_commands): Use range-based
|
||||||
|
for loop.
|
||||||
|
|
||||||
2017-03-03 Yao Qi <yao.qi@linaro.org>
|
2017-03-03 Yao Qi <yao.qi@linaro.org>
|
||||||
|
|
||||||
PR gdb/21165
|
PR gdb/21165
|
||||||
|
@ -9690,10 +9690,8 @@ remote_add_target_side_commands (struct gdbarch *gdbarch,
|
|||||||
|
|
||||||
/* Concatenate all the agent expressions that are commands into the
|
/* Concatenate all the agent expressions that are commands into the
|
||||||
cmds parameter. */
|
cmds parameter. */
|
||||||
for (int ix = 0; ix < bp_tgt->tcommands.size (); ix++)
|
for (agent_expr *aexpr : bp_tgt->tcommands)
|
||||||
{
|
{
|
||||||
struct agent_expr *aexpr = bp_tgt->tcommands[ix];
|
|
||||||
|
|
||||||
sprintf (buf, "X%x,", aexpr->len);
|
sprintf (buf, "X%x,", aexpr->len);
|
||||||
buf += strlen (buf);
|
buf += strlen (buf);
|
||||||
for (int i = 0; i < aexpr->len; ++i)
|
for (int i = 0; i < aexpr->len; ++i)
|
||||||
|
Loading…
Reference in New Issue
Block a user