summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xserver/ChangeLog452
-rw-r--r--xserver/Xext/security.c4
-rw-r--r--xserver/Xext/shm.c2
-rw-r--r--xserver/Xext/xace.c4
-rw-r--r--xserver/Xext/xselinux_ext.c6
-rw-r--r--xserver/Xext/xselinux_hooks.c4
-rw-r--r--xserver/Xi/exevents.c2
-rw-r--r--xserver/Xi/xichangehierarchy.c15
-rw-r--r--xserver/Xi/xipassivegrab.c10
-rw-r--r--xserver/configure151
-rw-r--r--xserver/configure.ac19
-rw-r--r--xserver/dix/dispatch.c33
-rw-r--r--xserver/dix/dixutils.c7
-rw-r--r--xserver/dix/events.c2
-rw-r--r--xserver/dix/extension.c14
-rw-r--r--xserver/hw/dmx/examples/Makefile.am56
-rw-r--r--xserver/hw/dmx/examples/Makefile.in85
-rw-r--r--xserver/hw/kdrive/linux/keyboard.c6
-rw-r--r--xserver/hw/kdrive/linux/ms.c4
-rw-r--r--xserver/hw/kdrive/linux/ps2.c4
-rw-r--r--xserver/hw/xfree86/common/xf86Xinput.c11
-rw-r--r--xserver/hw/xquartz/bundle/Info.plist.cpp8
-rw-r--r--xserver/include/dixstruct.h1
-rw-r--r--xserver/include/extension.h2
-rw-r--r--xserver/mi/mibitblt.c2
-rw-r--r--xserver/os/backtrace.c6
-rw-r--r--xserver/os/client.c118
-rw-r--r--xserver/record/record.c8
-rw-r--r--xserver/render/animcur.c3
-rw-r--r--xserver/xfixes/cursor.c4
30 files changed, 856 insertions, 187 deletions
diff --git a/xserver/ChangeLog b/xserver/ChangeLog
index ab079f2a3..29c791133 100644
--- a/xserver/ChangeLog
+++ b/xserver/ChangeLog
@@ -1,3 +1,455 @@
+commit e597f0119cd69b6d9edf86d06d941468f90d8e6d
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Fri Jan 27 21:07:17 2012 -0800
+
+ configure.ac: 1.11.4
+
+ Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+
+commit 6c491463ee7a3637c8aae7ddae9625b36b792078
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Fri Jan 20 23:54:58 2012 -0800
+
+ 1.11.3.902 (1.11.4 RC2)
+
+ Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+
+commit b747a91485184649c05aba6fa10734f70e926032
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Wed Jan 18 11:47:21 2012 -0800
+
+ XQuartz: Bump bundle version to 2.7.1
+
+ Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+
+commit a1ed67fa0551ee2b39d002d3b786a2017b37c7ac
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Fri Jan 6 13:20:45 2012 +1000
+
+ render: don't bother with animated cursors on floating slaves (#39989)
+
+ X.Org Bug 39989 <http://bugs.freedesktop.org/show_bug.cgi?id=39989>
+
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+ (cherry picked from commit bbb6b8c834e0e1491ca14403b5d0840dd14380d3)
+
+commit f89c39e6c9e20ffc3c1ae228ee601c2ab9007ff4
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Mon Jan 9 15:04:10 2012 +1000
+
+ dix: Update pointer limits for floating devices too (#43635)
+
+ When the screen is restructured, the pointer limits need to be reset for
+ floating slave devices as well, not just for master pointers. Only skip
+ devices that don't have a cursor (attached slaves and keyboard)
+
+ Bug reproducer: float an absolute slave device, rotate the screen - the
+ device is now confined to a section of the screen only.
+
+ X.Org Bug 43635 <http://bugs.freedesktop.org/show_bug.cgi?id=43635>
+
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
+ (cherry picked from commit 35bd77e9d0701daae87d681900d749604fc6471f)
+
+commit dea9377a257a402b2c7fe4a96c958d951a7d4579
+Author: Zhigang Gong <zhigang.gong@linux.intel.com>
+Date: Wed Jan 4 07:01:19 2012 +0000
+
+ mi/mibitblt: Fix an overflow bug of bit shift.
+
+ When depth equal to 32 and planeMask equal to 0, the overflow will
+ occur and cause the pixmap can't be cleared. There are some test
+ cases in XTS hit this bug, and this fix can eliminate the corresponding
+ failures.
+
+ Signed-off-by: Zhigang Gong <zhigang.gong@linux.intel.com>
+ Reviewed-by: Adam Jackson <ajax@redhat.com>
+ Signed-off-by: Keith Packard <keithp@keithp.com>
+ (cherry picked from commit f4956faab9ccf9aba6cf9603f4489f5dad19a347)
+
+commit d2db5100b1bafeeea8c1febd390631c8f8abb094
+Author: Alan Coopersmith <alan.coopersmith@oracle.com>
+Date: Fri Oct 28 21:29:50 2011 -0700
+
+ Convert DetermineClientCmd to use strdup instead of malloc+strncpy
+
+ *cmdname is initialized to NULL earlier in the function, so it's
+ okay to overwrite it with NULL if strdup fails, don't need that
+ extra check.
+
+ Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
+ Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+ (cherry picked from commit 780133f9ae7fada462714b47e79d26075bbd9abe)
+
+commit 5b28bcb340e279e7f4e76617e86b439092367690
+Author: Adam Jackson <ajax@redhat.com>
+Date: Tue Dec 13 21:23:12 2011 -0500
+
+ dix: Tune dixLookupDrawable for success
+
+ The vast vast vast majority of resource lookups are successful. Move some
+ work to the error paths so we don't punish success.
+
+ Before:
+ 40000000 trep @ 0.0009 msec (1109091.3/sec): PutImage 10x10 square
+ 60000000 trep @ 0.0005 msec (2072652.2/sec): ShmPutImage 10x10 square
+
+ After:
+ 40000000 trep @ 0.0009 msec (1148346.9/sec): PutImage 10x10 square
+ 60000000 trep @ 0.0005 msec (2091666.1/sec): ShmPutImage 10x10 square
+
+ Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
+ Signed-off-by: Adam Jackson <ajax@redhat.com>
+ (cherry picked from commit 8f9bdfd293ad8e45755efe8d764b4dcc2a724f51)
+
+commit e1ea93fec93b13d18df4451210aaaf322b769b6a
+Author: Adam Jackson <ajax@redhat.com>
+Date: Tue Dec 13 20:23:40 2011 -0500
+
+ dix: Tune dtrace hooks around Dispatch
+
+ Don't call LookupMajorName if the hooks aren't active, it's quite expensive.
+
+ Before:
+ 40000000 trep @ 0.0009 msec (1087458.5/sec): PutImage 10x10 square
+ 60000000 trep @ 0.0005 msec (2012238.6/sec): ShmPutImage 10x10 square
+
+ After:
+ 40000000 trep @ 0.0009 msec (1109091.3/sec): PutImage 10x10 square
+ 60000000 trep @ 0.0005 msec (2072652.2/sec): ShmPutImage 10x10 square
+
+ Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
+ Signed-off-by: Adam Jackson <ajax@redhat.com>
+ (cherry picked from commit 83a98543b58c661a22574a6f8d8f9d777c0955b8)
+
+commit 9eaa0b5c89f645c50ea90e07e8b49ebacf4349a0
+Author: Adam Jackson <ajax@redhat.com>
+Date: Tue Dec 13 21:00:05 2011 -0500
+
+ xace: ricer tuning for XaceHook
+
+ gcc doesn't want to hoist the check for XaceHooks[hook] != NULL above the
+ varargs code for some reason, so do it ourselves.
+
+ Before:
+ 40000000 trep @ 0.0010 msec (1050420.2/sec): PutImage 10x10 square
+ 60000000 trep @ 0.0005 msec (1921147.6/sec): ShmPutImage 10x10 square
+
+ After:
+ 40000000 trep @ 0.0009 msec (1087458.5/sec): PutImage 10x10 square
+ 60000000 trep @ 0.0005 msec (2012238.6/sec): ShmPutImage 10x10 square
+
+ Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
+ Signed-off-by: Adam Jackson <ajax@redhat.com>
+ (cherry picked from commit 11977fab546da35d579ebe285e3c26864007805e)
+
+commit a3b6ecc893e17028cfbe16d8d7981c9037fc0766
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Tue Jan 3 10:45:45 2012 +1000
+
+ xfree86: split warning about missing identifier or input driver
+
+ Check for identifier first and bail if it's missing (also remove the current
+ identifier check after we've already bailed due to missing identifiers)
+
+ If a driver is missing, warn but also say that we may have added this device
+ already. I see too many bugreports with incorrectly shortened log files.
+
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Cyril Brulebois <kibi@debian.org>
+ (cherry picked from commit 75953ccb9e9e5f1dbbaa44c714716a0049e22aae)
+
+commit 4a339afc586d55a9a248b893f007219d79c72600
+Author: Julien Cristau <jcristau@debian.org>
+Date: Fri Dec 30 20:41:25 2011 +0100
+
+ os: don't ignore failure from dladdr
+
+ If dladdr returns 0, don't go and use the returned Dl_info, it may
+ contain garbage.
+
+ X.Org bug#44315 <https://bugs.freedesktop.org/show_bug.cgi?id=44315>
+
+ Reported-and-tested-by: Cyril Brulebois <kibi@debian.org>
+ Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+ Reviewed-by: Cyril Brulebois <kibi@debian.org>
+ Signed-off-by: Julien Cristau <jcristau@debian.org>
+ (cherry picked from commit 6269977c91071e0ea16ca5b4b8e15fd6db0b6fcf)
+
+commit 9a4be7e99f0e832df87b8e7fb548793dd4b52717
+Author: Matthieu Herrb <matthieu.herrb@laas.fr>
+Date: Mon Jan 2 13:23:59 2012 +0000
+
+ Add OpenBSD support to DetermineClientCmd()
+
+ Uses kvm_getargv() from libkvm.
+
+ Signed-off-by: Matthieu Herrb <matthieu.herrb@laas.fr>
+ Reviewed-by: Adam Jackson <ajax@redhat.com>
+ Signed-off-by: Keith Packard <keithp@keithp.com>
+ (cherry picked from commit 6d6d4cb6043905d850834946e9bfc526ed5a9ef7)
+
+commit 8046717d720c1bbbf02ba986622bc96c6b52a36c
+Author: Alan Coopersmith <alan.coopersmith@oracle.com>
+Date: Sat Dec 24 10:00:56 2011 -0800
+
+ Add Solaris support to DetermineClientCmd
+
+ Uses /proc/pid/psinfo to read command & partial arguments.
+
+ Moves cmdsize & argsize variables into non-Solaris #else clause
+ to avoid unused variable warnings.
+
+ Fixes format mismatch errors when building with DEBUG defined on
+ a 64-bit platform (where Mask is defined as CARD32).
+
+ Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
+ Reviewed-by: Rami Ylimäki <rami.ylimaki@vincit.fi>
+ Signed-off-by: Keith Packard <keithp@keithp.com>
+ (cherry picked from commit cfc4c3d7fa8bd4da4c08b2ab8e6f85435f75353a)
+
+commit cea9f9f273cb525cb5daa2d2819d3f635582cb24
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Fri Jan 6 22:01:03 2012 -0800
+
+ configure.ac: 1.11.3.901 (1.11.4 RC1)
+
+ Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+
+commit b15be8547d4d204f3e498f52d86713a76766e871
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Fri Jan 6 22:12:14 2012 -0800
+
+ Xi: Fix mishandled git merge
+
+ Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+
+commit 82e0ae042379181eb143431e1413084432a17079
+Merge: f9b00c2 4e4bb31
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Mon Jan 2 20:58:22 2012 -0500
+
+ Merge remote-tracking branch 'whot/server-1.11-branch' into server-1.11-branch
+
+commit 4e4bb319a4f9510277557f65676948cd1db10e93
+Author: Carlos Garnacho <carlosg@gnome.org>
+Date: Tue Dec 13 15:41:23 2011 +0100
+
+ Xi: assign correct grab_mode/other_device_mode in XI2 passive grabs
+
+ CreateGrab() expects the keyboard mode to be stored in grab_mode, and the
+ pointer mode in other_device_mode, so respect this in passive XI2 grabs,
+ and switch modes if needed.
+
+ Signed-off-by: Carlos Garnacho <carlosg@gnome.org>
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
+ (cherry picked from commit 5b169cb695bd450d7f64e3800f00c9237ee67f96)
+
+commit 8c73f6bcbdc04380cc41d9f6dc7e849c7c4f9298
+Author: Alan Coopersmith <alan.coopersmith@oracle.com>
+Date: Thu Dec 8 21:52:07 2011 -0800
+
+ Change disable_clientpointer return type to void
+
+ It doesn't return anything, nor does it's caller expect it to.
+
+ Fixes Solaris Studio compiler error:
+ "xichangehierarchy.c", line 214: Function has no return statement : disable_clientpointer
+
+ Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
+ Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Signed-off-by: Keith Packard <keithp@keithp.com>
+ (cherry picked from commit 372a6f10dc2d74d2d179e8b92449e9b8636a99ef)
+
+commit ae4272a5742119b10074a542d0dcd4c493cb83e4
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Wed Nov 30 09:06:06 2011 +1000
+
+ xfixes: don't dereference a NULL cursor
+
+ If the new cursor is the NULL cursor, don't dereference it and use zeros
+ instead.
+
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+ (cherry picked from commit 1ab50be938524dcd4a9e56d27e3b96a27c2db2c0)
+
+commit 20efd3c15829d8fbb3610d5af41b67a627e63d21
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Tue Nov 29 16:15:37 2011 +1000
+
+ Xi: when removing a device, reset ClientPointers where needed
+
+ if a client had the to-be-removed device as ClientPointer, reset to NULL.
+
+ Fixes #43165
+
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+ (cherry picked from commit d2ebbcdaf6b13d70eee704b1764ff349e1be22a0)
+
+commit cf296f2eeffe4b438e9378268f84a1f63c555e52
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Wed Nov 9 15:31:10 2011 +1000
+
+ Xext: don't swap CARD8 in SProcSELinuxQueryVersion
+
+ xselinux_ext.c: In function 'SELinuxSendItemsToClient':
+ xselinux_ext.c:340:16: warning: unused variable 'n' [-Wunused-variable]
+ xselinux_ext.c: In function 'SProcSELinuxQueryVersion':
+ xselinux_ext.c:532:62: error: call to 'wrong_size' declared with attribute
+ error: wrong sized variable passed to swap
+ xselinux_ext.c:533:62: error: call to 'wrong_size' declared with attribute
+ error: wrong sized variable passed to swap
+
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Julien Cristau <jcristau@debian.org>
+ (cherry picked from commit bb4aa1f263ad38c175bfda3b7e6c325260ce3f28)
+
+ Conflicts:
+
+ Xext/xselinux_ext.c
+
+commit 4b386610243b1a30db7e4cdb89cb43012198407d
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Fri Dec 16 12:41:08 2011 +1000
+
+ dix: button state must show the logical buttons, not physical buttons
+
+ If the device is mapped 3 2 1, a click on physical button 1 sends a button 3
+ press, but the state was set for button 1. Fix this, the state must be set
+ for that button's logical mapping.
+
+ https://bugzilla.gnome.org/show_bug.cgi?id=655928
+
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ (cherry picked from commit 9567d21e85b99febe805263a4d93b15fd1f7ab42)
+
+ Conflicts:
+
+ dix/inpututils.c
+
+commit f9b00c2aba496fe470c24d0f8d3e3d0e3b05aa65
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Tue Nov 29 16:15:37 2011 +1000
+
+ Xi: when removing a device, reset ClientPointers where needed
+
+ if a client had the to-be-removed device as ClientPointer, reset to NULL.
+
+ Fixes #43165
+
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+ (cherry picked from commit d2ebbcdaf6b13d70eee704b1764ff349e1be22a0)
+
+commit e4984b3023351b5fcc506f4a196ad699db8b0535
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Wed Nov 30 09:06:06 2011 +1000
+
+ xfixes: don't dereference a NULL cursor
+
+ If the new cursor is the NULL cursor, don't dereference it and use zeros
+ instead.
+
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+ (cherry picked from commit 1ab50be938524dcd4a9e56d27e3b96a27c2db2c0)
+
+commit 625d1088192a9ad972c20fbdbcb4bb9fda979157
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Fri Dec 16 09:15:25 2011 -0500
+
+ dmx: force -fno-strict-aliasing for xinput example
+
+ Compiler warning:
+ xinput.c:272: warning: dereferencing pointer 'e' does break strict-aliasing
+ rules
+
+ The code itself is the usual XInput client-side code:
+ XEvent event;
+ XDeviceMotionEvent *e = (XDeviceMotionEvent *)&event;
+ XNextEvent(display, &event);
+ printf("%d\n", e->type);
+
+ Since XDeviceMotionEvent is not guaranteed the same size as XEvent, clients
+ must use pointer aliasing as above when using the XNextEvent API. Disable
+ strict aliasing for this example.
+
+ Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Reviewed-by: Gaetan Nadon <memsize@videotron.ca>
+ Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+ Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
+ Signed-off-by: Keith Packard <keithp@keithp.com>
+ (cherry picked from commit 3aca8199405cff5097ee5813605ec78b5ae44a43)
+
+commit 53e347b22bb79043243e25891cd7d6f374a8aa23
+Author: Keith Packard <keithp@keithp.com>
+Date: Tue Nov 8 10:13:15 2011 -0800
+
+ Save major/minor opcodes in ClientRec for RecordAReply
+
+ The record extension needs the major and minor opcodes in the reply
+ hook, but the request buffer may have been freed by the time the hook
+ is invoked. Saving the request major and minor codes as the request is
+ executed avoids fetching from the defunct request buffer.
+
+ This patch also eliminates the public MinorOpcodeOfRequest function,
+ inlining it into Dispatch. Usages of that function have been replaced
+ with direct access to the new ClientRec field.
+
+ Signed-off-by: Keith Packard <keithp@keithp.com>
+ Reviewed-by: Jamey Sharp <jamey@minilop.net>
+ (cherry picked from commit fb22a408c69a84f81905147de9e82cf66ffb6eb2)
+
+ Conflicts:
+
+ include/extension.h
+
+commit b736f8c92bae7773ff6e1fca886f9ccc50156488
+Author: Julien Cristau <jcristau@debian.org>
+Date: Sat Nov 5 13:00:07 2011 +0100
+
+ Fix ShmPutImage for XYBitmap
+
+ We can't call CopyArea in that case because the image has depth 1, which
+ might not match the target drawable, so we might overrun the shm
+ segment. Commit 11817a881cb93a89788105d1e575a468f2a8d27c apparently
+ fixed a similar bug for XYPixmap, but missed the bitmap case.
+
+ Fixes: http://bugs.debian.org/629611
+
+ Thanks to Alan Curry for diagnosing this and providing a test case.
+
+ Reported-and-tested-by: Alan Curry <pacman@kosh.dhis.org>
+ Reviewed-by: Peter Harris <pharris@opentext.com>
+ Signed-off-by: Julien Cristau <jcristau@debian.org>
+ (cherry picked from commit 08ec4da6a7617637914bee1636858474213cf39d)
+
+commit b2a4c09507b267495ea5e4c2e05373b323c80edf
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Sat Dec 17 12:56:59 2011 -0800
+
+ kdrive/linux: Fix compilation with -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast
+
+ Reported-by: Arkadiusz Miśkiewicz <arekm@maven.pl>
+ Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+ Reviewed-by: Jamey Sharp <jamey@minilop.net>
+ (cherry picked from commit 1deede3c48d5ac91f50774c79f02afc6e036614e)
+
+commit beaa7ad2ec45811e16722283a8b557a08e91ef18
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Sat Dec 17 12:25:26 2011 -0800
+
+ configure.ac: Make Xephyr dependency error message more informative
+
+ Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+ Reviewed-by: Jamey Sharp <jamey@minilop.net>
+ (cherry picked from commit d0170d54c71fc761b8f1ae7a0e555dc2ca23cf9c)
+
commit 41524dd61020f2a446ec54643fa17aa791338cac
Author: Jeremy Huddleston <jeremyhu@apple.com>
Date: Fri Dec 16 17:47:46 2011 -0800
diff --git a/xserver/Xext/security.c b/xserver/Xext/security.c
index 8673880d1..aa78e540d 100644
--- a/xserver/Xext/security.c
+++ b/xserver/Xext/security.c
@@ -148,9 +148,7 @@ SecurityLabelInitial(void)
static _X_INLINE const char *
SecurityLookupRequestName(ClientPtr client)
{
- int major = ((xReq *)client->requestBuffer)->reqType;
- int minor = MinorOpcodeOfRequest(client);
- return LookupRequestName(major, minor);
+ return LookupRequestName(client->majorOp, client->minorOp);
}
diff --git a/xserver/Xext/shm.c b/xserver/Xext/shm.c
index 4141a8fe6..d2ae08772 100644
--- a/xserver/Xext/shm.c
+++ b/xserver/Xext/shm.c
@@ -482,7 +482,7 @@ doShmPutImage(DrawablePtr dst, GCPtr pGC,
{
PixmapPtr pPixmap;
- if (format == ZPixmap || depth == 1) {
+ if (format == ZPixmap || (format == XYPixmap && depth == 1)) {
pPixmap = GetScratchPixmapHeader(dst->pScreen, w, h, depth,
BitsPerPixel(depth),
PixmapBytePad(w, depth),
diff --git a/xserver/Xext/xace.c b/xserver/Xext/xace.c
index c757cad05..ef69fe363 100644
--- a/xserver/Xext/xace.c
+++ b/xserver/Xext/xace.c
@@ -101,6 +101,10 @@ int XaceHook(int hook, ...)
} u;
int *prv = NULL; /* points to return value from callback */
va_list ap; /* argument list */
+
+ if (!XaceHooks[hook])
+ return Success;
+
va_start(ap, hook);
/* Marshal arguments for passing to callback.
diff --git a/xserver/Xext/xselinux_ext.c b/xserver/Xext/xselinux_ext.c
index 374571c4b..85ca2dc8e 100644
--- a/xserver/Xext/xselinux_ext.c
+++ b/xserver/Xext/xselinux_ext.c
@@ -528,12 +528,6 @@ ProcSELinuxDispatch(ClientPtr client)
static int
SProcSELinuxQueryVersion(ClientPtr client)
{
- REQUEST(SELinuxQueryVersionReq);
- int n;
-
- REQUEST_SIZE_MATCH(SELinuxQueryVersionReq);
- swaps(&stuff->client_major, n);
- swaps(&stuff->client_minor, n);
return ProcSELinuxQueryVersion(client);
}
diff --git a/xserver/Xext/xselinux_hooks.c b/xserver/Xext/xselinux_hooks.c
index f1d8e5d2f..0d4c9ab11 100644
--- a/xserver/Xext/xselinux_hooks.c
+++ b/xserver/Xext/xselinux_hooks.c
@@ -263,8 +263,8 @@ SELinuxAudit(void *auditdata,
if (client) {
REQUEST(xReq);
if (stuff) {
- major = stuff->reqType;
- minor = MinorOpcodeOfRequest(client);
+ major = client->majorOp;
+ minor = client->minorOp;
}
}
if (audit->id)
diff --git a/xserver/Xi/exevents.c b/xserver/Xi/exevents.c
index dcb496fd4..9d43564f8 100644
--- a/xserver/Xi/exevents.c
+++ b/xserver/Xi/exevents.c
@@ -927,7 +927,7 @@ ProcessOtherEvent(InternalEvent *ev, DeviceIntPtr device)
for (i = 0; mouse && mouse->button && i < mouse->button->numButtons; i++)
if (BitIsOn(mouse->button->down, i))
- SetBit(event->buttons, i);
+ SetBit(event->buttons, mouse->button->map[i]);
if (kbd && kbd->key)
{
diff --git a/xserver/Xi/xichangehierarchy.c b/xserver/Xi/xichangehierarchy.c
index 96ead6fcd..3facadd92 100644
--- a/xserver/Xi/xichangehierarchy.c
+++ b/xserver/Xi/xichangehierarchy.c
@@ -202,6 +202,19 @@ unwind:
return rc;
}
+static void
+disable_clientpointer(DeviceIntPtr dev)
+{
+ int i;
+
+ for (i = 0; i < currentMaxClients; i++)
+ {
+ ClientPtr client = clients[i];
+ if (client && client->clientPtr == dev)
+ client->clientPtr = NULL;
+ }
+}
+
static int
remove_master(ClientPtr client, xXIRemoveMasterInfo *r,
int flags[MAXDEVICES])
@@ -252,6 +265,8 @@ remove_master(ClientPtr client, xXIRemoveMasterInfo *r,
if (rc != Success)
goto unwind;
+ disable_clientpointer(ptr);
+
/* Disabling sends the devices floating, reattach them if
* desired. */
if (r->return_mode == XIAttachToMaster)
diff --git a/xserver/Xi/xipassivegrab.c b/xserver/Xi/xipassivegrab.c
index 5cdd8aca6..af46282c8 100644
--- a/xserver/Xi/xipassivegrab.c
+++ b/xserver/Xi/xipassivegrab.c
@@ -140,11 +140,17 @@ ProcXIPassiveGrabDevice(ClientPtr client)
memset(&param, 0, sizeof(param));
param.grabtype = GRABTYPE_XI2;
param.ownerEvents = stuff->owner_events;
- param.this_device_mode = stuff->grab_mode;
- param.other_devices_mode = stuff->paired_device_mode;
param.grabWindow = stuff->grab_window;
param.cursor = stuff->cursor;
+ if (IsKeyboardDevice(dev)) {
+ param.this_device_mode = stuff->grab_mode;
+ param.other_devices_mode = stuff->paired_device_mode;
+ } else {
+ param.this_device_mode = stuff->paired_device_mode;
+ param.other_devices_mode = stuff->grab_mode;
+ }
+
if (stuff->cursor != None)
{
status = dixLookupResourceByType(&tmp, stuff->cursor,
diff --git a/xserver/configure b/xserver/configure
index 6eaada34b..c7beed901 100644
--- a/xserver/configure
+++ b/xserver/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.62 for xorg-server 1.11.3.
+# Generated by GNU Autoconf 2.62 for xorg-server 1.11.4.
#
# Report bugs to <https://bugs.freedesktop.org/enter_bug.cgi?product=xorg>.
#
@@ -676,8 +676,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
# Identity of this package.
PACKAGE_NAME='xorg-server'
PACKAGE_TARNAME='xorg-server'
-PACKAGE_VERSION='1.11.3'
-PACKAGE_STRING='xorg-server 1.11.3'
+PACKAGE_VERSION='1.11.4'
+PACKAGE_STRING='xorg-server 1.11.4'
PACKAGE_BUGREPORT='https://bugs.freedesktop.org/enter_bug.cgi?product=xorg'
ac_unique_file="Makefile.am"
@@ -2016,7 +2016,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures xorg-server 1.11.3 to adapt to many kinds of systems.
+\`configure' configures xorg-server 1.11.4 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -2086,7 +2086,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of xorg-server 1.11.3:";;
+ short | recursive ) echo "Configuration of xorg-server 1.11.4:";;
esac
cat <<\_ACEOF
@@ -2480,7 +2480,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-xorg-server configure 1.11.3
+xorg-server configure 1.11.4
generated by GNU Autoconf 2.62
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -2494,7 +2494,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by xorg-server $as_me 1.11.3, which was
+It was created by xorg-server $as_me 1.11.4, which was
generated by GNU Autoconf 2.62. Invocation command line was
$ $0 $@
@@ -2860,7 +2860,7 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-RELEASE_DATE="2011-12-16"
+RELEASE_DATE="2012-01-27"
am__api_version="1.9"
ac_aux_dir=
@@ -3145,7 +3145,7 @@ fi
# Define the identity of the package.
PACKAGE='xorg-server'
- VERSION='1.11.3'
+ VERSION='1.11.4'
cat >>confdefs.h <<_ACEOF
@@ -25039,6 +25039,13 @@ _ACEOF
else
CLIENTIDS=no
fi
+if test "x$CLIENTIDS" = xyes; then
+ case $host_os in
+ openbsd*)
+ SYS_LIBS="$SYS_LIBS -lkvm"
+ ;;
+ esac
+fi
{ $as_echo "$as_me:$LINENO: result: $CLIENTIDS" >&5
$as_echo "$CLIENTIDS" >&6; }
@@ -32864,6 +32871,7 @@ _ACEOF
XEPHYR_REQUIRED_LIBS="$XEPHYR_REQUIRED_LIBS $LIBGL libdrm"
fi
+ if test "x$XEPHYR" = xauto; then
pkg_failed=no
{ $as_echo "$as_me:$LINENO: checking for XEPHYR" >&5
@@ -32925,23 +32933,128 @@ fi
{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
- xephyr="no"
+ XEPHYR="no"
elif test $pkg_failed = untried; then
- xephyr="no"
+ XEPHYR="no"
else
XEPHYR_CFLAGS=$pkg_cv_XEPHYR_CFLAGS
XEPHYR_LIBS=$pkg_cv_XEPHYR_LIBS
{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
- xephyr="yes"
+ XEPHYR="yes"
+fi
+ elif test "x$XEPHYR" = xyes ; then
+
+pkg_failed=no
+{ $as_echo "$as_me:$LINENO: checking for XEPHYR" >&5
+$as_echo_n "checking for XEPHYR... " >&6; }
+
+if test -n "$PKG_CONFIG"; then
+ if test -n "$XEPHYR_CFLAGS"; then
+ pkg_cv_XEPHYR_CFLAGS="$XEPHYR_CFLAGS"
+ else
+ if test -n "$PKG_CONFIG" && \
+ { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"\$XEPHYR_REQUIRED_LIBS\"") >&5
+ ($PKG_CONFIG --exists --print-errors "$XEPHYR_REQUIRED_LIBS") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ pkg_cv_XEPHYR_CFLAGS=`$PKG_CONFIG --cflags "$XEPHYR_REQUIRED_LIBS" 2>/dev/null`
+else
+ pkg_failed=yes
fi
- if test "x$XEPHYR" = xauto; then
- XEPHYR=$xephyr
fi
- if test "x$XEPHYR" = xyes && test "x$xephyr" = xno; then
- { { $as_echo "$as_me:$LINENO: error: Xephyr dependencies missing" >&5
-$as_echo "$as_me: error: Xephyr dependencies missing" >&2;}
+else
+ pkg_failed=untried
+fi
+if test -n "$PKG_CONFIG"; then
+ if test -n "$XEPHYR_LIBS"; then
+ pkg_cv_XEPHYR_LIBS="$XEPHYR_LIBS"
+ else
+ if test -n "$PKG_CONFIG" && \
+ { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"\$XEPHYR_REQUIRED_LIBS\"") >&5
+ ($PKG_CONFIG --exists --print-errors "$XEPHYR_REQUIRED_LIBS") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ pkg_cv_XEPHYR_LIBS=`$PKG_CONFIG --libs "$XEPHYR_REQUIRED_LIBS" 2>/dev/null`
+else
+ pkg_failed=yes
+fi
+ fi
+else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ XEPHYR_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "$XEPHYR_REQUIRED_LIBS"`
+ else
+ XEPHYR_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$XEPHYR_REQUIRED_LIBS"`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$XEPHYR_PKG_ERRORS" >&5
+
+ { { $as_echo "$as_me:$LINENO: error: Package requirements ($XEPHYR_REQUIRED_LIBS) were not met:
+
+$XEPHYR_PKG_ERRORS
+
+Consider adjusting the PKG_CONFIG_PATH environment variable if you
+installed software in a non-standard prefix.
+
+Alternatively, you may set the environment variables XEPHYR_CFLAGS
+and XEPHYR_LIBS to avoid the need to call pkg-config.
+See the pkg-config man page for more details.
+" >&5
+$as_echo "$as_me: error: Package requirements ($XEPHYR_REQUIRED_LIBS) were not met:
+
+$XEPHYR_PKG_ERRORS
+
+Consider adjusting the PKG_CONFIG_PATH environment variable if you
+installed software in a non-standard prefix.
+
+Alternatively, you may set the environment variables XEPHYR_CFLAGS
+and XEPHYR_LIBS to avoid the need to call pkg-config.
+See the pkg-config man page for more details.
+" >&2;}
+ { (exit 1); exit 1; }; }
+elif test $pkg_failed = untried; then
+ { { $as_echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it
+is in your PATH or set the PKG_CONFIG environment variable to the full
+path to pkg-config.
+
+Alternatively, you may set the environment variables XEPHYR_CFLAGS
+and XEPHYR_LIBS to avoid the need to call pkg-config.
+See the pkg-config man page for more details.
+
+To get pkg-config, see <http://www.freedesktop.org/software/pkgconfig>.
+See \`config.log' for more details." >&5
+$as_echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it
+is in your PATH or set the PKG_CONFIG environment variable to the full
+path to pkg-config.
+
+Alternatively, you may set the environment variables XEPHYR_CFLAGS
+and XEPHYR_LIBS to avoid the need to call pkg-config.
+See the pkg-config man page for more details.
+
+To get pkg-config, see <http://www.freedesktop.org/software/pkgconfig>.
+See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
+else
+ XEPHYR_CFLAGS=$pkg_cv_XEPHYR_CFLAGS
+ XEPHYR_LIBS=$pkg_cv_XEPHYR_LIBS
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+ :
+fi
fi
# Xephyr needs nanosleep() which is in librt on Solaris
@@ -34588,7 +34701,7 @@ exec 6>&1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by xorg-server $as_me 1.11.3, which was
+This file was extended by xorg-server $as_me 1.11.4, which was
generated by GNU Autoconf 2.62. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -34641,7 +34754,7 @@ Report bugs to <bug-autoconf@gnu.org>."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-xorg-server config.status 1.11.3
+xorg-server config.status 1.11.4
configured by $0, generated by GNU Autoconf 2.62,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff --git a/xserver/configure.ac b/xserver/configure.ac
index 3079f4999..a82812d9b 100644
--- a/xserver/configure.ac
+++ b/xserver/configure.ac
@@ -26,8 +26,8 @@ dnl
dnl Process this file with autoconf to create configure.
AC_PREREQ(2.57)
-AC_INIT([xorg-server], 1.11.3, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
-RELEASE_DATE="2011-12-16"
+AC_INIT([xorg-server], 1.11.4, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
+RELEASE_DATE="2012-01-27"
AC_CONFIG_SRCDIR([Makefile.am])
AM_INIT_AUTOMAKE([foreign dist-bzip2])
AM_MAINTAINER_MODE
@@ -1048,6 +1048,13 @@ if test "x$RES" = xyes && test "x$CLIENTIDS" = xyes; then
else
CLIENTIDS=no
fi
+if test "x$CLIENTIDS" = xyes; then
+ case $host_os in
+ openbsd*)
+ SYS_LIBS="$SYS_LIBS -lkvm"
+ ;;
+ esac
+fi
AC_MSG_RESULT([$CLIENTIDS])
AM_CONDITIONAL(CLIENTIDS, [test "x$CLIENTIDS" = xyes])
@@ -2097,12 +2104,10 @@ if test "$KDRIVE" = yes; then
XEPHYR_REQUIRED_LIBS="$XEPHYR_REQUIRED_LIBS $LIBGL libdrm"
fi
- PKG_CHECK_MODULES(XEPHYR, $XEPHYR_REQUIRED_LIBS, [xephyr="yes"], [xephyr="no"])
if test "x$XEPHYR" = xauto; then
- XEPHYR=$xephyr
- fi
- if test "x$XEPHYR" = xyes && test "x$xephyr" = xno; then
- AC_MSG_ERROR([Xephyr dependencies missing])
+ PKG_CHECK_MODULES(XEPHYR, $XEPHYR_REQUIRED_LIBS, [XEPHYR="yes"], [XEPHYR="no"])
+ elif test "x$XEPHYR" = xyes ; then
+ PKG_CHECK_MODULES(XEPHYR, $XEPHYR_REQUIRED_LIBS)
fi
# Xephyr needs nanosleep() which is in librt on Solaris
diff --git a/xserver/dix/dispatch.c b/xserver/dix/dispatch.c
index f8200b188..316384abc 100644
--- a/xserver/dix/dispatch.c
+++ b/xserver/dix/dispatch.c
@@ -337,8 +337,6 @@ DisableLimitedSchedulingLatency(void)
SmartScheduleLatencyLimited = 0;
}
-#define MAJOROP ((xReq *)client->requestBuffer)->reqType
-
void
Dispatch(void)
{
@@ -419,22 +417,33 @@ Dispatch(void)
}
client->sequence++;
+ client->majorOp = ((xReq *)client->requestBuffer)->reqType;
+ client->minorOp = 0;
+ if (client->majorOp >= EXTENSION_BASE) {
+ ExtensionEntry *ext = GetExtensionEntry(client->majorOp);
+ if (ext)
+ client->minorOp = ext->MinorOpcode(client);
+ }
#ifdef XSERVER_DTRACE
- XSERVER_REQUEST_START(LookupMajorName(MAJOROP), MAJOROP,
- ((xReq *)client->requestBuffer)->length,
- client->index, client->requestBuffer);
+ if (XSERVER_REQUEST_START_ENABLED())
+ XSERVER_REQUEST_START(LookupMajorName(client->majorOp),
+ client->majorOp,
+ ((xReq *)client->requestBuffer)->length,
+ client->index, client->requestBuffer);
#endif
if (result > (maxBigRequestSize << 2))
result = BadLength;
else {
- result = XaceHookDispatch(client, MAJOROP);
+ result = XaceHookDispatch(client, client->majorOp);
if (result == Success)
- result = (* client->requestVector[MAJOROP])(client);
+ result = (* client->requestVector[client->majorOp])(client);
XaceHookAuditEnd(client, result);
}
#ifdef XSERVER_DTRACE
- XSERVER_REQUEST_DONE(LookupMajorName(MAJOROP), MAJOROP,
- client->sequence, client->index, result);
+ if (XSERVER_REQUEST_DONE_ENABLED())
+ XSERVER_REQUEST_DONE(LookupMajorName(client->majorOp),
+ client->majorOp, client->sequence,
+ client->index, result);
#endif
if (client->noClientException != Success)
@@ -444,8 +453,8 @@ Dispatch(void)
}
else if (result != Success)
{
- SendErrorToClient(client, MAJOROP,
- MinorOpcodeOfRequest(client),
+ SendErrorToClient(client, client->majorOp,
+ client->minorOp,
client->errorValue, result);
break;
}
@@ -466,8 +475,6 @@ Dispatch(void)
SmartScheduleLatencyLimited = 0;
}
-#undef MAJOROP
-
static int VendorRelease = VENDOR_RELEASE;
static char *VendorString = VENDOR_NAME;
diff --git a/xserver/dix/dixutils.c b/xserver/dix/dixutils.c
index 1e3134663..cfb03974d 100644
--- a/xserver/dix/dixutils.c
+++ b/xserver/dix/dixutils.c
@@ -202,13 +202,12 @@ dixLookupDrawable(DrawablePtr *pDraw, XID id, ClientPtr client,
int rc;
*pDraw = NULL;
- client->errorValue = id;
-
- if (id == INVALID)
- return BadDrawable;
rc = dixLookupResourceByClass((pointer *)&pTmp, id, RC_DRAWABLE, client, access);
+ if (rc != Success)
+ client->errorValue = id;
+
if (rc == BadValue)
return BadDrawable;
if (rc != Success)
diff --git a/xserver/dix/events.c b/xserver/dix/events.c
index 8e7f9c324..7d2d0e3ee 100644
--- a/xserver/dix/events.c
+++ b/xserver/dix/events.c
@@ -1356,7 +1356,7 @@ ScreenRestructured (ScreenPtr pScreen)
for (pDev = inputInfo.devices; pDev; pDev = pDev->next)
{
- if (!DevHasCursor(pDev))
+ if (!IsFloating(pDev) && !DevHasCursor(pDev))
continue;
/* GrabDevice doesn't have a confineTo field, so we don't need to
diff --git a/xserver/dix/extension.c b/xserver/dix/extension.c
index 2db5695f3..d595b8057 100644
--- a/xserver/dix/extension.c
+++ b/xserver/dix/extension.c
@@ -230,20 +230,6 @@ StandardMinorOpcode(ClientPtr client)
return ((xReq *)client->requestBuffer)->data;
}
-unsigned short
-MinorOpcodeOfRequest(ClientPtr client)
-{
- unsigned char major;
-
- major = ((xReq *)client->requestBuffer)->reqType;
- if (major < EXTENSION_BASE)
- return 0;
- major -= EXTENSION_BASE;
- if (major >= NumExtensions)
- return 0;
- return (*extensions[major]->MinorOpcode)(client);
-}
-
void
CloseDownExtensions(void)
{
diff --git a/xserver/hw/dmx/examples/Makefile.am b/xserver/hw/dmx/examples/Makefile.am
index 229bb57fc..d055ddc71 100644
--- a/xserver/hw/dmx/examples/Makefile.am
+++ b/xserver/hw/dmx/examples/Makefile.am
@@ -10,60 +10,60 @@ bin_PROGRAMS = \
noinst_PROGRAMS = xinput xtest evi res xled xbell $(EV_PROG)
dmxinfo_SOURCES = dmxinfo.c
-dmxinfo_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxinfo_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxinfo_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxinfo_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxwininfo_SOURCES = dmxwininfo.c
-dmxwininfo_LDADD = @DMXXMUEXAMPLES_DEP_LIBS@
-dmxwininfo_CFLAGS = @DMXXMUEXAMPLES_DEP_CFLAGS@
+dmxwininfo_LDADD = $(DMXXMUEXAMPLES_DEP_LIBS)
+dmxwininfo_CFLAGS = $(DMXXMUEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxreconfig_SOURCES = dmxreconfig.c
-dmxreconfig_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxreconfig_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxreconfig_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxreconfig_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxresize_SOURCES = dmxresize.c
-dmxresize_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxresize_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxresize_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxresize_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxaddscreen_SOURCES = dmxaddscreen.c
-dmxaddscreen_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxaddscreen_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxaddscreen_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxaddscreen_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxrmscreen_SOURCES = dmxrmscreen.c
-dmxrmscreen_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxrmscreen_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxrmscreen_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxrmscreen_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxaddinput_SOURCES = dmxaddinput.c
-dmxaddinput_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxaddinput_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxaddinput_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxaddinput_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxrminput_SOURCES = dmxrminput.c
-dmxrminput_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxrminput_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxrminput_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxrminput_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
xinput_SOURCES = xinput.c
-xinput_LDADD = @DMXXIEXAMPLES_DEP_LIBS@
-xinput_CFLAGS = @DMXXIEXAMPLES_DEP_CFLAGS@
+xinput_LDADD = $(DMXXIEXAMPLES_DEP_LIBS)
+xinput_CFLAGS = $(DMXXIEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
xtest_SOURCES = xtest.c
-xtest_LDADD = @XTSTEXAMPLES_DEP_LIBS@
-xtest_CFLAGS = @XTSTEXAMPLES_DEP_CFLAGS@
+xtest_LDADD = $(XTSTEXAMPLES_DEP_LIBS)
+xtest_CFLAGS = $(XTSTEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
evi_SOURCES = evi.c
-evi_LDADD = @X11EXAMPLES_DEP_LIBS@
-evi_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@
+evi_LDADD = $(X11EXAMPLES_DEP_LIBS)
+evi_CFLAGS = $(X11EXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
res_SOURCES = res.c
-res_LDADD = @XRESEXAMPLES_DEP_LIBS@
-res_CFLAGS = @XRESEXAMPLES_DEP_CFLAGS@
+res_LDADD = $(XRESEXAMPLES_DEP_LIBS)
+res_CFLAGS = $(XRESEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
xled_SOURCES = xled.c
-xled_LDADD = @X11EXAMPLES_DEP_LIBS@
-xled_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@
+xled_LDADD = $(X11EXAMPLES_DEP_LIBS)
+xled_CFLAGS = $(X11EXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
xbell_SOURCES = xbell.c
-xbell_LDADD = @X11EXAMPLES_DEP_LIBS@
-xbell_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@
+xbell_LDADD = $(X11EXAMPLES_DEP_LIBS)
+xbell_CFLAGS = $(X11EXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
ev_SOURCES = ev.c
ev_LDADD =
diff --git a/xserver/hw/dmx/examples/Makefile.in b/xserver/hw/dmx/examples/Makefile.in
index 407f2da08..ecdfc0f44 100644
--- a/xserver/hw/dmx/examples/Makefile.in
+++ b/xserver/hw/dmx/examples/Makefile.in
@@ -67,49 +67,50 @@ binPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
PROGRAMS = $(bin_PROGRAMS) $(noinst_PROGRAMS)
am_dmxaddinput_OBJECTS = dmxaddinput-dmxaddinput.$(OBJEXT)
dmxaddinput_OBJECTS = $(am_dmxaddinput_OBJECTS)
-dmxaddinput_DEPENDENCIES =
+am__DEPENDENCIES_1 =
+dmxaddinput_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_dmxaddscreen_OBJECTS = dmxaddscreen-dmxaddscreen.$(OBJEXT)
dmxaddscreen_OBJECTS = $(am_dmxaddscreen_OBJECTS)
-dmxaddscreen_DEPENDENCIES =
+dmxaddscreen_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_dmxinfo_OBJECTS = dmxinfo-dmxinfo.$(OBJEXT)
dmxinfo_OBJECTS = $(am_dmxinfo_OBJECTS)
-dmxinfo_DEPENDENCIES =
+dmxinfo_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_dmxreconfig_OBJECTS = dmxreconfig-dmxreconfig.$(OBJEXT)
dmxreconfig_OBJECTS = $(am_dmxreconfig_OBJECTS)
-dmxreconfig_DEPENDENCIES =
+dmxreconfig_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_dmxresize_OBJECTS = dmxresize-dmxresize.$(OBJEXT)
dmxresize_OBJECTS = $(am_dmxresize_OBJECTS)
-dmxresize_DEPENDENCIES =
+dmxresize_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_dmxrminput_OBJECTS = dmxrminput-dmxrminput.$(OBJEXT)
dmxrminput_OBJECTS = $(am_dmxrminput_OBJECTS)
-dmxrminput_DEPENDENCIES =
+dmxrminput_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_dmxrmscreen_OBJECTS = dmxrmscreen-dmxrmscreen.$(OBJEXT)
dmxrmscreen_OBJECTS = $(am_dmxrmscreen_OBJECTS)
-dmxrmscreen_DEPENDENCIES =
+dmxrmscreen_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_dmxwininfo_OBJECTS = dmxwininfo-dmxwininfo.$(OBJEXT)
dmxwininfo_OBJECTS = $(am_dmxwininfo_OBJECTS)
-dmxwininfo_DEPENDENCIES =
+dmxwininfo_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_ev_OBJECTS = ev-ev.$(OBJEXT)
ev_OBJECTS = $(am_ev_OBJECTS)
ev_DEPENDENCIES =
am_evi_OBJECTS = evi-evi.$(OBJEXT)
evi_OBJECTS = $(am_evi_OBJECTS)
-evi_DEPENDENCIES =
+evi_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_res_OBJECTS = res-res.$(OBJEXT)
res_OBJECTS = $(am_res_OBJECTS)
-res_DEPENDENCIES =
+res_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_xbell_OBJECTS = xbell-xbell.$(OBJEXT)
xbell_OBJECTS = $(am_xbell_OBJECTS)
-xbell_DEPENDENCIES =
+xbell_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_xinput_OBJECTS = xinput-xinput.$(OBJEXT)
xinput_OBJECTS = $(am_xinput_OBJECTS)
-xinput_DEPENDENCIES =
+xinput_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_xled_OBJECTS = xled-xled.$(OBJEXT)
xled_OBJECTS = $(am_xled_OBJECTS)
-xled_DEPENDENCIES =
+xled_DEPENDENCIES = $(am__DEPENDENCIES_1)
am_xtest_OBJECTS = xtest-xtest.$(OBJEXT)
xtest_OBJECTS = $(am_xtest_OBJECTS)
-xtest_DEPENDENCIES =
+xtest_DEPENDENCIES = $(am__DEPENDENCIES_1)
DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)/include -I$(top_builddir)/include -I$(top_builddir)/include -I$(top_builddir)/include -I$(top_builddir)/include -I$(top_builddir)/include -I$(top_builddir)/include -I$(top_builddir)/include
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
@@ -676,47 +677,47 @@ target_alias = @target_alias@
# Requires <linux/input.h>
@DMX_BUILD_USB_TRUE@EV_PROG = ev
dmxinfo_SOURCES = dmxinfo.c
-dmxinfo_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxinfo_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxinfo_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxinfo_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxwininfo_SOURCES = dmxwininfo.c
-dmxwininfo_LDADD = @DMXXMUEXAMPLES_DEP_LIBS@
-dmxwininfo_CFLAGS = @DMXXMUEXAMPLES_DEP_CFLAGS@
+dmxwininfo_LDADD = $(DMXXMUEXAMPLES_DEP_LIBS)
+dmxwininfo_CFLAGS = $(DMXXMUEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxreconfig_SOURCES = dmxreconfig.c
-dmxreconfig_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxreconfig_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxreconfig_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxreconfig_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxresize_SOURCES = dmxresize.c
-dmxresize_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxresize_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxresize_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxresize_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxaddscreen_SOURCES = dmxaddscreen.c
-dmxaddscreen_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxaddscreen_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxaddscreen_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxaddscreen_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxrmscreen_SOURCES = dmxrmscreen.c
-dmxrmscreen_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxrmscreen_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxrmscreen_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxrmscreen_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxaddinput_SOURCES = dmxaddinput.c
-dmxaddinput_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxaddinput_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxaddinput_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxaddinput_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
dmxrminput_SOURCES = dmxrminput.c
-dmxrminput_LDADD = @DMXEXAMPLES_DEP_LIBS@
-dmxrminput_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@
+dmxrminput_LDADD = $(DMXEXAMPLES_DEP_LIBS)
+dmxrminput_CFLAGS = $(DMXEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
xinput_SOURCES = xinput.c
-xinput_LDADD = @DMXXIEXAMPLES_DEP_LIBS@
-xinput_CFLAGS = @DMXXIEXAMPLES_DEP_CFLAGS@
+xinput_LDADD = $(DMXXIEXAMPLES_DEP_LIBS)
+xinput_CFLAGS = $(DMXXIEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
xtest_SOURCES = xtest.c
-xtest_LDADD = @XTSTEXAMPLES_DEP_LIBS@
-xtest_CFLAGS = @XTSTEXAMPLES_DEP_CFLAGS@
+xtest_LDADD = $(XTSTEXAMPLES_DEP_LIBS)
+xtest_CFLAGS = $(XTSTEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
evi_SOURCES = evi.c
-evi_LDADD = @X11EXAMPLES_DEP_LIBS@
-evi_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@
+evi_LDADD = $(X11EXAMPLES_DEP_LIBS)
+evi_CFLAGS = $(X11EXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
res_SOURCES = res.c
-res_LDADD = @XRESEXAMPLES_DEP_LIBS@
-res_CFLAGS = @XRESEXAMPLES_DEP_CFLAGS@
+res_LDADD = $(XRESEXAMPLES_DEP_LIBS)
+res_CFLAGS = $(XRESEXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
xled_SOURCES = xled.c
-xled_LDADD = @X11EXAMPLES_DEP_LIBS@
-xled_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@
+xled_LDADD = $(X11EXAMPLES_DEP_LIBS)
+xled_CFLAGS = $(X11EXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
xbell_SOURCES = xbell.c
-xbell_LDADD = @X11EXAMPLES_DEP_LIBS@
-xbell_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@
+xbell_LDADD = $(X11EXAMPLES_DEP_LIBS)
+xbell_CFLAGS = $(X11EXAMPLES_DEP_CFLAGS) $(CWARNFLAGS)
ev_SOURCES = ev.c
ev_LDADD =
ev_CFLAGS =
diff --git a/xserver/hw/kdrive/linux/keyboard.c b/xserver/hw/kdrive/linux/keyboard.c
index f5f9d9b8a..ba2637b58 100644
--- a/xserver/hw/kdrive/linux/keyboard.c
+++ b/xserver/hw/kdrive/linux/keyboard.c
@@ -692,7 +692,7 @@ LinuxKeyboardEnable (KdKeyboardInfo *ki)
return !Success;
fd = LinuxConsoleFd;
- ki->driverPrivate = (void *) fd;
+ ki->driverPrivate = (void *) (intptr_t) fd;
ioctl (fd, KDGKBMODE, &LinuxKbdTrans);
tcgetattr (fd, &LinuxTermios);
@@ -724,7 +724,7 @@ LinuxKeyboardDisable (KdKeyboardInfo *ki)
if (!ki)
return;
- fd = (int) ki->driverPrivate;
+ fd = (int) (intptr_t) ki->driverPrivate;
KdUnregisterFd(ki, fd, FALSE);
ioctl(fd, KDSKBMODE, LinuxKbdTrans);
@@ -753,7 +753,7 @@ LinuxKeyboardLeds (KdKeyboardInfo *ki, int leds)
if (!ki)
return;
- ioctl ((int)ki->driverPrivate, KDSETLED, leds & 7);
+ ioctl ((int)(intptr_t)ki->driverPrivate, KDSETLED, leds & 7);
}
KdKeyboardDriver LinuxKeyboardDriver = {
diff --git a/xserver/hw/kdrive/linux/ms.c b/xserver/hw/kdrive/linux/ms.c
index b6151cd90..176e12550 100644
--- a/xserver/hw/kdrive/linux/ms.c
+++ b/xserver/hw/kdrive/linux/ms.c
@@ -152,7 +152,7 @@ MsEnable (KdPointerInfo *pi)
}
if (KdRegisterFd (port, MsRead, pi))
return TRUE;
- pi->driverPrivate = (void *)port;
+ pi->driverPrivate = (void *)(intptr_t)port;
return Success;
@@ -164,7 +164,7 @@ MsEnable (KdPointerInfo *pi)
static void
MsDisable (KdPointerInfo *pi)
{
- KdUnregisterFd (pi, (int)pi->driverPrivate, TRUE);
+ KdUnregisterFd (pi, (int)(intptr_t)pi->driverPrivate, TRUE);
}
static void
diff --git a/xserver/hw/kdrive/linux/ps2.c b/xserver/hw/kdrive/linux/ps2.c
index 465b963f2..b62d769f2 100644
--- a/xserver/hw/kdrive/linux/ps2.c
+++ b/xserver/hw/kdrive/linux/ps2.c
@@ -159,7 +159,7 @@ Ps2Enable (KdPointerInfo *pi)
return BadAlloc;
}
- pi->driverPrivate = (void *)fd;
+ pi->driverPrivate = (void *)(intptr_t)fd;
return Success;
}
@@ -168,7 +168,7 @@ Ps2Enable (KdPointerInfo *pi)
static void
Ps2Disable (KdPointerInfo *pi)
{
- KdUnregisterFd (pi, (int)pi->driverPrivate, TRUE);
+ KdUnregisterFd (pi, (int)(intptr_t)pi->driverPrivate, TRUE);
}
static void
diff --git a/xserver/hw/xfree86/common/xf86Xinput.c b/xserver/hw/xfree86/common/xf86Xinput.c
index ba7f85da2..5d20c32a0 100644
--- a/xserver/hw/xfree86/common/xf86Xinput.c
+++ b/xserver/hw/xfree86/common/xf86Xinput.c
@@ -940,15 +940,16 @@ NewInputDeviceRequest (InputOption *options, InputAttributes *attrs,
pInfo->attrs = DuplicateInputAttributes(attrs);
}
- if (!pInfo->driver || !pInfo->name) {
- xf86Msg(X_INFO, "No input driver/identifier specified (ignoring)\n");
+ if (!pInfo->name) {
+ xf86Msg(X_INFO, "No identifier specified, ignoring this device.\n");
rval = BadRequest;
goto unwind;
}
- if (!pInfo->name) {
- xf86Msg(X_ERROR, "No device identifier specified (ignoring)\n");
- rval = BadMatch;
+ if (!pInfo->driver) {
+ xf86Msg(X_INFO, "No input driver specified, ignoring this device.\n");
+ xf86Msg(X_INFO, "This device may have been added with another device file.\n");
+ rval = BadRequest;
goto unwind;
}
diff --git a/xserver/hw/xquartz/bundle/Info.plist.cpp b/xserver/hw/xquartz/bundle/Info.plist.cpp
index a4b8e1926..60251f76a 100644
--- a/xserver/hw/xquartz/bundle/Info.plist.cpp
+++ b/xserver/hw/xquartz/bundle/Info.plist.cpp
@@ -19,9 +19,9 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
- <string>2.7.0</string>
+ <string>2.7.1</string>
<key>CFBundleVersion</key>
- <string>2.7.0</string>
+ <string>2.7.1</string>
<key>CFBundleSignature</key>
<string>x11a</string>
<key>CSResourcesFileMapped</key>
@@ -37,9 +37,9 @@
<key>LSApplicationCategoryType</key>
<string>public.app-category.utilities</string>
<key>NSHumanReadableCopyright</key>
- <string>© 2003-2011 Apple Inc.
+ <string>© 2003-2012 Apple Inc.
© 2003 XFree86 Project, Inc.
-© 2003-2011 X.org Foundation, Inc.
+© 2003-2012 X.org Foundation, Inc.
</string>
<key>NSMainNibFile</key>
<string>main</string>
diff --git a/xserver/include/dixstruct.h b/xserver/include/dixstruct.h
index 443e8b0ae..94eb526c5 100644
--- a/xserver/include/dixstruct.h
+++ b/xserver/include/dixstruct.h
@@ -123,6 +123,7 @@ typedef struct _Client {
DeviceIntPtr clientPtr;
ClientIdPtr clientIds;
+ unsigned short majorOp, minorOp;
} ClientRec;
/*
diff --git a/xserver/include/extension.h b/xserver/include/extension.h
index 29a11c300..9249951a8 100644
--- a/xserver/include/extension.h
+++ b/xserver/include/extension.h
@@ -52,8 +52,6 @@ _XFUNCPROTOBEGIN
extern _X_EXPORT unsigned short StandardMinorOpcode(ClientPtr /*client*/);
-extern _X_EXPORT unsigned short MinorOpcodeOfRequest(ClientPtr /*client*/);
-
extern _X_EXPORT Bool EnableDisableExtension(char *name, Bool enable);
extern _X_EXPORT void EnableDisableExtensionError(char *name, Bool enable);
diff --git a/xserver/mi/mibitblt.c b/xserver/mi/mibitblt.c
index 49e17bde6..6e0055758 100644
--- a/xserver/mi/mibitblt.c
+++ b/xserver/mi/mibitblt.c
@@ -648,7 +648,7 @@ miGetImage( DrawablePtr pDraw, int sx, int sy, int w, int h,
depth = pDraw->depth;
if(format == ZPixmap)
{
- if ( (((1<<depth)-1)&planeMask) != (1<<depth)-1 )
+ if ( (((1LL<<depth)-1)&planeMask) != (1LL<<depth)-1 )
{
ChangeGCVal gcv;
xPoint pt;
diff --git a/xserver/os/backtrace.c b/xserver/os/backtrace.c
index 7ca6dab6d..f3255c738 100644
--- a/xserver/os/backtrace.c
+++ b/xserver/os/backtrace.c
@@ -44,7 +44,11 @@ void xorg_backtrace(void)
ErrorF("\nBacktrace:\n");
size = backtrace(array, 64);
for (i = 0; i < size; i++) {
- dladdr(array[i], &info);
+ int rc = dladdr(array[i], &info);
+ if (rc == 0) {
+ ErrorF("%d: ?? [%p]\n", i, array[i]);
+ continue;
+ }
mod = (info.dli_fname && *info.dli_fname) ? info.dli_fname : "(vdso)";
if (info.dli_saddr)
ErrorF("%d: %s (%s+0x%lx) [%p]\n", i, mod,
diff --git a/xserver/os/client.c b/xserver/os/client.c
index b5349778b..fbccf22ed 100644
--- a/xserver/os/client.c
+++ b/xserver/os/client.c
@@ -59,6 +59,20 @@
#include "os.h"
#include "dixstruct.h"
+#ifdef __sun
+#include <errno.h>
+#include <procfs.h>
+#endif
+
+#ifdef __OpenBSD__
+#include <sys/param.h>
+#include <sys/sysctl.h>
+#include <sys/types.h>
+
+#include <kvm.h>
+#include <limits.h>
+#endif
+
/**
* Try to determine a PID for a client from its connection
* information. This should be called only once when new client has
@@ -117,8 +131,6 @@ void DetermineClientCmd(pid_t pid, const char **cmdname, const char **cmdargs)
{
char path[PATH_MAX + 1];
int totsize = 0;
- int cmdsize = 0;
- int argsize = 0;
int fd = 0;
if (cmdname)
@@ -129,6 +141,80 @@ void DetermineClientCmd(pid_t pid, const char **cmdname, const char **cmdargs)
if (pid == -1)
return;
+#ifdef __sun /* Solaris */
+ /* Solaris does not support /proc/pid/cmdline, but makes information
+ * similar to what ps shows available in a binary structure in the
+ * /proc/pid/psinfo file. */
+ if (snprintf(path, sizeof(path), "/proc/%d/psinfo", pid) < 0)
+ return;
+ fd = open(path, O_RDONLY);
+ if (fd < 0)
+ {
+ ErrorF ("Failed to open %s: %s\n", path, strerror(errno));
+ return;
+ }
+ else
+ {
+ psinfo_t psinfo = { 0 };
+ char *sp;
+
+ totsize = read(fd, &psinfo, sizeof(psinfo_t));
+ close(fd);
+ if (totsize <= 0)
+ return;
+
+ /* pr_psargs is the first PRARGSZ (80) characters of the command
+ * line string - assume up to the first space is the command name,
+ * since it's not delimited. While there is also pr_fname, that's
+ * more limited, giving only the first 16 chars of the basename of
+ * the file that was exec'ed, thus cutting off many long gnome
+ * command names, or returning "isapython2.6" for all python scripts.
+ */
+ psinfo.pr_psargs[PRARGSZ-1] = '\0';
+ sp = strchr(psinfo.pr_psargs, ' ');
+ if (sp)
+ *sp++ = '\0';
+
+ if (cmdname)
+ *cmdname = strdup(psinfo.pr_psargs);
+
+ if (cmdargs && sp)
+ *cmdargs = strdup(sp);
+ }
+#elif defined(__OpenBSD__)
+ /* on OpenBSD use kvm_getargv() */
+ {
+ kvm_t *kd;
+ char errbuf[_POSIX2_LINE_MAX];
+ char **argv;
+ struct kinfo_proc *kp;
+ size_t len = 0;
+ int i, n;
+
+ kd = kvm_open(NULL, NULL, NULL, KVM_NO_FILES, errbuf);
+ if (kd == NULL)
+ return;
+ kp = kvm_getprocs(kd, KERN_PROC_PID, pid, sizeof(struct kinfo_proc), &n);
+ if (n != 1)
+ return;
+ argv = kvm_getargv(kd, kp, 0);
+ *cmdname = strdup(argv[0]);
+ i = 1;
+ while (argv[i] != NULL) {
+ len += strlen(argv[i]) + 1;
+ i++;
+ }
+ *cmdargs = calloc(1, len);
+ i = 1;
+ while (argv[i] != NULL) {
+ strlcat(*cmdargs, argv[i], len);
+ strlcat(*cmdargs, " ", len);
+ i++;
+ }
+ kvm_close(kd);
+ }
+#else /* Linux using /proc/pid/cmdline */
+
/* Check if /proc/pid/cmdline exists. It's not supported on all
* operating systems. */
if (snprintf(path, sizeof(path), "/proc/%d/cmdline", pid) < 0)
@@ -146,23 +232,20 @@ void DetermineClientCmd(pid_t pid, const char **cmdname, const char **cmdargs)
path[totsize - 1] = '\0';
/* Contruct the process name without arguments. */
- cmdsize = strlen(path) + 1;
if (cmdname)
{
- char *name = malloc(cmdsize);
- if (name)
- {
- strncpy(name, path, cmdsize);
- name[cmdsize - 1] = '\0';
- *cmdname = name;
- }
+ *cmdname = strdup(path);
}
/* Construct the arguments for client process. */
- argsize = totsize - cmdsize;
- if (cmdargs && (argsize > 0))
+ if (cmdargs)
{
- char *args = malloc(argsize);
+ int cmdsize = strlen(path) + 1;
+ int argsize = totsize - cmdsize;
+ char *args = NULL;
+
+ if (argsize > 0)
+ args = malloc(argsize);
if (args)
{
int i = 0;
@@ -175,6 +258,7 @@ void DetermineClientCmd(pid_t pid, const char **cmdname, const char **cmdargs)
*cmdargs = args;
}
}
+#endif
}
/**
@@ -198,9 +282,9 @@ void ReserveClientIds(struct _Client *client)
DetermineClientCmd(client->clientIds->pid, &client->clientIds->cmdname, &client->clientIds->cmdargs);
DebugF("client(%lx): Reserved pid(%d).\n",
- client->clientAsMask, client->clientIds->pid);
+ (unsigned long) client->clientAsMask, client->clientIds->pid);
DebugF("client(%lx): Reserved cmdname(%s) and cmdargs(%s).\n",
- client->clientAsMask,
+ (unsigned long) client->clientAsMask,
client->clientIds->cmdname ? client->clientIds->cmdname : "NULL",
client->clientIds->cmdargs ? client->clientIds->cmdargs : "NULL");
#endif /* CLIENTIDS */
@@ -222,9 +306,9 @@ void ReleaseClientIds(struct _Client *client)
return;
DebugF("client(%lx): Released pid(%d).\n",
- client->clientAsMask, client->clientIds->pid);
+ (unsigned long) client->clientAsMask, client->clientIds->pid);
DebugF("client(%lx): Released cmdline(%s) and cmdargs(%s).\n",
- client->clientAsMask,
+ (unsigned long) client->clientAsMask,
client->clientIds->cmdname ? client->clientIds->cmdname : "NULL",
client->clientIds->cmdargs ? client->clientIds->cmdargs : "NULL");
diff --git a/xserver/record/record.c b/xserver/record/record.c
index 93383cee4..778849a6e 100644
--- a/xserver/record/record.c
+++ b/xserver/record/record.c
@@ -554,7 +554,7 @@ RecordARequest(ClientPtr client)
}
else /* extension, check minor opcode */
{
- int minorop = MinorOpcodeOfRequest(client);
+ int minorop = client->minorOp;
int numMinOpInfo;
RecordMinorOpPtr pMinorOpInfo = pRCAP->pRequestMinOpInfo;
@@ -611,12 +611,9 @@ RecordAReply(CallbackListPtr *pcbl, pointer nulldata, pointer calldata)
RecordContextPtr pContext;
RecordClientsAndProtocolPtr pRCAP;
int eci;
- int majorop;
ReplyInfoRec *pri = (ReplyInfoRec *)calldata;
ClientPtr client = pri->client;
- REQUEST(xReq);
- majorop = stuff->reqType;
for (eci = 0; eci < numEnabledContexts; eci++)
{
pContext = ppAllContexts[eci];
@@ -624,6 +621,7 @@ RecordAReply(CallbackListPtr *pcbl, pointer nulldata, pointer calldata)
NULL);
if (pRCAP)
{
+ int majorop = client->majorOp;
if (pContext->continuedReply)
{
RecordAProtocolElement(pContext, client, XRecordFromServer,
@@ -644,7 +642,7 @@ RecordAReply(CallbackListPtr *pcbl, pointer nulldata, pointer calldata)
}
else /* extension, check minor opcode */
{
- int minorop = MinorOpcodeOfRequest(client);
+ int minorop = client->minorOp;
int numMinOpInfo;
RecordMinorOpPtr pMinorOpInfo = pRCAP->pReplyMinOpInfo;
assert (pMinorOpInfo);
diff --git a/xserver/render/animcur.c b/xserver/render/animcur.c
index 31cbab9a6..8d4a9c2ef 100644
--- a/xserver/render/animcur.c
+++ b/xserver/render/animcur.c
@@ -208,6 +208,9 @@ AnimCurDisplayCursor (DeviceIntPtr pDev,
AnimCurScreenPtr as = GetAnimCurScreen(pScreen);
Bool ret;
+ if (IsFloating(pDev))
+ return FALSE;
+
Unwrap (as, pScreen, DisplayCursor);
if (IsAnimCur(pCursor))
{
diff --git a/xserver/xfixes/cursor.c b/xserver/xfixes/cursor.c
index ecbed4016..7b01c8b52 100644
--- a/xserver/xfixes/cursor.c
+++ b/xserver/xfixes/cursor.c
@@ -179,9 +179,9 @@ CursorDisplayCursor (DeviceIntPtr pDev,
ev.type = XFixesEventBase + XFixesCursorNotify;
ev.subtype = XFixesDisplayCursorNotify;
ev.window = e->pWindow->drawable.id;
- ev.cursorSerial = pCursor->serialNumber;
+ ev.cursorSerial = pCursor ? pCursor->serialNumber : 0;
ev.timestamp = currentTime.milliseconds;
- ev.name = pCursor->name;
+ ev.name = pCursor ? pCursor->name : None;
WriteEventsToClient (e->pClient, 1, (xEvent *) &ev);
}
}