Commit Graph

9232 Commits

Author SHA1 Message Date
Adam Jackson
ffaae7c0c6 Remove mibank support
Banked framebuffers are so 1990.  As of 7.4 the only drivers remaining
that used this were chips, neomagic, trident, and vesa.  vesa only used
it when not using shadowfb, which is broadly undesirable anyway, and no
longer uses it at all as of 2.3.0.  neomagic never used it by default,
and support for it is gone in git master.  The other two effectively
only ever used it for ISA chips; since ISA support is now gone from
the server, they have been modified to only compile mibank support when
ISA support is available.

Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-27 11:14:03 -07:00
Jamey Sharp
b5b8f91b82 xfree86: use screen privates for Xv offscreen images.
This replaces a globally-allocated array that depended on MAXSCREENS.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Aaron Plattner <aplattner@nvidia.com>
2010-04-27 11:03:01 -07:00
Jamey Sharp
a1c2acfe79 xfree86: use screen privates for exclusive DGA clients.
Most DGA requests allow at most one client to be using DGA on each
screen. Instead of keeping track of the current client in a
MAXSCREEN-sized array, track it in a per-screen private.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Aaron Plattner <aplattner@nvidia.com>
2010-04-27 11:02:37 -07:00
Jamey Sharp
f9e3a2955d Make Xvfb independent of MAXSCREENS.
If a -screen option specifies a screen number higher than any previously
specified, reallocate the vfb-private array of screen-info structs.

If built with a DIX that still has a MAXSCREENS limit, asking for too
many screens won't be detected until InitOutput calls AddScreen.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-27 10:14:42 -07:00
Jamey Sharp
20e84b0b44 Xvfb: Simplify screen option processing.
Inspired by Jon Turney's "Xwin: Simplify screen option processing"
patch, which does something similar for the Xwin server.

Besides making the code more readable, this eliminates most of Xvfb's
references to MAXSCREENS.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-27 10:14:21 -07:00
Jamey Sharp
eeb8454755 Delete redundant scrnum field from Xvfb private screen-info struct.
The screen number can be inferred from the position in the vfbScreens
array, and it was only used in two places, so it was hardly important.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-27 10:14:05 -07:00
Jamey Sharp
da02178919 Track screens' installed colormaps as screen privates.
Several DDXes allow each screen to have at most one (or in some cases,
exactly one) installed colormap. These all use the same pattern: Declare
a global-lifetime array of MAXSCREENS ColormapPtrs, and index it by
screen number. This patch converts most of those to use screen privates
instead.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-27 10:13:47 -07:00
Jamey Sharp
22c4300ee2 Simplify XineramifyXv.
The structure of the adaptor-matching algorithm was obscured by trying
to use "continue" and "break" as the only control-flow primitives. It's
a lot more clear if you add "return" to that set.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Adam Jackson <ajax@redhat.com>
2010-04-27 10:07:09 -07:00
Peter Hutterer
af170a4ab7 Xext: only update the sprite on pointer events.
A call to miPointerUpdateSprite for the XTEST keyboard may result in a
NULL pointer dereference in miDCPutUpCursor() when the save buffer is NULL.

XTS test case: Xlib 11 KeymapNotify

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2010-04-27 15:50:26 +10:00
Dirk Wallenstein
bac1c5f1be xkb: Fix omissions in geometry initialization #27679
_XkbCopyGeom did not copy all of the data from the source geometry. This
resulted in failures when trying to obtain the keymap from a server
where the default geometry has not been replaced by a custom
configuration.

Signed-off-by: Dirk Wallenstein <halsmit@t-online.de>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2010-04-27 15:50:26 +10:00
Keith Packard
3f63db8919 Merge remote branch 'jamey/for-keith' 2010-04-26 20:18:13 -07:00
Pierre-Loup A. Griffais
41bdb6c003 xf86: Don't crash when switching modes through RandR without owning the VT.
While VT-switched, FB access is disabled and should remain so. Trying to switch
modes in that state would re-enable it, potentially causing crashes if trying
to access it before the driver has recovered from the mode switch.

Signed-off-by: Pierre-Loup A. Griffais <pgriffais@nvidia.com>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-26 20:15:17 -07:00
Adam Jackson
2a763c9023 dix: Default DPMS timeout values to match screensaver values
These have the same default, but if you specify something different with
-s on the command line, only the screensaver time is changed.  As DPMS
is usually what's desired, change it to match.

Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-26 20:04:39 -07:00
Pierre-Loup A. Griffais
518f3b189b mi: don't thrash resources when displaying the software cursor across screens
This changes the DC layer to maintain a persistent set of GCs/pixmaps/pictures
for each pScreen instead of failing to thrash between them when changing
screens.

Signed-off-by: Pierre-Loup A. Griffais <pgriffais@nvidia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Tested-by: Peter Hutterer <peter.hutterer@who-t.net>
2010-04-26 19:40:12 -07:00
Jamey Sharp
54e51de8cd ProcGrabButton: remove redundant error check.
If dixLookupResourceByType did not return Success, it will have set the
pointer to NULL, so the second if will always be true.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2010-04-26 19:24:25 -07:00
Jamey Sharp
7e573b5ccd Kill unused/useless macros in panoramiX.h: BREAK_IF, IF_RETURN, FORCE_ROOT
This header doesn't seem to be used outside the server tree, so I don't
think anything was depending on these except what I've fixed in this
patch.

FORCE_ROOT is not used anywhere, and never has been in all the history
that's in git. ajax removed its FORCE_WIN and FORCE_CMAP companions
three years ago, in 04b87d6dfa.

BREAK_IF and IF_RETURN expanded to exactly the keywords in their names,
which is silly. They were rarely used and served only to make callers
inconsistent with the idioms used elsewhere in the server.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Matt Turner <mattst88@gmail.com>
2010-04-26 19:19:02 -07:00
Jamey Sharp
e372cc58e0 Boolean-or short-circuits, so (a || (!a && ...)) is redundant. Simplify.
Signed-off-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Dan Nicholson <dbn.lists@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
2010-04-26 19:18:41 -07:00
Keith Packard
25d1c6cd37 Exa screen private has SavedSourceValidate, not SourceValidate
Need to check the right field to see if there is a wrapped
SourceValidate function.

Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-26 11:04:38 -07:00
Yaakov Selkowitz
d073e51bee Clarify help strings for disabled features in configure
Features which are disabled by default use the --enable-* syntax to show
how they need to be passed to override the default.

Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Reviewed-by: Mikhail Gusarov <dottedmag@dottedmag.net>
Reviewed-by: Dan Nicholson <dbn.lists@gmail.com>
Reviewed-by: Gaetan Nadon <memsize@videotron.ca>
2010-04-26 11:39:19 -05:00
Yaakov Selkowitz
57409af126 Catch when requested SHA1 implementation is missing
The other SHA1 implementation detections already error out if
specifically requested but were not found.

Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Reviewed-by: Julien Cristau <jcristau@debian.org>
2010-04-26 11:38:37 -05:00
Yaakov Selkowitz
0d8fe2fe5c Prefer libsha1 over libgcrypt
When no SHA1 implementation is specified, we should first prefer
system-builtin solutions (libc/libmd/CommonCrypto), then smaller
implementations over the larger ones.  libsha1 is much smaller than
libgcrypt, so it should be first.

Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Reviewed-by: Mikhail Gusarov <dottedmag@dottedmag.net>
Acked-by: Julien Cristau <jcristau@debian.org>
2010-04-26 11:35:56 -05:00
Yaakov Selkowitz
65a2c09549 Revert "Disable Record by default."
Record was broken during the pre-1.6 development cycle and was not fixed
until 1.7.6.  Now that it is fixed, re-enable it by default.

This reverts commit 3eaecdd66e.

Conflicts:

	configure.ac

Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
2010-04-26 11:35:55 -05:00
Yaakov Selkowitz
6e0d847c27 xfree86: Fix reference to SGML entities
XORG_CHECK_LINUXDOC sets the SGML search path to the parent of X11/defs.ent.

Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Acked-by: Dan Nicholson <dbn.lists@gmail.com>
Tested-by: Gaetan Nadon <memsize@videotron.ca>
2010-04-26 11:35:53 -05:00
Yaakov Selkowitz
04b7d529c0 xfree86: Ignore linuxdoc generated docs
Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Acked-by: Gaetan Nadon <memsize@videotron.ca>
2010-04-26 11:35:52 -05:00
Yaakov Selkowitz
39e5108c78 dmx: use silent rules in doc
Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Acked-by: Gaetan Nadon <memsize@videotron.ca>
2010-04-26 11:35:51 -05:00
Yaakov Selkowitz
3ba2ce5d10 dmx: Ignore linuxdoc generated docs
dmx.txt and scaled.txt are generated from SGML, so they probably never
should have been in version control in the first place.

Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Acked-by: Peter Hutterer <peter.hutterer@who-t.net>
Acked-by: Dan Nicholson <dbn.lists@gmail.com>
2010-04-26 11:35:49 -05:00
Yaakov Selkowitz
40972576b6 Use AC_PROG_SED and respect its result
AC_PROG_SED sets SED as the path to a fully-functional 'sed' (which may
also be called 'gsed' if GNU sed is installed alongside a proprietary
version).

This is a follow up to commit 9be4157391.

Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Reviewed-by: Rémi Cardona <remi@gentoo.org>
2010-04-26 11:35:48 -05:00
Jerome Glisse
b557571dbf exa: avoid calling non existent SourceValidate callback
In unaccel path we were unconditionaly calling the SourceValidate
callback but in some case it could be NULL. Check if we have a
valid callback before calling it.

Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Acked-by: Michel Dänzer <michel@daenzer.net>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-26 09:15:22 -07:00
Keith Packard
0e6e75b04e Revert "exa: avoid calling non existent SourceValidate callback"
This reverts commit daa6f9308f.

This one checked pScreen->SourceValidate instead of
pExaScr->SourceValidate which would cause a segfault when
pExaScr->SourceValidate was NULL.
2010-04-26 09:14:22 -07:00
Jerome Glisse
daa6f9308f exa: avoid calling non existent SourceValidate callback
In unaccel path we were unconditionaly calling the SourceValidate
callback but in some case it could be NULL. Check if we have a
valid callback before calling it.

Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Acked-by: Michel Dänzer <michel@daenzer.net>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-26 08:42:57 -07:00
Tiago Vignatti
edbc56c088 include: remove couple of unused structures fields and bump ABI
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-26 14:53:12 +03:00
Tiago Vignatti
4f8dc1109d dix and others: remove unused arraySize field from ScreenInfo
Bizarre. This seems to never be used before. I left the field in ScreenInfo,
with another name. So, stop looking at it.

Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Aaron Plattner <aplattner@nvidia.com>
2010-04-26 14:35:27 +03:00
Tiago Vignatti
64fd39f2f0 xfree86: no need to assign numScreens again
numScreens is always being assigned to 0 in dix for any server generation.

Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
2010-04-23 16:13:57 +03:00
Jon TURNEY
a7d398e545 Xwin: make screens structures run-time adjustable
Change g_ScreenInfo, an array of winScreenInfo elements, from a
static array of MAXSCREENS elements, to a dynamically allocated one

Fix up the validation that -screen option screen numbers are
contiguous from zero (which possibly didn't work correctly before
anyhow)

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jamey Sharp<jamey@minilop.net>
Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-23 15:59:49 +03:00
Jon TURNEY
d8454ae488 Xwin: Simplify screen option processing
Use an instance of the XWin DDX-specific screen info structure to hold
the current default values, to simplify greatly the code for applying
options to all screens and remove all those loops over MAXSCREENS screens
in the command line option processing

Use g_iNumScreens for tracking the current initialized screen count

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-23 15:55:17 +03:00
Tiago Vignatti
b61870595b xfree86: track screens' installed colormaps as screen privates
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
2010-04-23 15:50:23 +03:00
Tiago Vignatti
a94f5455c7 mi: track screens' installed colormaps as screen privates
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
2010-04-23 15:49:23 +03:00
Jamey Sharp
a2c716eaf6 fb: track screens' installed colormaps as screen privates.
Several DDXes allow each screen to have at most one (or in some cases,
exactly one) installed colormap. These all use the same pattern: Declare
a global-lifetime array of MAXSCREENS ColormapPtrs, and index it by
screen number. This patch converts most of those to use screen privates
instead.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-23 15:32:19 +03:00
Jamey Sharp
e055bef055 xfree86: use screen privates for exclusive DGA clients
Most DGA requests allow at most one client to be using DGA on each screen.
Instead of keeping track of the current client in a MAXSCREEN-sized array,
track it in a per-screen private.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-23 15:32:01 +03:00
Jamey Sharp
7c9733d063 xfree86: use screen privates for Xv offscreen images.
This replaces a globally-allocated array that depended on MAXSCREENS.

Signed-off-by: Jamey Sharp <jamey@minilop.net>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2010-04-23 15:30:03 +03:00
Tiago Vignatti
35d208125f xfree86: fix not reached code in fi1236 driver from i2c
This issue was introduced in the first dump of the code in 2004. I haven't
check what's the correct fix for it so I simply kept the behaviour of someone
calling this and removed the unreachable code.

Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-21 16:16:26 -07:00
Keith Packard
7ac6a6b7d0 Merge remote branch 'vignatti/for-keith'
Conflicts:
	exa/exa.c

Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-21 16:07:38 -07:00
Keith Packard
0782894b57 Xvfb: Usage message typo fix.
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-21 16:00:28 -07:00
Keith Packard
ee3412b870 Restore some unused win32 debug code accidentally removed with unifdef
unifdef found some code covered by

which it decided to remove. This patch simply restores that in case
someone wants it back.

Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-21 15:58:23 -07:00
Peter Hutterer
e3d2a7a613 Revert "mi: don't thrash resources when displaying the software cursor across screens"
This commit leads to a segfault on the very first XTS test case.

Backtrace:
0: /opt/xorg/bin/Xorg (xorg_backtrace+0x3b) [0x80a33db]
1: /opt/xorg/bin/Xorg (0x8048000+0x62a75) [0x80aaa75]
2: (vdso) (__kernel_rt_sigreturn+0x0) [0x5d140c]
3: /lib/libc.so.6 (0x9bb000+0x73579) [0xa2e579]
4: /lib/libc.so.6 (realloc+0xe0) [0xa2e830]
5: /opt/xorg/bin/Xorg (Xrealloc+0x33) [0x80a3f33]
6: /opt/xorg/bin/Xorg (0x8048000+0x1ab79) [0x8062b79]
7: /opt/xorg/bin/Xorg (0x8048000+0x1ac4e) [0x8062c4e]
8: /opt/xorg/bin/Xorg (RegisterExtensionNames+0x2ce) [0x8062fbe]
9: /opt/xorg/bin/Xorg (AddExtension+0x19a) [0x807bd7a]
10: /opt/xorg//lib/xorg/modules/extensions/libextmod.so (0x728000+0x1169a)
[0x73969a]
11: /opt/xorg/bin/Xorg (InitExtensions+0x85) [0x80c0eb5]
12: /opt/xorg/bin/Xorg (0x8048000+0x1a51d) [0x806251d]
13: /lib/libc.so.6 (__libc_start_main+0xe6) [0x9d1bb6]
14: /opt/xorg/bin/Xorg (0x8048000+0x1a2a1) [0x80622a1]
Segmentation fault at address 0x10b2d5f8

valgrind output:
==5069== Invalid read of size 4
==5069==    at 0x80F928D: FreePicture (picture.c:1531)
==5069==    by 0x818DDEF: miDCDeviceCleanup (midispcur.c:867)
==5069==    by 0x81B97F0: miSpriteDeviceCursorCleanup (misprite.c:968)
==5069==    by 0x80995FA: miPointerDeviceCleanup (mipointer.c:292)
==5069==    by 0x807973E: CloseDevice (devices.c:840)
==5069==    by 0x80799B6: CloseDownDevices (devices.c:933)
==5069==    by 0x8062705: main (main.c:309)
==5069==  Address 0x4cce844 is 12 bytes inside a block of size 84 free'd
==5069==    at 0x40057F6: free (vg_replace_malloc.c:325)
==5069==    by 0x80A3DE0: Xfree (utils.c:1154)
==5069==    by 0x80F9332: FreePicture (picture.c:1576)
==5069==    by 0x80FBB4B: PictureDestroyWindow (picture.c:69)
==5069==    by 0x810B1A3: damageDestroyWindow (damage.c:1840)
==5069==    by 0x80864F1: FreeWindowResources (window.c:846)
==5069==    by 0x8086812: DeleteWindow (window.c:925)
==5069==    by 0x806B53E: FreeClientResources (resource.c:806)
==5069==    by 0x806B60F: FreeAllResources (resource.c:823)
==5069==    by 0x80626E4: main (main.c:299)
==5069==
==5069== Invalid write of size 4
==5069==    at 0x80F9295: FreePicture (picture.c:1531)
==5069==    by 0x818DDEF: miDCDeviceCleanup (midispcur.c:867)
==5069==    by 0x81B97F0: miSpriteDeviceCursorCleanup (misprite.c:968)
==5069==    by 0x80995FA: miPointerDeviceCleanup (mipointer.c:292)
==5069==    by 0x807973E: CloseDevice (devices.c:840)
==5069==    by 0x80799B6: CloseDownDevices (devices.c:933)
==5069==    by 0x8062705: main (main.c:309)
==5069==  Address 0x4cce844 is 12 bytes inside a block of size 84 free'd
==5069==    at 0x40057F6: free (vg_replace_malloc.c:325)
==5069==    by 0x80A3DE0: Xfree (utils.c:1154)
==5069==    by 0x80F9332: FreePicture (picture.c:1576)
==5069==    by 0x80FBB4B: PictureDestroyWindow (picture.c:69)
==5069==    by 0x810B1A3: damageDestroyWindow (damage.c:1840)
==5069==    by 0x80864F1: FreeWindowResources (window.c:846)
==5069==    by 0x8086812: DeleteWindow (window.c:925)
==5069==    by 0x806B53E: FreeClientResources (resource.c:806)
==5069==    by 0x806B60F: FreeAllResources (resource.c:823)
==5069==    by 0x80626E4: main (main.c:299)

XTS test case: Xproto pAllocColor

This reverts commit 00b8b7ad61.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-04-21 15:54:21 -07:00
Tiago Vignatti
f7ef6fd9a1 xfree86: fix not reached code in tty code
CLEARRTS_SUPPORT cannot be triggered at all. Notice that mouse driver manual
page states the support for it though.

Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
2010-04-21 18:07:28 +03:00
Tiago Vignatti
b36eeb713a xkb: check for NULL pointer before dereferences it in XkbWriteXKBSymbols
move srv assignment to before it's being used. Also, check for xkb being nil.

Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
2010-04-21 18:07:25 +03:00
Tiago Vignatti
471f350c99 exa: don't need to check for NULL pointer if we already assumed it has a value
the alternative would be to check ps in the beginning of the function.

Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Acked-by: Michel Dänzer <michel@daenzer.net>
2010-04-21 18:07:22 +03:00
Tiago Vignatti
96784f4fcb xkb: check for NULL pointer before dereferences it in XkbAddClientResource
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Dan Nicholson <dbn.lists@gmail.com>
2010-04-21 18:07:20 +03:00
Tiago Vignatti
057c147541 Xi: check for NULL pointer before dereferences it in ListButtonInfo
Both dev and dev->button are already used before their checking were being
performed. So check on the beginning.

Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Dan Nicholson <dbn.lists@gmail.com>
2010-04-21 18:07:19 +03:00