Compare commits

...
Sign in to create a new pull request.

2 commits

Author SHA1 Message Date
Peter Hutterer
8d7be798e0 Add XF86TouchpadOn/Off to KeysymDB (#683950) 2011-03-22 11:41:17 +10:00
Bill Nottingham
90208249e6 Add upstream patch to fix use-after-free that makes clients crash. 2010-08-10 11:16:47 -04:00
3 changed files with 73 additions and 1 deletions

View file

@ -0,0 +1,29 @@
From f5b6c3f955ea7b65d2506a3c4a7111166f003704 Mon Sep 17 00:00:00 2001
From: Peter Hutterer <peter.hutterer@who-t.net>
Date: Tue, 22 Mar 2011 11:28:56 +1000
Subject: [PATCH] Add XF86TouchpadOn and XF86TouchpadOff to keysymdb
This patch isn't necessary in Xlib 1.4 and later since the keysymdb has been
made redunant. While we're on 1.3.x, we need it.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
---
src/XKeysymDB | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/src/XKeysymDB b/src/XKeysymDB
index 45d8929..28718b4 100644
--- a/src/XKeysymDB
+++ b/src/XKeysymDB
@@ -352,6 +352,8 @@ XF86Blue :1008FFA6
XF86Suspend :1008FFA7
XF86Hibernate :1008FFA8
XF86TouchpadToggle :1008FFA9
+XF86TouchpadOn :1008FFB0
+XF86TouchpadOff :1008FFB1
! XFree86 special action keys
XF86_Switch_VT_1 :1008FE01
--
1.7.4

View file

@ -0,0 +1,33 @@
From 54a963608d23d35cd9233b2223f880ac3671f10b Mon Sep 17 00:00:00 2001
From: Jamey Sharp <jamey@minilop.net>
Date: Fri, 06 Aug 2010 22:51:56 +0000
Subject: Fix use-after-free in _XReply on X errors.
_XReply would always call dequeue_pending_request on errors. When it
got an error for the current request, it would call dequeue, then break
out of the loop; then, if it had an error in the event queue, it would
compare it with the sequence number of the now-freed pending request.
_XReply already stored that sequence number in dpy->last_request_read
before freeing it, so look at that instead.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=29412
Signed-off-by: Jamey Sharp <jamey@minilop.net>
Signed-off-by: Josh Triplett <josh@joshtriplett.org>
(cherry picked from commit 4b8ff7db39f2fe7ef12968d462aaf3f9054b6c18)
---
diff --git a/src/xcb_io.c b/src/xcb_io.c
index dac7622..72881d8 100644
--- a/src/xcb_io.c
+++ b/src/xcb_io.c
@@ -579,7 +579,7 @@ Status _XReply(Display *dpy, xReply *rep, int extra, Bool discard)
xcb_generic_event_t *event = dpy->xcb->next_event;
unsigned long event_sequence = dpy->last_request_read;
widen(&event_sequence, event->full_sequence);
- if(event_sequence == current->sequence)
+ if(event_sequence == dpy->last_request_read)
{
error = (xcb_generic_error_t *) event;
dpy->xcb->next_event = NULL;
--
cgit v0.8.3-6-g21f6

View file

@ -4,7 +4,7 @@
Summary: Core X11 protocol client library
Name: libX11
Version: 1.3.4
Release: 2%{?dist}
Release: 4%{?dist}
License: MIT
Group: System Environment/Libraries
URL: http://www.x.org
@ -16,6 +16,8 @@ Source0: http://xorg.freedesktop.org/archive/individual/lib/%{name}-%{version}.t
#Source1: make-git-snapshot.sh
Patch2: dont-forward-keycode-0.patch
Patch3: 54a963608d23d35cd9233b2223f880ac3671f10b.patch
Patch4: 0001-Add-XF86TouchpadOn-and-XF86TouchpadOff-to-keysymdb.patch
BuildRequires: xorg-x11-util-macros
BuildRequires: pkgconfig(xproto) >= 7.0.15
@ -48,6 +50,8 @@ X.Org X11 libX11 development package
%setup -q
#setup -q -n %{tarball}-%{gitdate}
%patch2 -p1 -b .dont-forward-keycode-0
%patch3 -p1
%patch4 -p1
%build
# sodding libtool
@ -114,6 +118,12 @@ rm -rf $RPM_BUILD_ROOT
%{_mandir}/man5/*.5*
%changelog
* Tue Mar 22 2011 Peter Hutterer <peter.hutterer@redhat.com> 1.3.4-4
- Add XF86TouchpadOn/Off to KeysymDB (#683950)
* Tue Aug 10 2010 Bill Nottingham <notting@redhat.com> - 1.3.4-3
- Merge upstream commit 54a96360, fixes use-after-free (fd.o 29412)
* Mon Jul 19 2010 Matěj Cepl <mcepl@redhat.com> - 1.3.4-2
- don't own /usr/share/X11, filesystem owns it already (#569395)