[vlc-devel] [PATCH] lib: media: reset parsed_status on new parse request

Rémi Denis-Courmont remi at remlab.net
Tue Oct 22 13:28:30 CEST 2019


Hi,

Just a few days ago, Hugo made the case that media can be used in multiple threads. Now, this seems to be doing the exact opposite, propose a design that won't work if multiple threads use the same media (and try to parse it).

This does not add up. I'm not sure which way is right, but it can't be both.

Le 22 octobre 2019 13:45:14 GMT+03:00, Thomas Guillem <thomas at gllm.fr> a écrit :
>Otherwise, events are not propagated after the first request.
>
>cf. f37171e57b0d0af922215ffed19111a4f317fb29
>---
> lib/media.c | 3 +++
> 1 file changed, 3 insertions(+)
>
>diff --git a/lib/media.c b/lib/media.c
>index dd0513633f6..f0f1adb1bcf 100644
>--- a/lib/media.c
>+++ b/lib/media.c
>@@ -781,7 +781,10 @@ static int media_parse(libvlc_media_t *media, bool
>b_async,
>     needed = !media->has_asked_preparse;
>     media->has_asked_preparse = true;
>     if (needed)
>+    {
>         media->is_parsed = false;
>+        media->parsed_status = 0;
>+    }
>     vlc_mutex_unlock(&media->parsed_lock);
> 
>     if (needed)
>-- 
>2.20.1
>
>_______________________________________________
>vlc-devel mailing list
>To unsubscribe or modify your subscription options:
>https://mailman.videolan.org/listinfo/vlc-devel

-- 
Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez excuser ma brièveté.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20191022/3267766a/attachment.html>


More information about the vlc-devel mailing list