aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/main
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-12-12 08:35:50 +0100
committermarha <marha@users.sourceforge.net>2012-12-12 08:35:50 +0100
commitb395c3c85251d4e8761704d8e3a3c9f9fa5b45cc (patch)
tree9e522597a3553d72c66f4c9c57fc15c6c4df345c /mesalib/src/mesa/main
parent0328076efb5ff6e62152c09e38d0d11f7931d07b (diff)
downloadvcxsrv-b395c3c85251d4e8761704d8e3a3c9f9fa5b45cc.tar.gz
vcxsrv-b395c3c85251d4e8761704d8e3a3c9f9fa5b45cc.tar.bz2
vcxsrv-b395c3c85251d4e8761704d8e3a3c9f9fa5b45cc.zip
fontconfig mesa pixman xkeyboard-config git update 12 dev 2012
fontconfig: 9ce36f4bbebc702a35d0cd9f1a59d5b828549bc6 mesa: 621259b3de1f15c879620bbf17764fd8a27ae6f5 pixman: fdab3c1b6cd9c5e197ec3f6bc0a03da32880e317 xkeyboard-config: 378597a9d525f069c049fdd6d04ff628123f82c7
Diffstat (limited to 'mesalib/src/mesa/main')
-rw-r--r--mesalib/src/mesa/main/mtypes.h1
-rw-r--r--mesalib/src/mesa/main/syncobj.c14
2 files changed, 10 insertions, 5 deletions
diff --git a/mesalib/src/mesa/main/mtypes.h b/mesalib/src/mesa/main/mtypes.h
index b353e7026..11a832281 100644
--- a/mesalib/src/mesa/main/mtypes.h
+++ b/mesalib/src/mesa/main/mtypes.h
@@ -2513,7 +2513,6 @@ struct gl_query_state
/** Sync object state */
struct gl_sync_object
{
- struct set_entry *SetEntry;
GLenum Type; /**< GL_SYNC_FENCE */
GLuint Name; /**< Fence name */
GLint RefCount; /**< Reference count */
diff --git a/mesalib/src/mesa/main/syncobj.c b/mesalib/src/mesa/main/syncobj.c
index f599982bd..b977bfa21 100644
--- a/mesalib/src/mesa/main/syncobj.c
+++ b/mesalib/src/mesa/main/syncobj.c
@@ -199,10 +199,16 @@ _mesa_ref_sync_object(struct gl_context *ctx, struct gl_sync_object *syncObj)
void
_mesa_unref_sync_object(struct gl_context *ctx, struct gl_sync_object *syncObj)
{
+ struct set_entry *entry;
+
_glthread_LOCK_MUTEX(ctx->Shared->Mutex);
syncObj->RefCount--;
if (syncObj->RefCount == 0) {
- _mesa_set_remove(ctx->Shared->SyncObjects, syncObj->SetEntry);
+ entry = _mesa_set_search(ctx->Shared->SyncObjects,
+ _mesa_hash_pointer(syncObj),
+ syncObj);
+ assert (entry != NULL);
+ _mesa_set_remove(ctx->Shared->SyncObjects, entry);
_glthread_UNLOCK_MUTEX(ctx->Shared->Mutex);
ctx->Driver.DeleteSyncObject(ctx, syncObj);
@@ -290,9 +296,9 @@ _mesa_FenceSync(GLenum condition, GLbitfield flags)
ctx->Driver.FenceSync(ctx, syncObj, condition, flags);
_glthread_LOCK_MUTEX(ctx->Shared->Mutex);
- syncObj->SetEntry = _mesa_set_add(ctx->Shared->SyncObjects,
- _mesa_hash_pointer(syncObj),
- syncObj);
+ _mesa_set_add(ctx->Shared->SyncObjects,
+ _mesa_hash_pointer(syncObj),
+ syncObj);
_glthread_UNLOCK_MUTEX(ctx->Shared->Mutex);
return (GLsync) syncObj;