[pulseaudio-discuss] [PATCH] Initialise write_volume callback

Colin Guthrie gmane at colin.guthr.ie
Mon Aug 15 07:13:20 PDT 2011


'Twas brillig, and Maarten Bosmans at 15/08/11 14:39 did gyre and gimble:
> 2011/8/14 Tanu Kaskinen <tanuk at iki.fi>:
>> So the problem is that after unlinking the sink, there may still be
>> pending volume changes. The crash could be worked around, in addition to
>> your solution, by removing the assertion and calling s->write_volume()
>> only if it's set, or by removing reset_callbacks() from
>> pa_sink_unlink(), or by adding a check to the beginning of
>> pa_sink_volume_change_apply() that returns immediately if the sink is
>> not linked.
> 
> This third approach is what I've taken in the first patch.
> 
> However, that did make the second patch necessary.
> Is this the right way to fix that, or is it a sign that this whole approach is faulty?

How about just setting it to 0 when doing the return? Does that no avoid
the need for the 2nd patch or does this just confuse the semantics of
the whole thing?

Col



-- 

Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mageia Contributor [http://www.mageia.org/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]



More information about the pulseaudio-discuss mailing list