[PATCH weston] shell: End grab if the grabbed shell surface has been destroyed

Eoff, Ullysses A ullysses.a.eoff at intel.com
Thu May 23 08:39:45 PDT 2013


Rob, turns out the client side test case crash was just coincidental.  I isolated the
problem to a change in efl toolkit that occurred around the same time the weston
bug was introduced.

Thanks for the weston fix... it's working good now ;-)

U. Artie

> -----Original Message-----
> From: Eoff, Ullysses A
> Sent: Monday, May 20, 2013 8:59 AM
> To: Eoff, Ullysses A; Bradford, Robert; wayland-devel at lists.freedesktop.org
> Subject: RE: [PATCH weston] shell: End grab if the grabbed shell surface has been
> destroyed
> 
> Nonetheless, this is still a reasonable patch that can be applied to solve
> part of the problem...  that is, it prevents Weston from crashing.
> 
> > -----Original Message-----
> > From: wayland-devel-
> bounces+ullysses.a.eoff=intel.com at lists.freedesktop.org
> > [mailto:wayland-devel-
> > bounces+ullysses.a.eoff=intel.com at lists.freedesktop.org] On Behalf Of Eoff,
> > Ullysses A
> > Sent: Monday, May 20, 2013 5:59 AM
> > To: Bradford, Robert; wayland-devel at lists.freedesktop.org
> > Subject: RE: [PATCH weston] shell: End grab if the grabbed shell surface has
> been
> > destroyed
> >
> > Rob, I tried this same local modification on Friday... it seems to fix
> > Weston from segfaulting. However, I have another test case that
> > triggered this problem, too; only it crashes on the client-side as well.
> > The client-side crash did not disappear with this Weston modification,
> > which indicates there may be some deeper, underlying issue.
> >
> > I'll point you to the test case soon, real soon ;-)
> >
> > ----
> > U. Artie
> >
> >
> > > -----Original Message-----
> > > From: Rob Bradford [mailto:robert.bradford at intel.com]
> > > Sent: Monday, May 20, 2013 4:14 AM
> > > To: wayland-devel at lists.freedesktop.org; Eoff, Ullysses A
> > > Subject: Re: [PATCH weston] shell: End grab if the grabbed shell surface has
> > been
> > > destroyed
> > >
> > > I should add that although I think that this patch fixes the bug, i've
> > > written it by inspection of the code & backtraces only as I was unable
> > > to reproduce the issue. Artie, perhaps you could try this and give me
> > > a Tested-by if it resolves the problem.
> > >
> > > Cheers,
> > >
> > > Rob
> > >
> > > On 20 May 2013 12:09, Rob Bradford <robert.bradford at intel.com> wrote:
> > > > From: Rob Bradford <rob at linux.intel.com>
> > > >
> > > > The shell_grab_start function sets up a destroy notification on the
> > > > shell surface such that when the shell surface is destroyed the pointer
> > > > on the grab to the shell surface is set to NULL.
> > > >
> > > > We must therefore check whether the shell surface is NULL and end the
> > > > grab if it is.
> > > >
> > > > https://bugs.freedesktop.org/show_bug.cgi?id=64689
> > > > ---
> > > >  src/shell.c | 2 +-
> > > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > > >
> > > > diff --git a/src/shell.c b/src/shell.c
> > > > index f5d5bff..7261570 100644
> > > > --- a/src/shell.c
> > > > +++ b/src/shell.c
> > > > @@ -1296,7 +1296,7 @@ busy_cursor_grab_focus(struct
> > weston_pointer_grab
> > > *base)
> > > >                                                  pointer->x, pointer->y,
> > > >                                                  &sx, &sy);
> > > >
> > > > -       if (grab->shsurf->surface != surface) {
> > > > +       if (!grab->shsurf || grab->shsurf->surface != surface) {
> > > >                 shell_grab_end(grab);
> > > >                 free(grab);
> > > >         }
> > > > --
> > > > 1.8.1.4
> > > >
> > _______________________________________________
> > 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