From 612707761357b5ab69f552a9120d9cf92340c6cd Mon Sep 17 00:00:00 2001 From: Tim Newsome Date: Thu, 13 Oct 2022 13:29:15 -0700 Subject: [PATCH] target/breakpoints: better wording for error reason Imported from https://github.com/riscv-collab/riscv-openocd/pull/767 Extracted small part of target/riscv: Don't resume unavailable harts. Change-Id: Id6617230cfdadf93ba402e60fb704bdfe7af5c1e Signed-off-by: Tim Newsome Reviewed-on: https://review.openocd.org/c/openocd/+/8921 Tested-by: jenkins Reviewed-by: Evgeniy Naydanov Reviewed-by: Antonio Borneo Reviewed-by: Tomas Vanek --- src/target/breakpoints.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/target/breakpoints.c b/src/target/breakpoints.c index 7254eac7d..d65e5594f 100644 --- a/src/target/breakpoints.c +++ b/src/target/breakpoints.c @@ -78,7 +78,7 @@ static int breakpoint_add_internal(struct target *target, reason = "resource not available"; goto fail; case ERROR_TARGET_NOT_HALTED: - reason = "target running"; + reason = "target not halted"; goto fail; default: reason = "unknown reason"; @@ -523,7 +523,7 @@ static int watchpoint_add_internal(struct target *target, target_addr_t address, reason = "resource not available"; goto bye; case ERROR_TARGET_NOT_HALTED: - reason = "target running"; + reason = "target not halted"; goto bye; default: reason = "unrecognized error";