Re: [PATCH 1/5] Crash if zero data but non-zero fd's in message

2012-03-19 Thread Bill Spitzak
Any comments on this patch? This really did fix a pretty major bug for me. The other patches in this set are much less important but I thought it a good idea to send everything else I did while trying to debug this. I suspect my changes to EAGAIN are incorrect, however, so ignore them. On 03/

Re: [PATCH 3/3] compositor: dump command line options

2012-03-19 Thread Bill Spitzak
On 03/19/2012 08:57 PM, Tiago Vignatti wrote: + argv[argc] = argv[argc - 1] + strlen(argv[argc - 1]) +1; + strcpy(argv[argc], "--help"); You want just: argv[argc] = "--help"; You do not need to copy any string anywhere, and certainly the above is not in any way guaranteed to give you some

Re: [PATCH 3/3] compositor: dump command line options

2012-03-19 Thread Tiago Vignatti
On 03/19/2012 09:08 AM, Pekka Paalanen wrote: On Mon, 12 Mar 2012 19:06:40 -0300 Tiago Vignatti wrote: Use it with --help or -h. Signed-off-by: Tiago Vignatti --- shared/config-parser.h |3 +++ shared/option-parser.c | 13 + src/compositor-drm.c |7 ++-

Re: [PATCH 2/3] compositor: fix option types

2012-03-19 Thread Tiago Vignatti
On 03/19/2012 08:58 AM, Pekka Paalanen wrote: On Mon, 12 Mar 2012 19:06:39 -0300 Tiago Vignatti wrote: Basically all integer options should be set as unsigned integers instead. Funny that WESTON_OPTION_INTEGER is not being used anywhere now. Signed-off-by: Tiago Vignatti --- clients/eventde

[PATCH] shell: correct position of a surface before rotating it.

2012-03-19 Thread Rafał Mielniczuk
From: Rafal Mielniczuk How to reproduce: rotate the surface to something like 45 degrees, resize it drastically, continue to rotate. The surface will jump some space and the rotation point will not be in the center of the surface. Fix is to shift the surface position to match the rotation point

Re: [PATCH v2] evdev: use mtdev for multitouch devices

2012-03-19 Thread Tiago Vignatti
On 03/17/2012 09:30 AM, Daniel Stone wrote: Hi, On 16 March 2012 20:33, Tiago Vignatti wrote: @@ -334,7 +337,11 @@ evdev_input_device_data(int fd, uint32_t mask, void *data) if (!ec->focus) return 1; - len = read(fd,&ev, sizeof ev); + if (device->mtdev) +

Re: [PATCH] event-loop: Only read one epoll event per loop dispatch.

2012-03-19 Thread Bill Spitzak
Jonas Ådahl wrote: On Mon, Mar 19, 2012 at 7:10 PM, Bill Spitzak wrote: Jonas Ådahl wrote: That would not work because ep[i].data.ptr will already be loaded with the source pointer pointing to deallocated memory. It doesn't matter if that particular source is free:ed and removed from the ep

Re: [PATCH] event-loop: Only read one epoll event per loop dispatch.

2012-03-19 Thread Jonas Ådahl
On Mon, Mar 19, 2012 at 7:10 PM, Bill Spitzak wrote: > Jonas Ådahl wrote: > >> That would not work because ep[i].data.ptr will already be loaded with >> the source pointer pointing to deallocated memory. It doesn't matter >> if that particular source is free:ed and removed from the epoll state >>

Re: [PATCH] event-loop: Only read one epoll event per loop dispatch.

2012-03-19 Thread Bill Spitzak
Jonas Ådahl wrote: That would not work because ep[i].data.ptr will already be loaded with the source pointer pointing to deallocated memory. It doesn't matter if that particular source is free:ed and removed from the epoll state since it has already been triggered to dispatch. Another approach w

[PATCH] weston_surface: initialize pitch

2012-03-19 Thread zhaojuanamy
From: Juan Zhao Initializing pitch to 1 to avoid xxx/pitch errors This won't influence the valid texture coordinate calculation, because in that case buffer_attach will provide the correct value. --- src/compositor.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/c

Re: [PATCH] event-loop: Only read one epoll event per loop dispatch.

2012-03-19 Thread Jonas Ådahl
On Mon, Mar 19, 2012 at 4:03 PM, Andreas Ericsson wrote: > On 03/17/2012 09:39 AM, Jonas Ådahl wrote: >> In order for users of the event loop to manipulate the state of it or >> others, only one event may be processed per epoll_wait. When multiple >> events are queued up and a user removes an even

Re: Building Qt with wayland 0.85

2012-03-19 Thread darxus
On 03/18, dar...@chaosreigns.com wrote: > qtwayland is a plugin for qt that provides the wayland backend for qt. It > depends on qtbase. qtwayland has a 0.85 branch compatible with wayland > 0.85. But it doesn't currently build against qtbase master, which > is unfortunate. > git checkout 96232

Re: [PATCH] event-loop: Only read one epoll event per loop dispatch.

2012-03-19 Thread Andreas Ericsson
On 03/17/2012 09:39 AM, Jonas Ådahl wrote: > In order for users of the event loop to manipulate the state of it or > others, only one event may be processed per epoll_wait. When multiple > events are queued up and a user removes an event input source from an > event loop from within a dispatch, if

Re: [PATCH 4/5] Use blocking output for the pipe

2012-03-19 Thread Bill Spitzak
On 03/19/2012 01:57 AM, Pekka Paalanen wrote: --- a/src/connection.c +++ b/src/connection.c @@ -277,8 +277,7 @@ wl_connection_data(struct wl_connection *connection, uint32_t mask) msg.msg_flags = 0; do { - len = sendmsg(connection->fd,&msg,

Re: [PATCH 3/3] compositor: dump command line options

2012-03-19 Thread Bill Spitzak
On 03/19/2012 05:08 AM, Pekka Paalanen wrote: + if (help) { + dump_options(core_options, ARRAY_LENGTH(core_options)); + argv[argc] = strdup("--help"); + argc++; How do you know there is space in argv[] to add that? Also, doesn't strdup() leak her

Re: [PATCH 3/3] compositor: dump command line options

2012-03-19 Thread Pekka Paalanen
On Mon, 12 Mar 2012 19:06:40 -0300 Tiago Vignatti wrote: > Use it with --help or -h. > > Signed-off-by: Tiago Vignatti > --- > shared/config-parser.h |3 +++ > shared/option-parser.c | 13 + > src/compositor-drm.c |7 ++- > src/compositor-openwfd.c |7

Re: [PATCH 2/3] compositor: fix option types

2012-03-19 Thread Pekka Paalanen
On Mon, 12 Mar 2012 19:06:39 -0300 Tiago Vignatti wrote: > Basically all integer options should be set as unsigned integers instead. > Funny that WESTON_OPTION_INTEGER is not being used anywhere now. > > Signed-off-by: Tiago Vignatti > --- > clients/eventdemo.c |8 > src/comp

Re: [PATCH v3] parser: be more picky for integer values

2012-03-19 Thread Pekka Paalanen
On Fri, 16 Mar 2012 15:12:14 -0300 Tiago Vignatti wrote: > It was silently accepting "-i=3", "-i=3/2", "--idle-time=*3" and similar > unwanted type of arguments, not changing anything internally; this > gives the wrong impression for the user. Now it explicitly warns. > > Signed-off-by: Tiago Vi

Re: [PATCH 4/5] Use blocking output for the pipe

2012-03-19 Thread Pekka Paalanen
On Sun, 18 Mar 2012 22:56:21 -0700 spit...@gmail.com wrote: > From: Bill Spitzak > > It certainly looks like this message must be sent! > --- > src/connection.c |3 +-- > 1 files changed, 1 insertions(+), 2 deletions(-) > > diff --git a/src/connection.c b/src/connection.c > index 1f707ed..

Re: [PATCH 1/2] Don't hang in wait if suspended/resumed

2012-03-19 Thread Pekka Paalanen
On Sun, 18 Mar 2012 21:46:11 -0700 spit...@gmail.com wrote: > It actually never called sigchld when I killed or made clients exit, > so it is not clear if this handler is needed at all. SIGCHLD is received only for a process' immediate children, which in Weston's case can only be desktop-shell,