traceroute: fix help text to not show -6 when traceroute6 is off
[oweals/busybox.git] / libbb / xatonum_template.c
index 5e0bb59e6b1bbbd1198a48a0860c3158ede01691..c97a4b795fe82b38d2b6836746d6634034f02105 100644 (file)
@@ -25,9 +25,8 @@ unsigned type FAST_FUNC xstrtou(_range_sfx)(const char *numstr, int base,
        int old_errno;
        char *e;
 
-       /* Disallow '-' and any leading whitespace. Make sure we get the
-        * actual isspace function rather than a macro implementaion. */
-       if (*numstr == '-' || *numstr == '+' || (isspace)(*numstr))
+       /* Disallow '-' and any leading whitespace. */
+       if (*numstr == '-' || *numstr == '+' || isspace(*numstr))
                goto inval;
 
        /* Since this is a lib function, we're not allowed to reset errno to 0.
@@ -157,6 +156,11 @@ type FAST_FUNC xstrto(_range)(const char *numstr, int base, type lower, type upp
        return xstrto(_range_sfx)(numstr, base, lower, upper, NULL);
 }
 
+type FAST_FUNC xstrto()(const char *numstr, int base)
+{
+       return xstrto(_range_sfx)(numstr, base, XSTR_TYPE_MIN, XSTR_TYPE_MAX, NULL);
+}
+
 type FAST_FUNC xato(_range_sfx)(const char *numstr,
                type lower,
                type upper,