[vlc-devel] [PATCH] opengl: remove a cast to vlc_object_t*
Rémi Denis-Courmont
remi at remlab.net
Thu Apr 4 12:01:03 CEST 2019
No objections from me.
Le 4 avril 2019 12:54:42 GMT+03:00, Steve Lhomme <robux4 at ycbcr.xyz> a écrit :
>It's better to use the macro that find found if/when the vout_window_t
>is not
>a vlc_object_t.
>---
> src/video_output/opengl.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
>diff --git a/src/video_output/opengl.c b/src/video_output/opengl.c
>index 93527beea7..f17c8ff05c 100644
>--- a/src/video_output/opengl.c
>+++ b/src/video_output/opengl.c
>@@ -64,7 +64,6 @@ vlc_gl_t *vlc_gl_Create(const struct vout_display_cfg
>*restrict cfg,
> unsigned flags, const char *name)
> {
> vout_window_t *wnd = cfg->window;
>- vlc_object_t *parent = (vlc_object_t *)wnd;
> struct vlc_gl_priv_t *glpriv;
> const char *type;
>
>@@ -80,7 +79,7 @@ vlc_gl_t *vlc_gl_Create(const struct vout_display_cfg
>*restrict cfg,
> return NULL;
> }
>
>- glpriv = vlc_custom_create(parent, sizeof (*glpriv), "gl");
>+ glpriv = vlc_custom_create(VLC_OBJECT(wnd), sizeof (*glpriv),
>"gl");
> if (unlikely(glpriv == NULL))
> return NULL;
>
>--
>2.17.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/20190404/30c6c644/attachment.html>
More information about the vlc-devel
mailing list