blob: 8755b1dad2719d18610fcd1e35611bb90bf8e07a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
/* $OpenBSD: thread_malloc_lock.c,v 1.4 2002/11/05 22:19:55 marc Exp $ */
/* Public Domain <marc@snafu.org> */
#include <pthread.h>
#include "pthread_private.h"
static spinlock_t malloc_lock = _SPINLOCK_INITIALIZER;
void
_thread_malloc_lock()
{
_SPINLOCK(&malloc_lock);
}
void
_thread_malloc_unlock()
{
_SPINUNLOCK(&malloc_lock);
}
void
_thread_malloc_init()
{
}
|