return ERROR_OK;
}
- for (index = 0; index < DIM(svf_statemoves); index++)
+ for (index = 0; index < ARRAY_SIZE(svf_statemoves); index++)
{
if ((svf_statemoves[index].from == state_from)
&& (svf_statemoves[index].to == state_to))
int ret = ERROR_OK;
long long time_ago;
- if ((argc < 1) || (argc > (1 + SVF_NUM_OF_OPTIONS)))
+ if ((CMD_ARGC < 1) || (CMD_ARGC > (1 + SVF_NUM_OF_OPTIONS)))
{
command_print(cmd_ctx, "usage: svf <file> [quiet]");
return ERROR_FAIL;
// parse variant
svf_quiet = 0;
- for (unsigned i = 1; i < argc; i++)
+ for (unsigned i = 1; i < CMD_ARGC; i++)
{
if (!strcmp(args[i], "quiet"))
{
*/
command = svf_find_string_in_array(argus[0],
- (char **)svf_command_name, DIM(svf_command_name));
+ (char **)svf_command_name, ARRAY_SIZE(svf_command_name));
switch (command)
{
case ENDDR:
}
i_tmp = svf_find_string_in_array(argus[1],
(char **)svf_trst_mode_name,
- DIM(svf_trst_mode_name));
+ ARRAY_SIZE(svf_trst_mode_name));
switch (i_tmp)
{
case TRST_ON: