Re: [PATCH 5/5] parser: free val.str after xstrtokenize

2011-11-01 Thread Peter Hutterer
On Tue, Nov 01, 2011 at 11:12:38AM -0200, przan...@gmail.com wrote: > From: Paulo Zanoni > > After we tokenize val.str, we discard it. > > This is just one example: > 6 bytes in 1 blocks are definitely lost in loss record 24 of 652 >at 0x4C2779D: malloc (in vgpreload_memcheck-amd64-linux.so)

Re: [PATCH 4/5] parser: free val.str after xf86getBoolValue

2011-11-01 Thread Peter Hutterer
On Tue, Nov 01, 2011 at 11:12:37AM -0200, przan...@gmail.com wrote: > From: Paulo Zanoni > > After we convert the value to a boolean, we discard the string. > > This is just one example: > > 3 bytes in 1 blocks are definitely lost in loss record 5 of 657 >at 0x4C2779D: malloc (vgpreload_mem

Re: [PATCH 3/5] parser: free scandir's list

2011-11-01 Thread Peter Hutterer
On Tue, Nov 01, 2011 at 11:12:36AM -0200, przan...@gmail.com wrote: > From: Paulo Zanoni > > It seems appropriate to make the function that frees the list elements > also free the list. > > 80 bytes in 1 blocks are definitely lost in loss record 411 of 631 >at 0x4C2779D: malloc (vgpreload_me

Re: [PATCH 5/7] xf86ShowOpts.c: Remove bad code from DoShowOptions

2011-11-01 Thread Daniel Stone
Hi, On 2 November 2011 01:14, Alan Coopersmith wrote: > On 11/01/11 17:50, Daniel Stone wrote: >> On 1 November 2011 22:42, Alan Coopersmith >>  wrote: >>> When we want to print a string, it's okay to just print it. >>> We don't need to first allocate a buffer 2 bytes bigger than the >>> string,

Re: [PATCH] xfree86: Fix powerpc build with -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast

2011-11-01 Thread Jeremy Huddleston
On Nov 1, 2011, at 5:48 PM, Daniel Stone wrote: > Hi, > > On 1 November 2011 22:05, Jeremy Huddleston wrote: >> While this does fix the build failure, I'd much rather change memType to be >> a uintptr_t everywhere, but it was explicitly set to uint64_t for 32bit >> powerpc by Ian in the commi

Re: [PATCH 5/7] xf86ShowOpts.c: Remove bad code from DoShowOptions

2011-11-01 Thread Alan Coopersmith
On 11/01/11 17:50, Daniel Stone wrote: Hi, On 1 November 2011 22:42, Alan Coopersmith wrote: When we want to print a string, it's okay to just print it. We don't need to first allocate a buffer 2 bytes bigger than the string, copy the entire string unmodified to the buffer, print the buffer, a

Re: [PATCH 7/7] Remove unnecessary variable rtrn in XkbKeysymText

2011-11-01 Thread Daniel Stone
On 1 November 2011 22:42, Alan Coopersmith wrote: > Also removes even more unnecessary use of variable assignment inside > function arguments. > > Signed-off-by: Alan Coopersmith Reviewed-by: Daniel Stone ___ xorg-devel@lists.x.org: X.Org development

Re: [PATCH 5/7] xf86ShowOpts.c: Remove bad code from DoShowOptions

2011-11-01 Thread Daniel Stone
Hi, On 1 November 2011 22:42, Alan Coopersmith wrote: > When we want to print a string, it's okay to just print it. > We don't need to first allocate a buffer 2 bytes bigger than the > string, copy the entire string unmodified to the buffer, print the > buffer, and then leak the buffer (though we

Re: [PATCH] xfree86: Fix powerpc build with -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast

2011-11-01 Thread Daniel Stone
Hi, On 1 November 2011 22:05, Jeremy Huddleston wrote: > While this does fix the build failure, I'd much rather change memType to be a > uintptr_t everywhere, but it was explicitly set to uint64_t for 32bit powerpc > by Ian in the commit referenced below.  Ian, can you explain why you set > me

[PATCH evdev] Don't crop long value from EvdevBitIsSet.

2011-11-01 Thread Peter Hutterer
Introduced in xf86-input-evdev-2.6.0-26-g4969389 Signed-off-by: Peter Hutterer --- Cutting long to int for the return value loses us some values, notably in the ABS_MT ranges. src/evdev.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/src/evdev.c b/src/evdev.c index f

Re: [PATCH sis] Use miPointerSetPosition, not miPointerAbsoluteCursor

2011-11-01 Thread Peter Hutterer
On Sun, Oct 30, 2011 at 11:20:15PM -0700, Jeremy Huddleston wrote: > Does this need ifdef based on some ABI version? yes, it does. several even, but until the two-screen-coordinates stuff is merged I can't fix this since it'll change again then. so ignore this patch for now pls. Cheers, Peter

Re: [PATCH] Xi: allow passive keygrabs on the XIAll(Master)Devices fake devices

2011-11-01 Thread Peter Hutterer
ping? this issue affects all XI2-capable servers. On Thu, Oct 27, 2011 at 11:51:25AM +1000, Peter Hutterer wrote: > They don't have a KeyClassRec, but we must still allow passive grabs on > them. > > Signed-off-by: Peter Hutterer > --- > Xi/exevents.c |2 +- > 1 files changed, 1 insertions

[PATCH 1/7] Convert a bunch of sprintf to snprintf calls

2011-11-01 Thread Alan Coopersmith
This batch is the straightforward set - others are more complex and need more analysis to determine right size to pass. Signed-off-by: Alan Coopersmith --- exa/exa_render.c |6 +- hw/dmx/examples/ev.c |4 +- hw/dmx/glxProxy/glxscreens.c |

[PATCH 6/7] Remove xf86FormatPciBusNumber from API, inline the one place its used

2011-11-01 Thread Alan Coopersmith
Found no calls from current driver modules Signed-off-by: Alan Coopersmith --- hw/xfree86/common/xf86.h |1 - hw/xfree86/common/xf86pciBus.c | 17 ++--- 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/hw/xfree86/common/xf86.h b/hw/xfree86/common/xf86.h ind

[PATCH 7/7] Remove unnecessary variable rtrn in XkbKeysymText

2011-11-01 Thread Alan Coopersmith
Also removes even more unnecessary use of variable assignment inside function arguments. Signed-off-by: Alan Coopersmith --- xkb/xkbtext.c |8 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/xkb/xkbtext.c b/xkb/xkbtext.c index 885beb7..cd19000 100644 --- a/xkb/xkbtext

[PATCH 5/7] xf86ShowOpts.c: Remove bad code from DoShowOptions

2011-11-01 Thread Alan Coopersmith
When we want to print a string, it's okay to just print it. We don't need to first allocate a buffer 2 bytes bigger than the string, copy the entire string unmodified to the buffer, print the buffer, and then leak the buffer (though we AbortDDX 8 lines later, and then just in case we survived that,

[PATCH 4/7] Convert glx/single2.c:DoGetString() to use asprintf()

2011-11-01 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- glx/single2.c |4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/glx/single2.c b/glx/single2.c index 9884f40..9f8254b 100644 --- a/glx/single2.c +++ b/glx/single2.c @@ -351,12 +351,10 @@ int DoGetString(__GLXclientState *cl, GLbyte *pc,

[PATCH 3/7] LogVMessageVerb: Fix const mismatch warning

2011-11-01 Thread Alan Coopersmith
"log.c", line 382: warning: assignment type mismatch: pointer to char "=" pointer to const char Signed-off-by: Alan Coopersmith --- os/log.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/os/log.c b/os/log.c index 9ee32c9..671a01b 100644 --- a/os/log.c +++ b/os

[PATCH 2/7] AuthAudit: clean up string handling calls

2011-11-01 Thread Alan Coopersmith
The extra "out" pointer to redirect writes to the array isn't needed since the removal of LBX (commit a9ed5a87902a), and eliminating it allows more logical use of sizeof(addr) in length-checked strlcpy & snprintf calls to write to it. Signed-off-by: Alan Coopersmith --- os/connection.c | 11 ++

Re: [PATCH] xfree86: Fix powerpc build with -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast

2011-11-01 Thread Jeremy Huddleston
While this does fix the build failure, I'd much rather change memType to be a uintptr_t everywhere, but it was explicitly set to uint64_t for 32bit powerpc by Ian in the commit referenced below. Ian, can you explain why you set memType to 64bits even though void * is only 32bits? You reference

[PATCH] xfree86: Fix powerpc build with -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast

2011-11-01 Thread Jeremy Huddleston
memType is a uint64_t on powerpc Signed-off-by: Jeremy Huddleston --- hw/xfree86/os-support/linux/lnx_video.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/xfree86/os-support/linux/lnx_video.c b/hw/xfree86/os-support/linux/lnx_video.c index 3d45511..c12a654 10

Re: [PATCH util-macros 1/6] Fix the test for -Werror=attributes

2011-11-01 Thread Alan Coopersmith
On 11/01/11 13:56, Jeremy Huddleston wrote: Thanks for the catch. I've also added -errwarn=E_NO_IMPLICIT_DECL_ALLOWED Do you want to add corresponding SunCC flags for the other -Werror=? You mean the ones from patch 6 that you're suggesting to add to the base flags, right? Unfortunately, I d

[PATCH] randr: Make the RRConstrainCursorHarder logic the same as miPointerSetPosition

2011-11-01 Thread Rui Matos
The constraining logic in RRConstrainCursorHarder allows the cursor to reach crtc positions of x = width and y = height while the constraining code in miPointerSetPosition only allows it to reach x = width - 1 and y = height - 1 for the analogous screen case. This patch makes the former's logic eq

Re: [PATCH util-macros 1/6] Fix the test for -Werror=attributes

2011-11-01 Thread Jeremy Huddleston
Thanks for the catch. I've also added -errwarn=E_NO_IMPLICIT_DECL_ALLOWED Do you want to add corresponding SunCC flags for the other -Werror=? On Nov 1, 2011, at 1:37 PM, Alan Coopersmith wrote: > I only see one argument to AC_LANG_SOURCE in > https://www.gnu.org/software/autoconf/manual/html_n

Re: [PATCH] Xext: XCopyArea does not work in Xinerama mode.#25113

2011-11-01 Thread Dave Airlie
On Sat, Oct 15, 2011 at 2:27 AM, Arvind Umrao wrote: > Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=25113 > > XCopyArea() does not work in Xinerama mode. XCopyArea does not copy areas of > the screen across physical displays. XcopyArea works fine when source and > destination image are in

Re: [PATCH util-macros 1/6] Fix the test for -Werror=attributes

2011-11-01 Thread Alan Coopersmith
I only see one argument to AC_LANG_SOURCE in https://www.gnu.org/software/autoconf/manual/html_node/Generating-Sources.html Did you mean to change the macro to AC_LANG_PROGRAM? -alan- On 11/01/11 13:16, Jeremy Huddleston wrote: The current test was always failing to compile because 're

Re: [PATCH util-macros 3/6] Use XORG_TESTSET_CFLAG in XORG_STRICT_OPTION

2011-11-01 Thread Jeremy Huddleston
Please ignore the bad grammar in the comment in this change. I'll fix it ;) On Nov 1, 2011, at 1:16 PM, Jeremy Huddleston wrote: > Signed-off-by: Jeremy Huddleston > --- > xorg-macros.m4.in | 28 +--- > 1 files changed, 9 insertions(+), 19 deletions(-) > > diff --git a

Re: [PATCH util-macros 2/6] Add XORG_TESTSET_CFLAG which can be used to test what flags the compiler supports

2011-11-01 Thread Jeremy Huddleston
This patch is currently incomplete. I'm hoping an m4 guru (Gaetan, you're my hero) can help finish it. The recursive part of XORG_TESTSET_CFLAG is currently commented out because it doesn't work. From a high level, it looks like the logic is right (it should strip the second argument in the r

[PATCH util-macros 6/6] Add additional flags to XORG_COMPILER_FLAGS

2011-11-01 Thread Jeremy Huddleston
Signed-off-by: Jeremy Huddleston --- xorg-macros.m4.in | 34 ++ 1 files changed, 34 insertions(+), 0 deletions(-) diff --git a/xorg-macros.m4.in b/xorg-macros.m4.in index a2bf35c..f9d633e 100644 --- a/xorg-macros.m4.in +++ b/xorg-macros.m4.in @@ -1427,6 +1427,7

[PATCH util-macros 5/6] Update XORG_CWARNFLAGS to use XORG_COMPILER_FLAGS

2011-11-01 Thread Jeremy Huddleston
Signed-off-by: Jeremy Huddleston --- xorg-macros.m4.in | 16 +++- 1 files changed, 3 insertions(+), 13 deletions(-) diff --git a/xorg-macros.m4.in b/xorg-macros.m4.in index c362943..a2bf35c 100644 --- a/xorg-macros.m4.in +++ b/xorg-macros.m4.in @@ -1454,21 +1454,11 @@ AC_SUBST(BASE

[PATCH util-macros 4/6] Add XORG_COMPILER_FLAGS to replace XORG_CWARNFLAGS

2011-11-01 Thread Jeremy Huddleston
See: https://bugs.freedesktop.org/show_bug.cgi?id=31238 Signed-off-by: Jeremy Huddleston --- xorg-macros.m4.in | 47 ++- 1 files changed, 46 insertions(+), 1 deletions(-) diff --git a/xorg-macros.m4.in b/xorg-macros.m4.in index 456f78f..c362943 1006

[PATCH util-macros 3/6] Use XORG_TESTSET_CFLAG in XORG_STRICT_OPTION

2011-11-01 Thread Jeremy Huddleston
Signed-off-by: Jeremy Huddleston --- xorg-macros.m4.in | 28 +--- 1 files changed, 9 insertions(+), 19 deletions(-) diff --git a/xorg-macros.m4.in b/xorg-macros.m4.in index c4a521f..456f78f 100644 --- a/xorg-macros.m4.in +++ b/xorg-macros.m4.in @@ -1443,31 +1443,21 @@ A

[PATCH util-macros 2/6] Add XORG_TESTSET_CFLAG which can be used to test what flags the compiler supports

2011-11-01 Thread Jeremy Huddleston
Signed-off-by: Jeremy Huddleston --- xorg-macros.m4.in | 27 +++ 1 files changed, 27 insertions(+), 0 deletions(-) diff --git a/xorg-macros.m4.in b/xorg-macros.m4.in index 3b02190..c4a521f 100644 --- a/xorg-macros.m4.in +++ b/xorg-macros.m4.in @@ -1378,6 +1378,33 @@ AC_

[PATCH util-macros 1/6] Fix the test for -Werror=attributes

2011-11-01 Thread Jeremy Huddleston
The current test was always failing to compile because 'return 0;' was global rather than in the body of a function. Signed-off-by: Jeremy Huddleston --- xorg-macros.m4.in |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/xorg-macros.m4.in b/xorg-macros.m4.in index 0527df

Re: [PATCH] xfree86: duplicate name and driver from pInfo for NewInputDeviceRequest

2011-11-01 Thread James Cloos
> "PH" == Peter Hutterer writes: PH> xorg.conf devices had the name and driver set in the DDX's InputInfoPtr list PH> but not in the option list for those devices. That information was lost when PH> passing the options into NewInputDeviceRequest. NIDR then refused to start PH> the devices. P

Re: [PATCH] Xext: XCopyArea does not work in Xinerama mode.#25113

2011-11-01 Thread Arvind Umrao
Still waiting for review tag. At bugzilla, 2011BRB_Reviewed by Jeremy -Arvind On 10/15/11 06:57, Arvind Umrao wrote: Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=25113 XCopyArea() does not work in Xinerama mode. XCopyArea does not copy areas of the screen across physical displays. Xc

Re: [PATCH 1/5] dix: don't InitXTestDevices if there's no XTest extension

2011-11-01 Thread Paulo Zanoni
2011/11/1 Julien Cristau : > > XTEST is always defined these days.  Also, IIRC there's a bunch of stuff > in XI that relies on the xtest devices.  Does that still work if you > don't init the devices? It seems you're right. I didn't think on this scenario. Let's just discard this patch then. Sorry

Re: [PATCH 1/5] dix: don't InitXTestDevices if there's no XTest extension

2011-11-01 Thread Julien Cristau
On Tue, Nov 1, 2011 at 11:12:34 -0200, przan...@gmail.com wrote: > From: Paulo Zanoni > > Signed-off-by: Paulo Zanoni > --- > dix/devices.c |5 - > 1 files changed, 4 insertions(+), 1 deletions(-) > > diff --git a/dix/devices.c b/dix/devices.c > index 673a360..9d67c06 100644 > --- a/

Re: [PATCH joystick v2 2/2] Deal with opaque input option types.

2011-11-01 Thread Chase Douglas
On 10/31/2011 06:41 PM, Peter Hutterer wrote: > ABI 14 made the InputOption type opaque, move the existing code to ifdefs > and use the new function calls otherwise. > > Signed-off-by: Peter Hutterer Reviewed-by: Chase Douglas ___ xorg-devel@lists.x.o

[PATCH 5/5] parser: free val.str after xstrtokenize

2011-11-01 Thread przanoni
From: Paulo Zanoni After we tokenize val.str, we discard it. This is just one example: 6 bytes in 1 blocks are definitely lost in loss record 24 of 652 at 0x4C2779D: malloc (in vgpreload_memcheck-amd64-linux.so) by 0x4D744D: xf86getToken (scan.c:400) by 0x4D75F1: xf86getSubToken (scan.c

[PATCH 4/5] parser: free val.str after xf86getBoolValue

2011-11-01 Thread przanoni
From: Paulo Zanoni After we convert the value to a boolean, we discard the string. This is just one example: 3 bytes in 1 blocks are definitely lost in loss record 5 of 657 at 0x4C2779D: malloc (vgpreload_memcheck-amd64-linux.so) by 0x4D744D: xf86getToken (scan.c:400) by 0x4D75F1: xf86

[PATCH 3/5] parser: free scandir's list

2011-11-01 Thread przanoni
From: Paulo Zanoni It seems appropriate to make the function that frees the list elements also free the list. 80 bytes in 1 blocks are definitely lost in loss record 411 of 631 at 0x4C2779D: malloc (vgpreload_memcheck-amd64-linux.so) by 0x4C27927: realloc (vgpreload_memcheck-amd64-linux.so

[PATCH 2/5] Correctly free config file names

2011-11-01 Thread przanoni
From: Paulo Zanoni We call xf86penConfigDirFiles twice, so we overwrite the configDirPath variable, losing the pointer. If we move the pointer management to the upper layer (the function callers), they will be able to call these functions as many times as they want, but they'll have to free those

[PATCH 1/5] dix: don't InitXTestDevices if there's no XTest extension

2011-11-01 Thread przanoni
From: Paulo Zanoni Signed-off-by: Paulo Zanoni --- dix/devices.c |5 - 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/dix/devices.c b/dix/devices.c index 673a360..9d67c06 100644 --- a/dix/devices.c +++ b/dix/devices.c @@ -681,7 +681,10 @@ InitCoreDevices(void) !

[PATCH xserver] mi: remove deprecated miPointerAbsoluteCursor from design doc

2011-11-01 Thread Gaetan Nadon
Function was removed from the code by commit f5409aa026 Reviewed-by: Jeremy Huddleston Signed-off-by: Gaetan Nadon --- hw/dmx/doc/dmx.xml |9 + 1 files changed, 1 insertions(+), 8 deletions(-) diff --git a/hw/dmx/doc/dmx.xml b/hw/dmx/doc/dmx.xml index ce472c2..845eec9 100644 --- a/