[vlc-devel] [PATCH 2/5] input: es_out_timeshift: use same offset for queries
Rémi Denis-Courmont
remi at remlab.net
Tue Apr 21 14:17:22 CEST 2020
Hi,
Not sure what you're trying to do but same offset is typically not enough for compatibility, so this is probably putting brown paper over a bug...
Le 20 avril 2020 21:27:26 GMT+03:00, Francois Cartegnie <fcvlcdev at free.fr> a écrit :
>If you end up reading a pointer instead of query,
>all priv/public controls guards breaks.
>---
> src/input/es_out_timeshift.c | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
>diff --git a/src/input/es_out_timeshift.c
>b/src/input/es_out_timeshift.c
>index 7c1d2d0095..dbff49d4c5 100644
>--- a/src/input/es_out_timeshift.c
>+++ b/src/input/es_out_timeshift.c
>@@ -88,8 +88,8 @@ typedef struct attribute_packed
>
> typedef struct attribute_packed
> {
>- input_source_t *in;
> int i_query;
>+ input_source_t *in;
>
> union
> {
>@@ -158,6 +158,10 @@ typedef struct attribute_packed
> } u;
> } ts_cmd_privcontrol_t;
>
>+static_assert(offsetof(ts_cmd_control_t, i_query) ==
>+ offsetof(ts_cmd_privcontrol_t, i_query),
>+ "query control offset is inconsistent");
>+
> typedef struct attribute_packed
> {
> int8_t i_type;
>--
>2.25.3
>
>_______________________________________________
>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/20200421/1ffa7d6c/attachment.html>
More information about the vlc-devel
mailing list