[Xcb] [PATCH] Use xcb_discard_request() when deallocating a cookie

Julien Danjou julien at danjou.info
Mon Mar 15 05:35:35 PDT 2010


Signed-off-by: Julien Danjou <julien at danjou.info>
---
 configure.ac |    2 +-
 src/cookie.c |    1 +
 2 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/configure.ac b/configure.ac
index 4f01541..bed3ee6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -28,7 +28,7 @@ AC_PROG_CC
 
 # Checks for pkg-config packages
 PKG_CHECK_MODULES(XCBPROTO, xcb-proto >= 1.6)
-PKG_CHECK_MODULES(LIBXCB, xcb >= 1.1)
+PKG_CHECK_MODULES(LIBXCB, xcb > 1.5)
 
 # Find the xcb-proto protocol descriptions
 AC_MSG_CHECKING([for xcb-proto include dir])
diff --git a/src/cookie.c b/src/cookie.c
index db0a20f..6c43e62 100644
--- a/src/cookie.c
+++ b/src/cookie.c
@@ -23,6 +23,7 @@ xpybCookie_new(PyTypeObject *self, PyObject *args, PyObject *kw)
 static void
 xpybCookie_dealloc(xpybCookie *self)
 {
+    xcb_discard_reply(c, self->cookie.sequence);
     Py_CLEAR(self->reply_type);
     Py_CLEAR(self->request);
     Py_CLEAR(self->conn);
-- 
1.7.0



More information about the Xcb mailing list