target/arm_tpiu: Make error message easier to understand

Change-Id: Idddc31e34a67641c32d041c89d01fe2126ec5ddb
Signed-off-by: Marc Schink <dev@zapb.de>
Reviewed-on: https://review.openocd.org/c/openocd/+/6328
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
This commit is contained in:
Marc Schink 2021-06-22 11:47:26 +02:00 committed by Antonio Borneo
parent e8e62c5aca
commit 29e2a74516
1 changed files with 2 additions and 1 deletions

View File

@ -886,7 +886,8 @@ static int arm_tpiu_swo_create(Jim_Interp *interp, struct arm_tpiu_swo_object *o
/* does this command exist? */
cmd = Jim_GetCommand(interp, Jim_NewStringObj(interp, obj->name, -1), JIM_NONE);
if (cmd) {
Jim_SetResultFormatted(interp, "Command: %s Exists", obj->name);
Jim_SetResultFormatted(interp, "cannot create TPIU object because a command with name '%s' already exists",
obj->name);
return JIM_ERR;
}