diff -ur t1utils-1.42/clp.c t1utils-src/clp.c --- t1utils-1.42/clp.c Wed Oct 28 00:08:00 2020 +++ t1utils-src/clp.c Sat Oct 31 13:01:47 2020 @@ -1095,22 +1095,28 @@ parse_int(Clp_Parser* clp, const char* arg, int complain, void* user_data) { const char *val; + char *temp; uintptr_t type = (uintptr_t) user_data; if (*arg == 0 || isspace((unsigned char) *arg) || ((type & 1) && *arg == '-')) val = arg; else if (type & 1) { /* unsigned */ #if HAVE_STRTOUL - clp->val.ul = strtoul(arg, (char **) &val, 0); + clp->val.ul = strtoul(arg, &temp, 0); + val = temp; #else /* don't bother really trying to do it right */ if (arg[0] == '-') val = arg; - else - clp->val.l = strtol(arg, (char **) &val, 0); + else { + clp->val.l = strtol(arg, &temp, 0); + val = temp; + } #endif - } else - clp->val.l = strtol(arg, (char **) &val, 0); + } else { + clp->val.l = strtol(arg, &temp, 0); + val = temp; + } if (type <= 1) clp->val.u = (unsigned) clp->val.ul; if (*arg != 0 && *val == 0) @@ -1130,11 +1136,14 @@ parse_double(Clp_Parser *clp, const char *arg, int complain, void *user_data) { const char *val; + char *temp; (void)user_data; if (*arg == 0 || isspace((unsigned char) *arg)) val = arg; - else - clp->val.d = strtod(arg, (char **) &val); + else { + clp->val.d = strtod(arg, &temp); + val = temp; + } if (*arg != 0 && *val == 0) return 1; else {