Re: [PATCH weston] compositor-drm: Stop sending uninit data to the kernel

2016-07-08 Thread Yong Bakos
On Jul 8, 2016, at 10:50 AM, Derek Foreman wrote: > > Valgrind noticed that we send uninit data to drmModeAddFB2. While > the kernel should never read this (because of the plane format), > it's probably still nicer to zero the data before we send it. > > Signed-off-by: Derek Foreman Reviewed-

Re: Weston versioning (Re: [PATCH weston 6/6] libweston: do not use weston version in libweston.pc)

2016-07-08 Thread Jan Engelhardt
On Thursday 2016-07-07 11:46, Pekka Paalanen wrote: >> >> +AC_SUBST([LIBWESTON_VERSION], >> >> [libweston_major_version.libweston_minor_version.libweston_patch_version]) >> >> >> > >> > That makes packaging a pain. Although the whole libweston (supposedly >> > parallel-installable) is already a

Re: [PATCH weston] rdp: Check for non-numeric value in RDP_FD env var

2016-07-08 Thread Yong Bakos
On Jul 8, 2016, at 6:54 PM, Bryce Harrington wrote: > > strtoul(nptr, endptr, ...) will set *endptr to nptr in the case of where > no digits were read from the string, and return 0. Running with > RDP_FD=foo would thus result in fd=0 being specified to > freerdp_peer_new(), which is unlikely to

Re: [PATCH weston] multi-resource: Check for no digits in time description

2016-07-08 Thread Yong Bakos
On Jul 8, 2016, at 6:35 PM, Bryce Harrington wrote: > > strtoul(nptr, endptr, ...) will set *endptr to nptr in the case of where > no digits were read from the string. E.g. "foo:bar" should trigger an > error, instead of being read as "0:0" and allowed through. > > Signed-off-by: Bryce Harringt

Re: [PATCH] tests: Require base 10 for the string specifying the number of open fd's

2016-07-08 Thread Yong Bakos
On Jul 8, 2016, at 7:00 PM, Bryce Harrington wrote: > > The third arg to strtol() specifies the base to assume for the number. > When 0 is passed, as is currently done in wayland-client.c, hexadecimal > and octal numbers are permitted and automatically detected and > converted. > > exec-fd-leak-

Re: [PATCH] scanner: Improve documentation for strtouint()

2016-07-08 Thread Yong Bakos
On Jul 8, 2016, at 4:51 PM, Bryce Harrington wrote: > > From: Bryce Harrington > > Signed-off-by: Bryce Harrington > Signed-off-by: Bryce Harrington A definite improvement. However, a couple questions inline below. > --- > src/scanner.c | 13 +++-- > 1 file changed, 11 insertions(+)

Re: [PATCH weston] option-parser: Require integer option string values to be base-10

2016-07-08 Thread Bryce Harrington
On Fri, Jul 08, 2016 at 06:47:19PM -0700, Yong Bakos wrote: > On Jul 8, 2016, at 5:52 PM, Bryce Harrington wrote: > > > > The third arg to strtol() specifies the base to assume for the number. > > When 0 is passed, as is currently done in option-parser.c, hexadecimal > > and octal numbers are per

[PATCH] tests: Require base 10 for the string specifying the number of open fd's

2016-07-08 Thread Bryce Harrington
The third arg to strtol() specifies the base to assume for the number. When 0 is passed, as is currently done in wayland-client.c, hexadecimal and octal numbers are permitted and automatically detected and converted. exec-fd-leak-checker's single argument is the count of file descriptors it should

Re: [PATCH] wayland-client: Require base 10 for WAYLAND_SOCKET, explicitly

2016-07-08 Thread Bryce Harrington
On Fri, Jul 08, 2016 at 06:36:19PM -0700, Yong Bakos wrote: > On Jul 8, 2016, at 4:42 PM, Bryce Harrington wrote: > > > > The third arg to strtol() specifies the base to assume for the number. > > When 0 is passed, as is currently done in wayland-client.c, hexadecimal > > and octal numbers are pe

[PATCH weston] rdp: Check for non-numeric value in RDP_FD env var

2016-07-08 Thread Bryce Harrington
strtoul(nptr, endptr, ...) will set *endptr to nptr in the case of where no digits were read from the string, and return 0. Running with RDP_FD=foo would thus result in fd=0 being specified to freerdp_peer_new(), which is unlikely to be the user's intent. Signed-off-by: Bryce Harrington --- lib

Re: [PATCH] wayland-client: Require base 10 for WAYLAND_SOCKET, explicitly

2016-07-08 Thread Yong Bakos
On Jul 8, 2016, at 4:42 PM, Bryce Harrington wrote: > > The third arg to strtol() specifies the base to assume for the number. > When 0 is passed, as is currently done in wayland-client.c, hexadecimal > and octal numbers are permitted and automatically detected and > converted. > > I can find no

Re: [PATCH weston] option-parser: Require integer option string values to be base-10

2016-07-08 Thread Yong Bakos
On Jul 8, 2016, at 5:52 PM, Bryce Harrington wrote: > > The third arg to strtol() specifies the base to assume for the number. > When 0 is passed, as is currently done in option-parser.c, hexadecimal > and octal numbers are permitted and automatically detected and > converted. > > In weston and

[PATCH weston] multi-resource: Check for no digits in time description

2016-07-08 Thread Bryce Harrington
strtoul(nptr, endptr, ...) will set *endptr to nptr in the case of where no digits were read from the string. E.g. "foo:bar" should trigger an error, instead of being read as "0:0" and allowed through. Signed-off-by: Bryce Harrington --- clients/multi-resource.c | 7 --- 1 file changed, 4 i

[PATCH weston] option-parser: Require integer option string values to be base-10

2016-07-08 Thread Bryce Harrington
The third arg to strtol() specifies the base to assume for the number. When 0 is passed, as is currently done in option-parser.c, hexadecimal and octal numbers are permitted and automatically detected and converted. In weston and the weston clients and tests using option-parser.c, the options are

[PATCH] scanner: Improve documentation for strtouint()

2016-07-08 Thread Bryce Harrington
From: Bryce Harrington Signed-off-by: Bryce Harrington Signed-off-by: Bryce Harrington --- src/scanner.c | 13 +++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/scanner.c b/src/scanner.c index 4708cae..a266da1 100644 --- a/src/scanner.c +++ b/src/scanner.c @@ -57

[PATCH] wayland-client: Require base 10 for WAYLAND_SOCKET, explicitly

2016-07-08 Thread Bryce Harrington
The third arg to strtol() specifies the base to assume for the number. When 0 is passed, as is currently done in wayland-client.c, hexadecimal and octal numbers are permitted and automatically detected and converted. I can find no indication that we would ever expect use of hexadecimal or octal fo

Re: [PATCH weston RFC] compositor: Move all views to a new primary output

2016-07-08 Thread Armin Krezović
On 05.07.2016 13:42, Pekka Paalanen wrote: > On Thu, 30 Jun 2016 06:29:48 +0200 > Armin Krezović wrote: > >> When primary output gets disconnected and there >> were views created, they won't get assigned a >> new output when a new primary output gets plugged >> in. This will lead to crashes when

Re: [PATCH RFC] Add tiled states per edge

2016-07-08 Thread Benoit Gschwind
Hello, more random comments below :) On 08/07/2016 11:58, Quentin Glidic wrote: > Hi all, > > I will try to summarize all the discussion about tiling that this thread > has generated, and if all goes fine, we will see that we mostly all > agree with each other. > > First, definitions: > > Stac

Re: [PATCH] fullscreen-shell: Remap surface when attaching primary output

2016-07-08 Thread Armin Krezović
On 04.07.2016 14:14, Pekka Paalanen wrote: Hi Pekka, All your points below are good, so I don't think I need to reply for each one of them with "OK". I'll implement all your suggestions and reply again if I encounter any issues with your proposals. Thanks, Armin. > On Thu, 30 Jun 2016 19:55:

Re: [PATCH] compositor-x11: Flush xcb connection from x11_output_destroy()

2016-07-08 Thread Armin Krezović
On 04.07.2016 12:13, Pekka Paalanen wrote: > On Thu, 30 Jun 2016 06:29:00 +0200 > Armin Krezović wrote: > >> Current code flushes the connection when it receives >> a delete window request. This means that a destroyed >> window will remain available when X11 output gets >> removed differently (ie

Re: [PATCH RFC] Add tiled states per edge

2016-07-08 Thread Benoit Gschwind
Hello, simple random comment bellow :) On 08/07/2016 12:16, Jonas Ådahl wrote: > On Fri, Jul 08, 2016 at 11:58:13AM +0200, Quentin Glidic wrote: >> Hi all, >> >> I will try to summarize all the discussion about tiling that this thread has >> generated, and if all goes fine, we will see that we m

[PATCH weston v2] desktop-shell: Send fewer pings

2016-07-08 Thread Derek Foreman
Currently we can end up sending pings to popups every screen redraw and every pointer move when they're focused. Instead let's send a maximum of 1 every 200ms by letting the ping timer expire before we send another ping. With the old code I've logged 400+ pings per second on the right click pop-

Re: [PATCH weston] config-parser: Improve error checks for strtol/strtoul calls

2016-07-08 Thread Bryce Harrington
On Fri, Jul 08, 2016 at 11:33:56AM +0100, Eric Engestrom wrote: > On Fri, Jul 08, 2016 at 10:26:43AM +0100, Eric Engestrom wrote: > > On Thu, Jul 07, 2016 at 02:08:28PM -0700, Bryce Harrington wrote: > > > + errno = 0; > > > *value = strtol(entry->value, &end, 0); > > > - if (*end != '\0') { > >

Re: [PATCH wayland-protocols] Fix grammar for 'an X*'

2016-07-08 Thread Bryce Harrington
On Fri, Jul 08, 2016 at 10:20:22AM +0100, Eric Engestrom wrote: > On Thu, Jul 07, 2016 at 10:56:12AM -0700, Bryce Harrington wrote: > > Signed-off-by: Bryce Harrington > > This is the last of it, right? ^^ > Reviewed-by: Eric Engestrom Thanks Eric and Yong, pushed. > > --- > > unstable/input

[PATCH weston] compositor-drm: Stop sending uninit data to the kernel

2016-07-08 Thread Derek Foreman
Valgrind noticed that we send uninit data to drmModeAddFB2. While the kernel should never read this (because of the plane format), it's probably still nicer to zero the data before we send it. Signed-off-by: Derek Foreman --- libweston/compositor-drm.c | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH weston 2/2] desktop-shell: Send fewer pings

2016-07-08 Thread Derek Foreman
Currently we can end up sending pings to popups every screen redraw and every pointer move when they're focused. Instead let's send a maximum of 1 every 200ms by letting the ping timer expire before we send another ping. With the old code I've logged 400+ pings per second on the right click pop-

[PATCH weston 1/2] desktop-shell: Generate serials for pings in the function that sends them

2016-07-08 Thread Derek Foreman
Currently we generate a serial and pass it through a couple of functions. In a future commit I'm going to throttle pings in the leaf function, so generating them there prevents consuming them needlessly. Signed-off-by: Derek Foreman --- desktop-shell/shell.c | 14 ++ 1 file changed,

Re: [PATCH wayland-protocols] Fix grammar for 'an X*'

2016-07-08 Thread Yong Bakos
On Jul 7, 2016, at 10:56 AM, Bryce Harrington wrote: > > Signed-off-by: Bryce Harrington Reviewed-by: Yong Bakos yong > --- > unstable/input-method/input-method-unstable-v1.xml | 2 +- > unstable/text-input/text-input-unstable-v1.xml | 2 +- > 2 files changed, 2 insertions(+), 2 deletions

Re: [PATCH weston 3/6] README: Document versioning scheme, forward compatibility

2016-07-08 Thread Emil Velikov
On 8 July 2016 at 12:00, Quentin Glidic wrote: > On 08/07/2016 12:52, Emil Velikov wrote: >> >> On 7 July 2016 at 19:08, Quentin Glidic >> wrote: >>> >>> On 07/07/2016 18:11, Emil Velikov wrote: On 7 July 2016 at 10:05, Pekka Paalanen wrote: > > > > [snip] >>> >>>

Re: [PATCH weston 3/6] README: Document versioning scheme, forward compatibility

2016-07-08 Thread Quentin Glidic
On 08/07/2016 13:00, Quentin Glidic wrote: On 08/07/2016 12:52, Emil Velikov wrote: On 7 July 2016 at 19:08, Quentin Glidic wrote: On 07/07/2016 18:11, Emil Velikov wrote: On 7 July 2016 at 10:05, Pekka Paalanen wrote: [snip] Now that you mentioned the semantics could be of upper or

Re: [PATCH weston 3/6] README: Document versioning scheme, forward compatibility

2016-07-08 Thread Quentin Glidic
On 08/07/2016 12:52, Emil Velikov wrote: On 7 July 2016 at 19:08, Quentin Glidic wrote: On 07/07/2016 18:11, Emil Velikov wrote: On 7 July 2016 at 10:05, Pekka Paalanen wrote: [snip] Now that you mentioned the semantics could be of upper or lower limit, the name should imply the meani

Re: [PATCH weston 3/6] README: Document versioning scheme, forward compatibility

2016-07-08 Thread Emil Velikov
On 7 July 2016 at 19:08, Quentin Glidic wrote: > On 07/07/2016 18:11, Emil Velikov wrote: >> >> On 7 July 2016 at 10:05, Pekka Paalanen wrote: >>> >>> >>> [snip] > >>> >>> Now that you mentioned the semantics could be of upper or lower >>> limit, the name should imply the meaning. I only thought

Re: [PATCH weston] config-parser: Improve error checks for strtol/strtoul calls

2016-07-08 Thread Eric Engestrom
On Fri, Jul 08, 2016 at 10:26:43AM +0100, Eric Engestrom wrote: > On Thu, Jul 07, 2016 at 02:08:28PM -0700, Bryce Harrington wrote: > > + errno = 0; > > *value = strtol(entry->value, &end, 0); > > - if (*end != '\0') { > > + if (errno != 0 || end == entry->value || *end != '\0') { > > Is

Re: [PATCH weston 5/6] libweston: do not add libweston-$version to the Cflags

2016-07-08 Thread Emil Velikov
On 7 July 2016 at 19:18, Quentin Glidic wrote: > On 07/07/2016 18:28, Emil Velikov wrote: >> >> On 7 July 2016 at 10:20, Pekka Paalanen wrote: >>> >>> [snip] >>> Therefore a NAK from me too. >>> >> As you guys wish. In that case can we drop the pkgincludedir variable >> ? Most packages don't both

Re: Create cross wayland-scanner for toolchain or cross-development environment

2016-07-08 Thread Emil Velikov
Hi all, Jumping the gun a bit, hope you'll forgive me :-) On 8 July 2016 at 09:17, Quentin Glidic wrote: > On 18/05/2016 14:55, Andrew Kosteltsev wrote: >> Then the user can make use this cross-wayland-scanner in his SDK, for >> example, like follow: >> >> $ ../MesaLib-10.3.4/configure >> WAILA

Re: [PATCH RFC] Add tiled states per edge

2016-07-08 Thread Jonas Ådahl
On Fri, Jul 08, 2016 at 11:58:13AM +0200, Quentin Glidic wrote: > Hi all, > > I will try to summarize all the discussion about tiling that this thread has > generated, and if all goes fine, we will see that we mostly all agree with > each other. > > First, definitions: > > Stacking/Floating: thi

Re: [PATCH RFC] Add tiled states per edge

2016-07-08 Thread Quentin Glidic
Hi all, I will try to summarize all the discussion about tiling that this thread has generated, and if all goes fine, we will see that we mostly all agree with each other. First, definitions: Stacking/Floating: this is the “classic” way of managing windows, directly inherited from the deskt

Re: [PATCH weston] config-parser: Improve error checks for strtol/strtoul calls

2016-07-08 Thread Eric Engestrom
On Thu, Jul 07, 2016 at 02:08:28PM -0700, Bryce Harrington wrote: > Check errno, which is set of over/underflow, out of range, etc. Also > check for empty strings (the usages covered in this patch already also > cover the case where there are non-digits present). Set errno to 0 > before making th

Re: Create cross wayland-scanner for toolchain or cross-development environment

2016-07-08 Thread Quentin Glidic
On 08/07/2016 10:46, Andrew Kosteltsev wrote: Hi Quentin. I see. My suggestion related to simplify the build process on developer machines which doesn't have pre-installed native Wayland package. And also I think it would be good if wailand-scanner output will be generated by scanner which has t

Re: [PATCH wayland-protocols] Fix grammar for 'an X*'

2016-07-08 Thread Eric Engestrom
On Thu, Jul 07, 2016 at 10:56:12AM -0700, Bryce Harrington wrote: > Signed-off-by: Bryce Harrington This is the last of it, right? ^^ Reviewed-by: Eric Engestrom > --- > unstable/input-method/input-method-unstable-v1.xml | 2 +- > unstable/text-input/text-input-unstable-v1.xml | 2 +- > 2

Re: Create cross wayland-scanner for toolchain or cross-development environment

2016-07-08 Thread Quentin Glidic
On 18/05/2016 14:55, Andrew Kosteltsev wrote: Hi guys, Currently during cross compilation of the wayland library the wayland-scanner utility is built by cross-gcc and then used on the developer machine which lead build error. I suggest to build development version, for example, $(top_builddir)/

Re: [PATCH weston] fullscreen-shell: avoid access to freed data

2016-07-08 Thread Quentin Glidic
On 08/06/2016 17:55, Arnaud Vrac wrote: Remove the output transform from the view transform list when its surface is destroyed. The surface destruction also triggers the freeing of its views, so the next access to the output transform link could crash. --- fullscreen-shell/fullscreen-shell.c | 2