command: Cleaned up cmd_connect_reset

This commit is contained in:
dragonmux 2022-07-26 12:31:49 +01:00 committed by Piotr Esden-Tempski
parent 567fc631f0
commit bffd3d3d14
1 changed files with 5 additions and 7 deletions

View File

@ -410,15 +410,13 @@ static bool cmd_connect_reset(target *t, int argc, const char **argv)
{
(void)t;
bool print_status = false;
if (argc == 1) {
if (argc == 1)
print_status = true;
} else if (argc == 2) {
if (parse_enable_or_disable(argv[1], &connect_assert_nrst)) {
else if (argc == 2) {
if (parse_enable_or_disable(argv[1], &connect_assert_nrst))
print_status = true;
}
} else {
gdb_outf("Unrecognized command format\n");
}
} else
gdb_out("Unrecognized command format\n");
if (print_status) {
gdb_outf("Assert nRST during connect: %s\n", connect_assert_nrst ? "enabled" : "disabled");