commit ec591534c2129df740b730eda699f2e8ca52e7d4 Author: Marcin Krol <h...@tld-linux.org> Date: Sat Apr 14 13:48:35 2018 +0000
- dropped python patch, not needed - added better git fixes in place of xcbproto-1.9 patch git.patch | 73 +++++++++++++++++++++++++++++++++++++++++++ python-xpyb.spec | 6 ++-- xpyb-1.3.1-xcbproto-1.9.patch | 11 ------- xpyb-python.patch | 12 ------- 4 files changed, 75 insertions(+), 27 deletions(-) --- diff --git a/python-xpyb.spec b/python-xpyb.spec index 293e841..710ef7c 100644 --- a/python-xpyb.spec +++ b/python-xpyb.spec @@ -8,9 +8,8 @@ Group: Development/Languages/Python Source0: http://xcb.freedesktop.org/dist/xpyb-%{version}.tar.bz2 # Source0-md5: b9b70746cd348836516edcba96d24677 Patch0: %{name}-dir.patch -Patch1: xpyb-python.patch -Patch2: xpyb-1.3.1-xcbproto-1.9.patch -Patch3: xpyb-1.3.1-xcbproto-1.13.patch +Patch1: git.patch +Patch2: xpyb-1.3.1-xcbproto-1.13.patch URL: http://xcb.freedesktop.org/ BuildRequires: autoconf >= 2.57 BuildRequires: automake @@ -51,7 +50,6 @@ Pliki programistyczne pakietu X Python Binding. %patch0 -p1 %patch1 -p1 %patch2 -p1 -%patch3 -p1 %build %{__libtoolize} diff --git a/git.patch b/git.patch new file mode 100644 index 0000000..fbe91fc --- /dev/null +++ b/git.patch @@ -0,0 +1,73 @@ +From ed0147e182cc739ae77c34675080e14d498492b2 Mon Sep 17 00:00:00 2001 +From: Alan Coopersmith <alan.coopersm...@oracle.com> +Date: Sun, 18 Aug 2013 16:44:31 -0700 +Subject: xpybConn_call should ensure ext is not NULL before using it + +Found by Oracle's Parfait 1.2 static analyzer: + Null pointer dereference (CWE 476): Read from null pointer ext + at line 322 of /export/alanc/X.Org/amd64-parfait/xcb/xpyb/src/conn.c + in function 'xpybConn_call'. + Function xpybConn_load_ext may return constant 'NULL' at line 141, + called at line 321. + Null pointer introduced at line 141 in function 'xpybConn_load_ext'. + +Signed-off-by: Alan Coopersmith <alan.coopersm...@oracle.com> +--- + src/conn.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/conn.c b/src/conn.c +index 39833c8..1b21d17 100644 +--- a/src/conn.c ++++ b/src/conn.c +@@ -319,7 +319,7 @@ xpybConn_call(xpybConn *self, PyObject *args, PyObject *kw) + + /* Check our dictionary of cached values */ + ext = xpybConn_load_ext(self, key); +- if (!ext->present) { ++ if (ext != NULL && !ext->present) { + PyErr_SetString(xpybExcept_ext, "Extension not present on server."); + Py_DECREF(ext); + return NULL; +-- +cgit v1.1 + +From 56d56615db00445679fde3742fc72c793a982d2e Mon Sep 17 00:00:00 2001 +From: Matt Turner <matts...@gmail.com> +Date: Sat, 4 Mar 2017 11:33:12 -0800 +Subject: Add CARD64/INT64 protocol types + +The following commit to xcb/proto, included in the 1.9 release, added CARD64 +and INT64 types. + + commit 4d8241c67c83957aa0f612da6823db2d18fdd314 + Author: Keith Packard <kei...@keithp.com> + Date: Thu Jul 11 15:56:54 2013 -0700 + + Add CARD64/INT64 protocol types + +Signed-off-by: Matt Turner <matts...@gmail.com> +Signed-off-by: Uli Schlachter <psyc...@znc.in> +--- + src/py_client.py | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/src/py_client.py b/src/py_client.py +index 5c83e46..113abd5 100755 +--- a/src/py_client.py ++++ b/src/py_client.py +@@ -16,9 +16,11 @@ _py_reserved_words = [ 'None', 'def', 'class', 'and', 'or' ] + _cardinal_types = {'CARD8': 'B', 'uint8_t': 'B', + 'CARD16': 'H','uint16_t': 'H', + 'CARD32': 'I','uint32_t': 'I', ++ 'CARD64': 'L','uint64_t': 'L', + 'INT8': 'b', 'int8_t': 'b', + 'INT16': 'h', 'int16_t': 'h', + 'INT32': 'i', 'int32_t': 'i', ++ 'INT64': 'l', 'int64_t': 'l', + 'BYTE': 'B', + 'BOOL': 'B', + 'char': 'b', +-- +cgit v1.1 + diff --git a/xpyb-1.3.1-xcbproto-1.9.patch b/xpyb-1.3.1-xcbproto-1.9.patch deleted file mode 100644 index 1196741..0000000 --- a/xpyb-1.3.1-xcbproto-1.9.patch +++ /dev/null @@ -1,11 +0,0 @@ -diff -ruN xpyb-1.3.1_ORIG/src/py_client.py xpyb-1.3.1/src/py_client.py ---- xpyb-1.3.1_ORIG/src/py_client.py 2013-11-17 12:57:05.157530931 +0100 -+++ xpyb-1.3.1/src/py_client.py 2013-11-17 12:57:52.221530100 +0100 -@@ -19,6 +19,7 @@ - 'INT8': 'b', 'int8_t': 'b', - 'INT16': 'h', 'int16_t': 'h', - 'INT32': 'i', 'int32_t': 'i', -+ 'INT64': 'i', 'int64_t': 'i', - 'BYTE': 'B', - 'BOOL': 'B', - 'char': 'b', diff --git a/xpyb-python.patch b/xpyb-python.patch deleted file mode 100644 index 4d5d9ac..0000000 --- a/xpyb-python.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- xpyb-1.3.1/configure.ac.orig 2013-05-21 19:01:51.054962821 +0400 -+++ xpyb-1.3.1/configure.ac 2013-05-21 19:05:22.342961464 +0400 -@@ -38,7 +38,8 @@ - - # Find the xcbgen Python package - AC_MSG_CHECKING([for xcb-proto python dir]) --XCBPROTO_XCBPYTHONDIR=`$PKG_CONFIG --variable=pythondir xcb-proto` -+XCBPROTO_XCBPYTHONDIR=`$PYTHON -c 'import xcbgen; from os.path import dirname, abspath, join; \ -+ print abspath(join(dirname(xcbgen.[__file__]), ".."))'` - AC_MSG_RESULT($XCBPROTO_XCBPYTHONDIR) - AC_SUBST(XCBPROTO_XCBPYTHONDIR) - ================================================================ ---- gitweb: http://git.pld-linux.org/gitweb.cgi/packages/python-xpyb.git/commitdiff/6537e86bc442f8d0f953ea87995bebd4411b1932 _______________________________________________ pld-cvs-commit mailing list pld-cvs-commit@lists.pld-linux.org http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit