libxcb 1.8.1
This commit is contained in:
parent
5b5004c8b3
commit
a1e6e0f6cb
1
.gitignore
vendored
1
.gitignore
vendored
@ -5,3 +5,4 @@ libxcb-1.4.tar.bz2
|
|||||||
libxcb-1.5.tar.bz2
|
libxcb-1.5.tar.bz2
|
||||||
libxcb-1.7.tar.bz2
|
libxcb-1.7.tar.bz2
|
||||||
/libxcb-1.8.tar.bz2
|
/libxcb-1.8.tar.bz2
|
||||||
|
/libxcb-1.8.1.tar.bz2
|
||||||
|
@ -1,79 +0,0 @@
|
|||||||
diff --git a/src/xcb_conn.c b/src/xcb_conn.c
|
|
||||||
index 7e18891..e30c5ca 100644
|
|
||||||
--- a/src/xcb_conn.c
|
|
||||||
+++ b/src/xcb_conn.c
|
|
||||||
@@ -42,13 +42,18 @@
|
|
||||||
#include <sys/select.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
+/* SHUT_RDWR is fairly recent and is not available on all platforms */
|
|
||||||
+#if !defined(SHUT_RDWR)
|
|
||||||
+#define SHUT_RDWR 2
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
typedef struct {
|
|
||||||
uint8_t status;
|
|
||||||
uint8_t pad0[5];
|
|
||||||
uint16_t length;
|
|
||||||
} xcb_setup_generic_t;
|
|
||||||
|
|
||||||
-static const int error_connection = 1;
|
|
||||||
+const int error_connection = 1;
|
|
||||||
|
|
||||||
static int set_fd_flags(const int fd)
|
|
||||||
{
|
|
||||||
@@ -243,10 +248,13 @@ xcb_connection_t *xcb_connect_to_fd(int fd, xcb_auth_info_t *auth_info)
|
|
||||||
|
|
||||||
void xcb_disconnect(xcb_connection_t *c)
|
|
||||||
{
|
|
||||||
- if(c->has_error)
|
|
||||||
+ if(c == (xcb_connection_t *) &error_connection)
|
|
||||||
return;
|
|
||||||
|
|
||||||
free(c->setup);
|
|
||||||
+
|
|
||||||
+ /* disallow further sends and receives */
|
|
||||||
+ shutdown(c->fd, SHUT_RDWR);
|
|
||||||
close(c->fd);
|
|
||||||
|
|
||||||
pthread_mutex_destroy(&c->iolock);
|
|
||||||
@@ -311,6 +319,13 @@ int _xcb_conn_wait(xcb_connection_t *c, pthread_cond_t *cond, struct iovec **vec
|
|
||||||
do {
|
|
||||||
#if USE_POLL
|
|
||||||
ret = poll(&fd, 1, -1);
|
|
||||||
+ /* If poll() returns an event we didn't expect, such as POLLNVAL, treat
|
|
||||||
+ * it as if it failed. */
|
|
||||||
+ if(ret >= 0 && (fd.revents & ~fd.events))
|
|
||||||
+ {
|
|
||||||
+ ret = -1;
|
|
||||||
+ break;
|
|
||||||
+ }
|
|
||||||
#else
|
|
||||||
ret = select(c->fd + 1, &rfds, &wfds, 0, 0);
|
|
||||||
#endif
|
|
||||||
diff --git a/src/xcb_util.c b/src/xcb_util.c
|
|
||||||
index 5a82ac1..07fa4a3 100644
|
|
||||||
--- a/src/xcb_util.c
|
|
||||||
+++ b/src/xcb_util.c
|
|
||||||
@@ -49,8 +49,6 @@
|
|
||||||
#include "xcbext.h"
|
|
||||||
#include "xcbint.h"
|
|
||||||
|
|
||||||
-static const int error_connection = 1;
|
|
||||||
-
|
|
||||||
int xcb_popcount(uint32_t mask)
|
|
||||||
{
|
|
||||||
uint32_t y;
|
|
||||||
diff --git a/src/xcbint.h b/src/xcbint.h
|
|
||||||
index f07add8..6991238 100644
|
|
||||||
--- a/src/xcbint.h
|
|
||||||
+++ b/src/xcbint.h
|
|
||||||
@@ -174,6 +174,8 @@ void _xcb_ext_destroy(xcb_connection_t *c);
|
|
||||||
|
|
||||||
/* xcb_conn.c */
|
|
||||||
|
|
||||||
+extern const int error_connection;
|
|
||||||
+
|
|
||||||
struct xcb_connection_t {
|
|
||||||
int has_error;
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
|||||||
Name: libxcb
|
Name: libxcb
|
||||||
Version: 1.8
|
Version: 1.8.1
|
||||||
Release: 2%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: A C binding to the X11 protocol
|
Summary: A C binding to the X11 protocol
|
||||||
|
|
||||||
Group: System Environment/Libraries
|
Group: System Environment/Libraries
|
||||||
@ -108,6 +108,9 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
%{_datadir}/doc/%{name}-%{version}
|
%{_datadir}/doc/%{name}-%{version}
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Apr 09 2012 Adam Jackson <ajax@redhat.com> 1.8.1-1
|
||||||
|
- libxcb 1.8.1
|
||||||
|
|
||||||
* Fri Jan 13 2012 Adam Jackson <ajax@redhat.com> 1.8-2
|
* Fri Jan 13 2012 Adam Jackson <ajax@redhat.com> 1.8-2
|
||||||
- Don't %%doc in the base package, that pulls in copies of things we only
|
- Don't %%doc in the base package, that pulls in copies of things we only
|
||||||
want in -doc subpackage.
|
want in -doc subpackage.
|
||||||
|
Loading…
Reference in New Issue
Block a user