shell: Fix various build issues with string formattors

We get a few different CI failures associated with data type
differences on various platforms.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
Kumar Gala 2021-10-19 09:41:40 -05:00 committed by Kumar Gala
commit fb4d68973f
4 changed files with 6 additions and 6 deletions

View file

@ -22,11 +22,11 @@ static int cmd_get_device_id(const struct shell *shell, size_t argc, char **argv
shell_error(shell, "Not supported by hardware");
return -ENOTSUP;
} else if (length < 0) {
shell_error(shell, "Error: %d", length);
shell_error(shell, "Error: %zd", length);
return length;
}
shell_fprintf(shell, SHELL_NORMAL, "Length: %d\n", length);
shell_fprintf(shell, SHELL_NORMAL, "Length: %zd\n", length);
shell_fprintf(shell, SHELL_NORMAL, "ID: 0x");
for (i = 0 ; i < length ; i++) {