tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: [PATCH] strto*l() nonstandard behaviour fix



> strto*l() functions should operate with bases from 2 till 36 and 0 as
> well for special cases.  [...]

>       /*
> +      * Check base range. We only accept bases from 2 to 36 as
> +      * described in ISO/IEC 9899:1999 7.20.1.4.
> +      */
> +     if (base < 2 || base > 36) {
> +             errno = EINVAL;
> +             return 0;
> +     }
> +
> +     /*

Is there any requirement to reject other base values, or does the spec
merely require support for 2-36 and 0?

/~\ The ASCII                           der Mouse
\ / Ribbon Campaign
 X  Against HTML                mouse%rodents-montreal.org@localhost
/ \ Email!           7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B


Home | Main Index | Thread Index | Old Index