Quell clang warnings in tests directory

Remove unnecessary parentheses in memcsv.c.

Fix cfp->u.c.combostr as old check was always true since it's statically
allocated.

RRR
Mike W9MDB
libusb-1-0
Michael Black 2016-02-06 01:05:40 -06:00 zatwierdzone przez Nate Bargmann
rodzic 61a0e77110
commit 95a99fa37d
2 zmienionych plików z 2 dodań i 2 usunięć

Wyświetl plik

@ -184,7 +184,7 @@ static int tokenize_line( char *line, char **token_list, size_t siz, char delim
tok = mystrtok( NULL, delim );
// printf("Next token: %s\n", tok );
/* If NULL, no more tokens left */
if( (tok == NULL) ) break;
if(tok == NULL) break;
/* Add token to the list */
token_list[ i++ ] = tok;
}

Wyświetl plik

@ -1115,7 +1115,7 @@ int print_conf_list(const struct confparams *cfp, rig_ptr_t data)
cfp->u.n.min, cfp->u.n.max, cfp->u.n.step);
break;
case RIG_CONF_COMBO:
if (!cfp->u.c.combostr)
if (!cfp->u.c.combostr[0])
break;
printf("\tCombo: %s", cfp->u.c.combostr[0]);
for (i = 1 ; i < RIG_COMBO_MAX && cfp->u.c.combostr[i]; i++)