[pulseaudio-discuss] [PATCH] alsa-mixer: Get rid of a compiler warning.
Tanu Kaskinen
tanuk at iki.fi
Sun Mar 27 11:28:50 PDT 2011
On Sun, 2011-03-27 at 21:20 +0300, Tanu Kaskinen wrote:
> @@ -2018,14 +2018,8 @@ int pa_atoi(const char *s, int32_t *ret_i) {
> pa_assert(s);
> pa_assert(ret_i);
>
> - errno = 0;
> - l = strtol(s, &x, 0);
> -
> - if (!x || *x || errno) {
> - if (!errno)
> - errno = EINVAL;
> + if (pa_atol(s, &l) < 0)
> return -1;
> - }
>
> if ((int32_t) l != l) {
> errno = ERANGE;
Damn, this causes another warning: x is now an unused variable. Fixup
coming...
--
Tanu
More information about the pulseaudio-discuss
mailing list