summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2001-11-02 00:56:45 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2001-11-02 00:56:45 +0000
commitf97edb4ca3639deee985354eb55388bc26dfae75 (patch)
tree3df59be3338324c1e757c9092468d23d93d381e0
parent3b0571dd5ca3988c14560e99d1c30a629da75706 (diff)
init the hash table mutex in _mesa_NewHashTable (Won-Suk Chun)
-rw-r--r--src/mesa/main/hash.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/mesa/main/hash.c b/src/mesa/main/hash.c
index 0d73fc9fd2..70d71c183d 100644
--- a/src/mesa/main/hash.c
+++ b/src/mesa/main/hash.c
@@ -1,4 +1,4 @@
-/* $Id: hash.c,v 1.10 2001/03/12 00:48:38 gareth Exp $ */
+/* $Id: hash.c,v 1.10.2.1 2001/11/02 00:56:45 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -64,7 +64,11 @@ struct _mesa_HashTable {
*/
struct _mesa_HashTable *_mesa_NewHashTable(void)
{
- return CALLOC_STRUCT(_mesa_HashTable);
+ struct _mesa_HashTable *table = CALLOC_STRUCT(_mesa_HashTable);
+ if (table) {
+ _glthread_INIT_MUTEX(table->Mutex);
+ }
+ return table;
}