[PATCH weston] gl-renderer: Set renderer to NULL after destroyed
Ucan, Emre (ADITG/SW1)
eucan at de.adit-jv.com
Tue Aug 11 23:17:16 PDT 2015
Hi Daniel,
I saw now the patch of Dawid. Yeah, it is fine then.
I don’t know why I missed it before.
Best regards
Emre Ucan
> -----Original Message-----
> From: wayland-devel [mailto:wayland-devel-
> bounces at lists.freedesktop.org] On Behalf Of Daniel Stone
> Sent: Dienstag, 11. August 2015 20:12
> To: Ucan, Emre (ADITG/SW1)
> Cc: Dawid Gajownik; wayland-devel at lists.freedesktop.org
> Subject: Re: [PATCH weston] gl-renderer: Set renderer to NULL after
> destroyed
>
> Hi Emre,
>
> On 11 August 2015 at 14:45, Ucan, Emre (ADITG/SW1) <eucan at de.adit-
> jv.com> wrote:
> > Hi,
> >
> >> -----Original Message-----
> >> From: Dawid Gajownik [mailto:gajownik at gmail.com]
> >> Sent: Dienstag, 11. August 2015 15:31
> >> To: Ucan, Emre (ADITG/SW1)
> >> Cc: wayland-devel at lists.freedesktop.org
> >> Subject: Re: [PATCH weston] gl-renderer: Set renderer to NULL after
> >> destroyed
> >>
> >> On Tue, Aug 11, 2015 at 4:09 AM, Ucan, Emre (ADITG/SW1)
> >> <eucan at de.adit- jv.com> wrote:
> >> > The pointer of the renderer in the compositor data structure is
> >> > controlled in weston_compositor_shutdown. When it is not NULL, the
> >> > destroy method of the renderer is called. Therefore, the renderer
> >> > pointer should be set to NULL in gl_renderer_destroy, so that it
> >> > would not
> >> be called when it is already destroyed.
> >>
> >> Hey,
> >>
> >> when it's destroyed twice? In X11 backend in x11_backend_create()?
> >> Maybe we should not call renderer->destroy(compositor) directly but
> >> use weston_compositor_shutdown(compositor)?
> >>
> >> Or did you find another case when renderer is already destroyed?
> >
> > Yes, in many places:
> > - fbdev_compositor_create
> > - drm_compositor_create
> > - rpi_compositor_create
> > - wayland_compositor_create
>
> As far as I can tell, this is no longer an issue in current git. None of the
> backends appear to manually destroy the renderer as well as calling
> weston_compositor_shutdown, and the core code does not call
> weston_compositor_shutdown if backend_init fails. So I think this particular
> problem should be OK now?
>
> Cheers,
> Daniel
> _______________________________________________
> wayland-devel mailing list
> wayland-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
More information about the wayland-devel
mailing list