Use even more conventional conversion routines.
Reported by: peterj@
This commit is contained in:
parent
d6a381f8c9
commit
34be301210
@ -943,7 +943,7 @@ indextooffset(char *s)
|
||||
char *es;
|
||||
|
||||
if (s[0] == '+' || s[0] == '-') {
|
||||
i = strtod (s, &es);
|
||||
i = strtol (s, &es, 10);
|
||||
if (*es != '\0') /* trailing junk */
|
||||
errx (1, "Invalid specifier format: %s\n", s);
|
||||
return (i);
|
||||
|
Loading…
Reference in New Issue
Block a user