[pulseaudio-discuss] [PATCH 2/4] Solaris: build fixes

Lennart Poettering lennart at poettering.net
Thu Aug 20 16:29:18 PDT 2009


On Fri, 21.08.09 03:49, Finn Thain (fthain at telegraphics.com.au) wrote:

> Fix bit rot due to recent flat volume changes.

Hmm, this patch got corrupted some way (probably due to pasting it
inline in your mailer?) and doesn't apply to my tree. Tried a lot of
tricks but was unsucessful in the end. Could you resend this one (and
the others too) and include it as an uncorrupted attachment or --
preferably -- as proper git formatted patch?

Otherwise I'd be happy to merge your patches 2-3 without changes!

Thanks,

Lennart

>
> --- pulseaudio-0.9.16-test5/src/modules/module-solaris.c	Thu Jul 23 23:40:47 2009
> +++ pulseaudio-0.9.16-test5/src/modules/module-solaris.c	Thu Aug 20 14:44:59 2009
> @@ -479,7 +479,7 @@
>      if (u->fd >= 0) {
>          AUDIO_INITINFO(&info);
>
> -        info.play.gain = pa_cvolume_max(&s->virtual_volume) * AUDIO_MAX_GAIN / PA_VOLUME_NORM;
> +        info.play.gain = pa_cvolume_max(&s->real_volume) * AUDIO_MAX_GAIN / PA_VOLUME_NORM;
>          assert(info.play.gain <= AUDIO_MAX_GAIN);
>
>          if (ioctl(u->fd, AUDIO_SETINFO, &info) < 0) {
> @@ -501,8 +501,7 @@
>          if (ioctl(u->fd, AUDIO_GETINFO, &info) < 0)
>              pa_log("AUDIO_SETINFO: %s", pa_cstrerror(errno));
>          else
> -            pa_cvolume_set(&s->virtual_volume, s->sample_spec.channels,
> -                info.play.gain * PA_VOLUME_NORM / AUDIO_MAX_GAIN);
> +            pa_cvolume_set(&s->real_volume, s->sample_spec.channels, info.play.gain * PA_VOLUME_NORM / AUDIO_MAX_GAIN);
>      }
>  }
>
> @@ -515,7 +514,7 @@
>      if (u->fd >= 0) {
>          AUDIO_INITINFO(&info);
>
> -        info.play.gain = pa_cvolume_max(&s->virtual_volume) * AUDIO_MAX_GAIN / PA_VOLUME_NORM;
> +        info.play.gain = pa_cvolume_max(&s->volume) * AUDIO_MAX_GAIN / PA_VOLUME_NORM;
>          assert(info.play.gain <= AUDIO_MAX_GAIN);
>
>          if (ioctl(u->fd, AUDIO_SETINFO, &info) < 0) {
> @@ -537,8 +536,7 @@
>          if (ioctl(u->fd, AUDIO_GETINFO, &info) < 0)
>              pa_log("AUDIO_SETINFO: %s", pa_cstrerror(errno));
>          else
> -            pa_cvolume_set(&s->virtual_volume, s->sample_spec.channels,
> -                info.play.gain * PA_VOLUME_NORM / AUDIO_MAX_GAIN);
> +            pa_cvolume_set(&s->volume, s->sample_spec.channels, info.play.gain * PA_VOLUME_NORM / AUDIO_MAX_GAIN);
>      }
>  }
>
> @@ -797,7 +795,7 @@
>      pa_log_debug("caught signal");
>
>      if (u->sink) {
> -        pa_sink_get_volume(u->sink, TRUE, FALSE);
> +        pa_sink_get_volume(u->sink, TRUE);
>          pa_sink_get_mute(u->sink, TRUE);
>      }
>
> _______________________________________________
> pulseaudio-discuss mailing list
> pulseaudio-discuss at mail.0pointer.de
> https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss


Lennart

-- 
Lennart Poettering                        Red Hat, Inc.
lennart [at] poettering [dot] net         ICQ# 11060553
http://0pointer.net/lennart/           GnuPG 0x1A015CC4



More information about the pulseaudio-discuss mailing list