shell: fix shell instance name typo

Fixing typo from the original implementation in
44705b698c725166834f19d6fd5db2804f9a0d60, which resulted in
the name of current shell instance getting print over and over
again.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
This commit is contained in:
Yong Cong Sin 2023-12-05 17:53:50 +08:00 committed by Chris Friedt
commit d65cb1fe12

View file

@ -231,7 +231,7 @@ static int cmd_backends(const struct shell *sh, size_t argc, char **argv)
shell_print(sh, "Active shell backends:");
STRUCT_SECTION_FOREACH(shell, obj) {
shell_print(sh, " %2d. :%s (%s)", cnt++, obj->ctx->prompt, sh->name);
shell_print(sh, " %2d. :%s (%s)", cnt++, obj->ctx->prompt, obj->name);
}
return 0;