TRILABS-81 coverity tools fixes

This commit is contained in:
Allen Byrne
2018-11-09 08:13:07 -06:00
parent f97de01d36
commit 4da93e9d6f
30 changed files with 647 additions and 653 deletions

View File

@@ -350,7 +350,7 @@ check_n_input( const char *str )
unsigned i;
char c;
for (i = 0; i < strlen(str); i++) {
for (i = 0; i < HDstrlen(str); i++) {
c = str[i];
if (i == 0) {
if (c < 49 || c > 57) /* ascii values between 1 and 9 */
@@ -387,7 +387,7 @@ check_p_input( const char *str )
the atof return value on a hexadecimal input is different
on some systems; we do a character check for this
*/
if (strlen(str) > 2 && str[0] == '0' && str[1] == 'x')
if (HDstrlen(str) > 2 && str[0] == '0' && str[1] == 'x')
return -1;
x = atof(str);
@@ -421,7 +421,7 @@ check_d_input( const char *str )
the atof return value on a hexadecimal input is different
on some systems; we do a character check for this
*/
if (strlen(str) > 2 && str[0] == '0' && str[1] == 'x')
if (HDstrlen(str) > 2 && str[0] == '0' && str[1] == 'x')
return -1;
x = atof(str);