diff options
-rw-r--r-- | libxcb/NEWS | 8 | ||||
-rw-r--r-- | libxcb/configure.ac | 2 | ||||
-rw-r--r-- | libxcb/src/xcb_conn.c | 8 | ||||
-rw-r--r-- | libxcb/xcb-proto/src/xkb.xml | 4 | ||||
-rw-r--r-- | xorg-server/Xext/geext.c | 13 | ||||
-rw-r--r-- | xorg-server/Xext/geint.h | 3 | ||||
-rw-r--r-- | xorg-server/dix/extension.c | 5 | ||||
-rw-r--r-- | xorg-server/exa/exa_accel.c | 2 | ||||
-rw-r--r-- | xorg-server/glx/glxdri.c | 7 | ||||
-rw-r--r-- | xorg-server/glx/glxdri2.c | 28 | ||||
-rw-r--r-- | xorg-server/glx/glxdricommon.c | 13 | ||||
-rw-r--r-- | xorg-server/glx/glxdricommon.h | 3 | ||||
-rw-r--r-- | xorg-server/glx/glxdriswrast.c | 5 | ||||
-rw-r--r-- | xorg-server/include/protocol-versions.h | 4 |
14 files changed, 55 insertions, 50 deletions
diff --git a/libxcb/NEWS b/libxcb/NEWS index 0855448c5..457059877 100644 --- a/libxcb/NEWS +++ b/libxcb/NEWS @@ -1,3 +1,11 @@ +Release 1.6 (2010-04-09) +======================== +- darwin: xnu doesn't support poll on ttys on the master side +- Fix descriptor leak on memory error path +- Support xcb_discard_reply +- Open the X11 socket with close-on-exec flag +- Fix authentication on hpux and Hurd + Release 1.5 (2009-12-03) ======================== - setsockopt(SO_KEEPALIVE) on TCP display connections diff --git a/libxcb/configure.ac b/libxcb/configure.ac index 23f4f2253..c5f454bee 100644 --- a/libxcb/configure.ac +++ b/libxcb/configure.ac @@ -3,7 +3,7 @@ AC_PREREQ(2.57) AC_INIT([libxcb], - 1.5, + 1.6, [xcb@lists.freedesktop.org]) AC_CONFIG_SRCDIR([xcb.pc.in]) AM_INIT_AUTOMAKE([foreign dist-bzip2]) diff --git a/libxcb/src/xcb_conn.c b/libxcb/src/xcb_conn.c index ed2153d27..1d3761452 100644 --- a/libxcb/src/xcb_conn.c +++ b/libxcb/src/xcb_conn.c @@ -210,6 +210,14 @@ xcb_connection_t *xcb_connect_to_fd(int fd, xcb_auth_info_t *auth_info) { xcb_connection_t* c; +#ifndef USE_POLL + if(fd >= FD_SETSIZE) /* would overflow in FD_SET */ + { + close(fd); + return (xcb_connection_t *) &error_connection; + } +#endif + c = calloc(1, sizeof(xcb_connection_t)); if(!c) { close(fd); diff --git a/libxcb/xcb-proto/src/xkb.xml b/libxcb/xcb-proto/src/xkb.xml index fb97ba408..33d3ea354 100644 --- a/libxcb/xcb-proto/src/xkb.xml +++ b/libxcb/xcb-proto/src/xkb.xml @@ -1127,7 +1127,7 @@ authorization from the authors. </switch> </request> - <request name="Bell" opcode="2"> + <request name="Bell" opcode="3"> <field name="deviceSpec" type="DeviceSpec" /> <field name="bellClass" type="BellClassSpec" /> <field name="bellID" type="IDSpec" /> @@ -1142,7 +1142,7 @@ authorization from the authors. <field name="window" type="WINDOW" /> </request> - <request name="GetState" opcode="3"> + <request name="GetState" opcode="4"> <field name="deviceSpec" type="DeviceSpec" /> <pad bytes="2" /> <reply> diff --git a/xorg-server/Xext/geext.c b/xorg-server/Xext/geext.c index 2ba0ca824..f0a3d8778 100644 --- a/xorg-server/Xext/geext.c +++ b/xorg-server/Xext/geext.c @@ -36,11 +36,8 @@ #define rClient(obj) (clients[CLIENT_ID((obj)->resource)]) -int GEEventBase; -int GEErrorBase; static int GEClientPrivateKeyIndex; DevPrivateKey GEClientPrivateKey = &GEClientPrivateKeyIndex; -int GEEventType; /* The opcode for all GenericEvents will have. */ int RT_GECLIENT = 0; @@ -178,10 +175,6 @@ GEResetProc(ExtensionEntry *extEntry) { DeleteCallback(&ClientStateCallback, GEClientCallback, 0); EventSwapVector[GenericEvent] = NotImplemented; - - GEEventBase = 0; - GEErrorBase = 0; - GEEventType = 0; } /* Calls the registered event swap function for the extension. @@ -225,14 +218,10 @@ GEExtensionInit(void) } if((extEntry = AddExtension(GE_NAME, - GENumberEvents, GENumberErrors, + 0, GENumberErrors, ProcGEDispatch, SProcGEDispatch, GEResetProc, StandardMinorOpcode)) != 0) { - GEEventBase = extEntry->eventBase; - GEErrorBase = extEntry->errorBase; - GEEventType = GEEventBase; - memset(GEExtensions, 0, sizeof(GEExtensions)); EventSwapVector[GenericEvent] = (EventSwapPtr) SGEGenericEvent; diff --git a/xorg-server/Xext/geint.h b/xorg-server/Xext/geint.h index 881d30661..10a33cea3 100644 --- a/xorg-server/Xext/geint.h +++ b/xorg-server/Xext/geint.h @@ -37,9 +37,6 @@ #include "extnsionst.h" #include <X11/extensions/geproto.h> -extern _X_EXPORT int GEEventType; -extern _X_EXPORT int GEEventBase; -extern _X_EXPORT int GEErrorBase; extern _X_EXPORT DevPrivateKey GEClientPrivateKey; typedef struct _GEClientInfo { diff --git a/xorg-server/dix/extension.c b/xorg-server/dix/extension.c index fb83af148..f34866586 100644 --- a/xorg-server/dix/extension.c +++ b/xorg-server/dix/extension.c @@ -83,8 +83,11 @@ AddExtension(char *name, int NumEvents, int NumErrors, if (!MainProc || !SwappedMainProc || !MinorOpcodeProc) return((ExtensionEntry *) NULL); if ((lastEvent + NumEvents > LAST_EVENT) || - (unsigned)(lastError + NumErrors > LAST_ERROR)) + (unsigned)(lastError + NumErrors > LAST_ERROR)) { + LogMessage(X_ERROR, "Not enabling extension %s: maximum number of " + "events or errors exceeded.\n", name); return((ExtensionEntry *) NULL); + } ext = xalloc(sizeof(ExtensionEntry)); if (!ext) diff --git a/xorg-server/exa/exa_accel.c b/xorg-server/exa/exa_accel.c index 4680c3709..57029fdc5 100644 --- a/xorg-server/exa/exa_accel.c +++ b/xorg-server/exa/exa_accel.c @@ -512,7 +512,7 @@ exaHWCopyNtoN (DrawablePtr pSrcDrawable, * * Only taking this path for directly accessible pixmaps. */ - } else if (!pDstExaPixmap->pDamage) { + } else if (!pDstExaPixmap->pDamage && pSrcExaPixmap->sys_ptr) { int bpp = pSrcDrawable->bitsPerPixel; int src_stride = exaGetPixmapPitch(pSrcPixmap); CARD8 *src = NULL; diff --git a/xorg-server/glx/glxdri.c b/xorg-server/glx/glxdri.c index 21e44d12d..9810a73a7 100644 --- a/xorg-server/glx/glxdri.c +++ b/xorg-server/glx/glxdri.c @@ -35,6 +35,7 @@ #include <drm.h> #include <GL/gl.h> #include <GL/internal/dri_interface.h> +#include <GL/glxtokens.h> #include <windowstr.h> #include <os.h> @@ -939,9 +940,6 @@ initializeExtensions(__GLXDRIscreen *screen) } } -extern __GLXconfig * -glxConvertConfigs(const __DRIcoreExtension *core, const __DRIconfig **configs); - static __GLXscreen * __glXDRIscreenProbe(ScreenPtr pScreen) { @@ -1131,7 +1129,8 @@ __glXDRIscreenProbe(ScreenPtr pScreen) goto handle_error; } - screen->base.fbconfigs = glxConvertConfigs(screen->core, driConfigs); + screen->base.fbconfigs = glxConvertConfigs(screen->core, + driConfigs, GLX_WINDOW_BIT); initializeExtensions(screen); diff --git a/xorg-server/glx/glxdri2.c b/xorg-server/glx/glxdri2.c index edd29b0e1..4c9f381c6 100644 --- a/xorg-server/glx/glxdri2.c +++ b/xorg-server/glx/glxdri2.c @@ -616,6 +616,7 @@ glxDRILeaveVT (int index, int flags) static void initializeExtensions(__GLXDRIscreen *screen) { + ScreenPtr pScreen = screen->base.pScreen; const __DRIextension **extensions; int i; @@ -625,10 +626,17 @@ initializeExtensions(__GLXDRIscreen *screen) "GLX_MESA_copy_sub_buffer"); LogMessage(X_INFO, "AIGLX: enabled GLX_MESA_copy_sub_buffer\n"); - /* FIXME: only if DDX supports it */ __glXEnableExtension(screen->glx_enable_bits, "GLX_INTEL_swap_event"); LogMessage(X_INFO, "AIGLX: enabled GLX_INTEL_swap_event\n"); + if (DRI2HasSwapControl(pScreen)) { + __glXEnableExtension(screen->glx_enable_bits, + "GLX_SGI_swap_control"); + __glXEnableExtension(screen->glx_enable_bits, + "GLX_MESA_swap_control"); + LogMessage(X_INFO, "AIGLX: enabled GLX_SGI_swap_control and GLX_MESA_swap_control\n"); + } + for (i = 0; extensions[i]; i++) { #ifdef __DRI_READ_DRAWABLE if (strcmp(extensions[i]->name, __DRI_READ_DRAWABLE) == 0) { @@ -639,19 +647,6 @@ initializeExtensions(__GLXDRIscreen *screen) } #endif -#ifdef __DRI_SWAP_CONTROL - if (strcmp(extensions[i]->name, __DRI_SWAP_CONTROL) == 0) { - screen->swapControl = - (const __DRIswapControlExtension *) extensions[i]; - __glXEnableExtension(screen->glx_enable_bits, - "GLX_SGI_swap_control"); - __glXEnableExtension(screen->glx_enable_bits, - "GLX_MESA_swap_control"); - - LogMessage(X_INFO, "AIGLX: enabled GLX_SGI_swap_control and GLX_MESA_swap_control\n"); - } -#endif - #ifdef __DRI_TEX_BUFFER if (strcmp(extensions[i]->name, __DRI_TEX_BUFFER) == 0) { screen->texBuffer = @@ -753,7 +748,10 @@ __glXDRIscreenProbe(ScreenPtr pScreen) initializeExtensions(screen); - screen->base.fbconfigs = glxConvertConfigs(screen->core, driConfigs); + screen->base.fbconfigs = glxConvertConfigs(screen->core, driConfigs, + GLX_WINDOW_BIT | + GLX_PIXMAP_BIT | + GLX_PBUFFER_BIT); __glXScreenInit(&screen->base, pScreen); diff --git a/xorg-server/glx/glxdricommon.c b/xorg-server/glx/glxdricommon.c index faaa3b7ae..454aa5587 100644 --- a/xorg-server/glx/glxdricommon.c +++ b/xorg-server/glx/glxdricommon.c @@ -121,7 +121,7 @@ setScalar(__GLXconfig *config, unsigned int attrib, unsigned int value) static __GLXconfig * createModeFromConfig(const __DRIcoreExtension *core, const __DRIconfig *driConfig, - unsigned int visualType) + unsigned int visualType, unsigned int drawableType) { __GLXDRIconfig *config; unsigned int attrib, value; @@ -167,13 +167,14 @@ createModeFromConfig(const __DRIcoreExtension *core, config->config.next = NULL; config->config.xRenderable = GL_TRUE; config->config.visualType = visualType; - config->config.drawableType = GLX_WINDOW_BIT | GLX_PIXMAP_BIT; + config->config.drawableType = drawableType; return &config->config; } __GLXconfig * -glxConvertConfigs(const __DRIcoreExtension *core, const __DRIconfig **configs) +glxConvertConfigs(const __DRIcoreExtension *core, + const __DRIconfig **configs, unsigned int drawableType) { __GLXconfig head, *tail; int i; @@ -183,7 +184,8 @@ glxConvertConfigs(const __DRIcoreExtension *core, const __DRIconfig **configs) for (i = 0; configs[i]; i++) { tail->next = createModeFromConfig(core, - configs[i], GLX_TRUE_COLOR); + configs[i], GLX_TRUE_COLOR, + drawableType); if (tail->next == NULL) break; @@ -192,7 +194,8 @@ glxConvertConfigs(const __DRIcoreExtension *core, const __DRIconfig **configs) for (i = 0; configs[i]; i++) { tail->next = createModeFromConfig(core, - configs[i], GLX_DIRECT_COLOR); + configs[i], GLX_DIRECT_COLOR, + drawableType); if (tail->next == NULL) break; diff --git a/xorg-server/glx/glxdricommon.h b/xorg-server/glx/glxdricommon.h index f88964b36..41e2d2770 100644 --- a/xorg-server/glx/glxdricommon.h +++ b/xorg-server/glx/glxdricommon.h @@ -33,7 +33,8 @@ struct __GLXDRIconfig { }; __GLXconfig * -glxConvertConfigs(const __DRIcoreExtension *core, const __DRIconfig **configs); +glxConvertConfigs(const __DRIcoreExtension *core, + const __DRIconfig **configs, unsigned int drawableType); extern const __DRIsystemTimeExtension systemTimeExtension; diff --git a/xorg-server/glx/glxdriswrast.c b/xorg-server/glx/glxdriswrast.c index c647d83ca..918383cf0 100644 --- a/xorg-server/glx/glxdriswrast.c +++ b/xorg-server/glx/glxdriswrast.c @@ -506,7 +506,10 @@ __glXDRIscreenProbe(ScreenPtr pScreen) initializeExtensions(screen); - screen->base.fbconfigs = glxConvertConfigs(screen->core, driConfigs); + screen->base.fbconfigs = glxConvertConfigs(screen->core, driConfigs, + GLX_WINDOW_BIT | + GLX_PIXMAP_BIT | + GLX_PBUFFER_BIT); __glXScreenInit(&screen->base, pScreen); diff --git a/xorg-server/include/protocol-versions.h b/xorg-server/include/protocol-versions.h index c74b7faf0..97ef5dad5 100644 --- a/xorg-server/include/protocol-versions.h +++ b/xorg-server/include/protocol-versions.h @@ -51,10 +51,6 @@ #define SERVER_DMX_MINOR_VERSION 2 #define SERVER_DMX_PATCH_VERSION 20040604 -/* DRI2 */ -#define SERVER_DRI2_MAJOR_VERSION 1 -#define SERVER_DRI2_MINOR_VERSION 2 - /* Generic event extension */ #define SERVER_GE_MAJOR_VERSION 1 #define SERVER_GE_MINOR_VERSION 0 |