[PATCH] cliptest: Don't underrun the vertex array of empty polygons.

2014-08-19 Thread Ondřej Majerech
This silences the following warning: clients/cliptest.c:277:22: warning: array subscript is below array bounds [-Warray-bounds] ctx->prev.x = src->x[src->n - 1]; Signed-off-by: Ondřej Majerech --- clients/cliptest.c | 12 1 file changed, 12 insertions(+) dif

[PATCH v2 2/2] Don't underrun the vertex array of empty polygons

2014-08-19 Thread Ondřej Majerech
This silences the following warning: src/vertex-clipping.c:196:22: warning: array subscript is below array bounds [-Warray-bounds] ctx->prev.x = src->x[src->n - 1]; Signed-off-by: Ondřej Majerech --- src/vertex-clipping.c | 12 1 file changed, 12 insertions(+) dif

[PATCH v2 1/2] Remove duplicated code from cliptest.c

2014-08-19 Thread Ondřej Majerech
Signed-off-by: Ondřej Majerech --- Makefile.am| 2 +- clients/cliptest.c | 293 + 2 files changed, 4 insertions(+), 291 deletions(-) diff --git a/Makefile.am b/Makefile.am index 191dcc9..8a27d44 100644 --- a/Makefile.am +++ b

[PATCH] xwayland: Use frame geometry for resizing shell surface

2014-08-20 Thread Ondřej Majerech
We want to set the size of the entire window, not just the input area. This fixes the bug where resizing an X client under XWayland would make the window snap to a smaller size, and the pointer would then stay a distance away from the frame. Signed-off-by: Ondřej Majerech --- xwayland/window

[PATCH] desktop-shell: Replace magic constants with named ones

2014-08-21 Thread Ondřej Majerech
Signed-off-by: Ondřej Majerech --- desktop-shell/shell.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/desktop-shell/shell.c b/desktop-shell/shell.c index e3abaad..02e180d 100644 --- a/desktop-shell/shell.c +++ b/desktop-shell/shell.c @@ -1884,13 +1884,20

Re: [PATCH] xwayland: Use frame geometry for resizing shell surface

2014-08-27 Thread Ondřej Majerech
On 27/08/14 14:38, Pekka Paalanen wrote: On Mon, 25 Aug 2014 10:17:48 +0200 "Nils Chr. Brause" wrote: I also noticed this in current master. This seems to fix the problem. :) Reviewed-by: Nils Chr. Brause On Thu, Aug 21, 2014 at 2:51 AM, Ondřej Majerech wrote: We want to se

[PATCH] compositor: Don't free an uninitialised pointer.

2014-09-11 Thread Ondřej Majerech
When backend_init returns NULL, we goto out_signals, which wants to free(modules), but in this particular code path, modules hasn't been initialised leading to a "Double-free or corruption" error message. Initialising modules to NULL makes the free a no-op in this scenario. Signed

[PATCH] window: Don't needlessly sync parent and geometry

2014-09-13 Thread Ondřej Majerech
quests for changing the geometry or parent if these haven't changed. So remember the last geometry and parent, and update them only if needed. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=83297 Signed-off-by: Ondřej Majerech --- clients/window.c | 12 1 file changed, 12 insertions

Re: [PATCH] window: Don't needlessly sync parent and geometry

2014-09-14 Thread Ondřej Majerech
On Sun, 14 Sep 2014 13:52:21 +0100 Daniel Stone wrote: > Hi, > > On 13 September 2014 15:35, Ondřej Majerech > wrote: > > > When a toytoolkit client redraws, the toolkit syncs the parent and > > geometry. If a client redraws often (such as the terminal drawing

[PATCH 1/2] compositor: Propagate error from module_init

2014-12-05 Thread Ondřej Majerech
load_modules currently calls module_init, but completely ignores its return value and instead always returns 0. Its return value appears to be checked in callers, so we most likely want to propagate any error signalled by module_init. Signed-off-by: Ondřej Majerech --- src/compositor.c | 3

[PATCH 2/2] ivi-shell: Say something when configuration is missing

2014-12-05 Thread Ondřej Majerech
When ivi-module is not set in weston.conf, we probably want to tell the user about their error instead of just dying. Signed-off-by: Ondřej Majerech --- ivi-shell/ivi-shell.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ivi-shell/ivi-shell.c b/ivi-shell/ivi-shell.c index a14010e..02fbafb

[PATCH v2 0/2] Let's propagate even more errors

2014-12-05 Thread Ondřej Majerech
Derp. After sending this out, I noticed there's yet another low-hanging fruit to be picked. Ondřej Majerech (2): compositor: Propagate errors from module_init ivi-shell: Say something when configuration is missing ivi-shell/ivi-shell.c | 1 + src/compositor.c | 6 -- 2

[PATCH v2 2/2] ivi-shell: Say something when configuration is missing

2014-12-05 Thread Ondřej Majerech
When ivi-module is not set in weston.conf, we probably want to tell the user about their error instead of just dying. Signed-off-by: Ondřej Majerech --- ivi-shell/ivi-shell.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ivi-shell/ivi-shell.c b/ivi-shell/ivi-shell.c index a14010e..02fbafb

[PATCH v2 1/2] compositor: Propagate errors from module_init

2014-12-05 Thread Ondřej Majerech
load_modules currently ignores errors signalled by both weston_load_module and module_init, and instead always returns 0. Its return value appears to be checked in callers, so we most likely want to propagate any errors. Signed-off-by: Ondřej Majerech --- src/compositor.c | 6 -- 1 file

Re: [PATCH v2 1/2] compositor: Propagate errors from module_init

2014-12-09 Thread Ondřej Majerech
On Tue, 09 Dec 2014 10:19:22 -0600 Derek Foreman wrote: > On 05/12/14 07:49 PM, Ondřej Majerech wrote: > > load_modules currently ignores errors signalled by both > > weston_load_module and module_init, and instead always returns 0. > > Its return value appears to be chec

Re: [PATCH 2/2] ivi-shell: Say something when configuration is missing

2014-12-09 Thread Ondřej Majerech
shell sounds like a good idea. :-) > > BR, > Nobuhiko Tanibata > > > -Original Message- > > From: wayland-devel > > [mailto:wayland-devel-boun...@lists.freedesktop.org] On Behalf Of > > Ond?ej Majerech > > Sent: Saturday, December 06, 2014 9:39 AM > >

[PATCH weston] compositor-x11: Fix pointer warping with multiple outputs

2015-03-20 Thread Ondřej Majerech
count. Signed-off-by: Ondřej Majerech --- src/compositor-x11.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/compositor-x11.c b/src/compositor-x11.c index e9735c5..5092a4a 100644 --- a/src/compositor-x11.c +++ b/src/compositor-x11.c @@ -1095,10 +10