<html>
<head>
<base href="https://bugs.webkit.org/" />
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - [GStreamer] Use RunLoop::Timer instead of GMainLoopSource in video sink"
href="https://bugs.webkit.org/show_bug.cgi?id=150807#c10">Comment # 10</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - [GStreamer] Use RunLoop::Timer instead of GMainLoopSource in video sink"
href="https://bugs.webkit.org/show_bug.cgi?id=150807">bug 150807</a>
from <span class="vcard"><a class="email" href="mailto:cgarcia@igalia.com" title="Carlos Garcia Campos <cgarcia@igalia.com>"> <span class="fn">Carlos Garcia Campos</span></a>
</span></b>
<pre>(In reply to <a href="show_bug.cgi?id=150807#c9">comment #9</a>)
<span class="quote">> Comment on <span class=""><a href="attachment.cgi?id=264681&action=diff" name="attach_264681" title="Updated patch">attachment 264681</a> <a href="attachment.cgi?id=264681&action=edit" title="Updated patch">[details]</a></span>
> Updated patch
>
> View in context:
> <a href="https://bugs.webkit.org/attachment.cgi?id=264681&action=review">https://bugs.webkit.org/attachment.cgi?id=264681&action=review</a>
>
> >>> Source/WebCore/platform/graphics/gstreamer/VideoSinkGStreamer.cpp:92
> >>> + LockHolder locker(m_sampleMutex);
> >>
> >> I'm still stuck on this. in requestRender() m_timer operation is protected, here it's not.
> >>
> >> Regarding previous behavior, timeoutSource was never cancelled after scheduling, except when WebKitVideoSinkPrivate was destroyed. This technically deviates from that.
> >
> > It's not actually the timer what is protected, but the sample, we need to hold the lock for the condition wait.
>
> The timer is protected in requestRender(), and I don't see any reason why it
> wouldn't be protected here.</span >
It's protected only because it needs to happen between changing the sample and the condition wait. In stop() we can simply cancel the timer before waiting to acquire the lock. I can move it inside the protection if you think it's a problem</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>