[Spice-devel] [spice-gtk PATCH v6 2/4] audio: spice-pulse implement async volume-info

Marc-André Lureau marcandre.lureau at gmail.com
Wed Apr 15 10:29:12 PDT 2015


On Wed, Apr 15, 2015 at 2:12 PM, Victor Toso <victortoso at redhat.com> wrote:

> > > +
> > > +    if (info->channel_map.channels == 0) {
> > > +        SPICE_DEBUG("%s - Number of channels stored is zero. Ignore.
> > > (%s)", __func__, info->name);
> > > +        return;
> > > +
> >
> > What if there is already a playing stream, is this going to reset it to
> > restore value?
>
> Sorry, I think I did not understand.
>
> This if () is only to avoid issues with restore-info. If the number of
> channels stored in pulseaudio database is zero, probably we are not
> interested in the volume-information.
>
>
I'm not sure when I hit this issue, probably when you have a new
> database and we start the pulseaudio context but do not have any audio
> stream. I believe it saved the application information in the database,
> with default values but I'm not sure.
>

It's not about that if, it's actually about the function and the code after
that change pstream->info. If there is already a info_cb that did update
info, you'll reset it here.

-- 
Marc-André Lureau
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/spice-devel/attachments/20150415/be515dc3/attachment.html>


More information about the Spice-devel mailing list