aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/glx
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-04-28 11:14:32 +0000
committermarha <marha@users.sourceforge.net>2011-04-28 11:14:32 +0000
commit1840c5631682e0a69ed11487a23a43d45f2d15e1 (patch)
treefe954636044c0057b9f08e76d19489493ff09745 /xorg-server/glx
parent2ab09dc03e4ecc726ee7b5528306b0fe3e5b1837 (diff)
parent57a879849643e79d9674198a3a77c59532fb79b4 (diff)
downloadvcxsrv-1840c5631682e0a69ed11487a23a43d45f2d15e1.tar.gz
vcxsrv-1840c5631682e0a69ed11487a23a43d45f2d15e1.tar.bz2
vcxsrv-1840c5631682e0a69ed11487a23a43d45f2d15e1.zip
svn merge ^/branches/released .
Diffstat (limited to 'xorg-server/glx')
-rw-r--r--xorg-server/glx/glapi.c6
-rw-r--r--xorg-server/glx/glapi.h1
-rw-r--r--xorg-server/glx/glthread.h3
-rw-r--r--xorg-server/glx/glxdri.c17
4 files changed, 16 insertions, 11 deletions
diff --git a/xorg-server/glx/glapi.c b/xorg-server/glx/glapi.c
index 5174124d9..c11454b1f 100644
--- a/xorg-server/glx/glapi.c
+++ b/xorg-server/glx/glapi.c
@@ -84,11 +84,9 @@ static void init_glapi_relocs(void);
/*@{*/
#if defined(GLX_USE_TLS)
-PUBLIC TLS struct _glapi_table * _glapi_tls_Dispatch
- __attribute__((tls_model("initial-exec"))) = NULL;
+PUBLIC TLS struct _glapi_table * _glapi_tls_Dispatch = NULL;
-PUBLIC TLS void * _glapi_tls_Context
- __attribute__((tls_model("initial-exec")));
+PUBLIC TLS void * _glapi_tls_Context;
PUBLIC const struct _glapi_table *_glapi_Dispatch = NULL;
PUBLIC const void *_glapi_Context = NULL;
diff --git a/xorg-server/glx/glapi.h b/xorg-server/glx/glapi.h
index 98f3913a9..2595087f9 100644
--- a/xorg-server/glx/glapi.h
+++ b/xorg-server/glx/glapi.h
@@ -101,7 +101,6 @@ _GLAPI_EXPORT extern const void *_glapi_Context;
_GLAPI_EXPORT extern const struct _glapi_table *_glapi_Dispatch;
_GLAPI_EXPORT extern __thread void * _glapi_tls_Context
- __attribute__((tls_model("initial-exec")));
# define GET_DISPATCH() _glapi_tls_Dispatch
# define GET_CURRENT_CONTEXT(C) struct gl_context *C = (struct gl_context *) _glapi_tls_Context
diff --git a/xorg-server/glx/glthread.h b/xorg-server/glx/glthread.h
index a1b0bf99a..4ad5d493d 100644
--- a/xorg-server/glx/glthread.h
+++ b/xorg-server/glx/glthread.h
@@ -233,8 +233,7 @@ _glthread_SetTSD(_glthread_TSD *, void *);
#if defined(GLX_USE_TLS)
-extern TLS struct _glapi_table * _glapi_tls_Dispatch
- __attribute__((tls_model("initial-exec")));
+extern TLS struct _glapi_table * _glapi_tls_Dispatch;
#define GET_DISPATCH() _glapi_tls_Dispatch
diff --git a/xorg-server/glx/glxdri.c b/xorg-server/glx/glxdri.c
index bd04fcd13..2119d4879 100644
--- a/xorg-server/glx/glxdri.c
+++ b/xorg-server/glx/glxdri.c
@@ -820,10 +820,19 @@ static void __glXReportDamage(__DRIdrawable *driDraw,
__glXenterServer(GL_FALSE);
- RegionInit(&region, (BoxPtr) rects, num_rects);
- RegionTranslate(&region, pDraw->x, pDraw->y);
- DamageDamageRegion(pDraw, &region);
- RegionUninit(&region);
+ if (RegionInitBoxes(&region, (BoxPtr) rects, num_rects)) {
+ RegionTranslate(&region, pDraw->x, pDraw->y);
+ DamageDamageRegion(pDraw, &region);
+ RegionUninit(&region);
+ }
+ else {
+ while (num_rects--) {
+ RegionInit (&region, (BoxPtr) rects++, 1);
+ RegionTranslate(&region, pDraw->x, pDraw->y);
+ DamageDamageRegion(pDraw, &region);
+ RegionUninit(&region);
+ }
+ }
__glXleaveServer(GL_FALSE);
}