diff options
author | Paul Selkirk <paul@psgd.org> | 2017-10-11 21:26:27 -0400 |
---|---|---|
committer | Paul Selkirk <paul@psgd.org> | 2017-10-11 21:26:27 -0400 |
commit | b159bf0bb24a99c7d3ff1b3855f840add63198e5 (patch) | |
tree | 9e3861da94bb69412025ef51db5a686d717d7a84 /projects/cli-test/mgmt-keystore.c | |
parent | 4026cce22d330d3b9c4b218dd2e19d4f60412e05 (diff) |
Cleanup 'unused parameter' warnings, a couple of which are actual coding errors.
Diffstat (limited to 'projects/cli-test/mgmt-keystore.c')
-rw-r--r-- | projects/cli-test/mgmt-keystore.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/projects/cli-test/mgmt-keystore.c b/projects/cli-test/mgmt-keystore.c index bc2bc0c..ea1f263 100644 --- a/projects/cli-test/mgmt-keystore.c +++ b/projects/cli-test/mgmt-keystore.c @@ -59,6 +59,8 @@ static int cmd_keystore_set_pin(struct cli_def *cli, const char *command, char * hal_error_t status; hal_client_handle_t client = { -1 }; + command = command; + if (argc != 2) { cli_print(cli, "Wrong number of arguments (%i).", argc); cli_print(cli, "Syntax: keystore set pin <user|so|wheel> <pin>"); @@ -91,6 +93,8 @@ static int cmd_keystore_clear_pin(struct cli_def *cli, const char *command, char hal_error_t status; hal_client_handle_t client = { -1 }; + command = command; + if (argc != 1) { cli_print(cli, "Wrong number of arguments (%i).", argc); cli_print(cli, "Syntax: keystore clear pin <user|so|wheel>"); @@ -122,6 +126,8 @@ static int cmd_keystore_set_pin_iterations(struct cli_def *cli, const char *comm hal_error_t status; hal_client_handle_t client = { -1 }; + command = command; + if (argc != 1) { cli_print(cli, "Wrong number of arguments (%i).", argc); cli_print(cli, "Syntax: keystore set pin iterations <number>"); @@ -156,6 +162,8 @@ static int cmd_keystore_set_key(struct cli_def *cli, const char *command, char * hal_error_t status; int hint = 0; + command = command; + if (argc != 2) { cli_print(cli, "Wrong number of arguments (%i).", argc); cli_print(cli, "Syntax: keystore set key <name> <der>"); @@ -187,6 +195,8 @@ static int cmd_keystore_delete_key(struct cli_def *cli, const char *command, cha hal_error_t status; hal_uuid_t name; + command = command; + if (argc != 1) { cli_print(cli, "Wrong number of arguments (%i).", argc); cli_print(cli, "Syntax: keystore delete key <name>"); @@ -214,6 +224,10 @@ static int cmd_keystore_show_data(struct cli_def *cli, const char *command, char uint8_t buf[KEYSTORE_PAGE_SIZE]; uint32_t i; + command = command; + argv = argv; + argc = argc; + if (keystore_check_id() != 1) { cli_print(cli, "ERROR: The keystore memory is not accessible."); } @@ -318,6 +332,10 @@ static int show_keys(struct cli_def *cli, const char *title) static int cmd_keystore_show_keys(struct cli_def *cli, const char *command, char *argv[], int argc) { + command = command; + argv = argv; + argc = argc; + if (show_keys(cli, "Keystore:")) return CLI_OK; else @@ -329,6 +347,8 @@ static int cmd_keystore_erase(struct cli_def *cli, const char *command, char *ar hal_error_t err; int status; + command = command; + if (argc != 1 || strcmp(argv[0], "YesIAmSure") != 0) { cli_print(cli, "Syntax: keystore erase YesIAmSure"); return CLI_ERROR; |