tor  0.4.0.0-alpha-dev
compat_mutex_winthreads.c
Go to the documentation of this file.
1 /* Copyright (c) 2003-2004, Roger Dingledine
2  * Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
3  * Copyright (c) 2007-2018, The Tor Project, Inc. */
4 /* See LICENSE for licensing information */
5 
12 #include "lib/lock/compat_mutex.h"
13 #include "lib/err/torerr.h"
14 
15 void
16 tor_locking_init(void)
17 {
18 }
19 
20 void
22 {
23  InitializeCriticalSection(&m->mutex);
24 }
25 void
27 {
28  InitializeCriticalSection(&m->mutex);
29 }
30 
31 void
33 {
34  DeleteCriticalSection(&m->mutex);
35 }
36 void
38 {
39  raw_assert(m);
40  EnterCriticalSection(&m->mutex);
41 }
42 void
44 {
45  LeaveCriticalSection(&m->mutex);
46 }
void tor_mutex_uninit(tor_mutex_t *m)
void tor_mutex_acquire(tor_mutex_t *m)
void tor_mutex_init_nonrecursive(tor_mutex_t *m)
Header for compat_mutex.c.
Headers for torerr.c.
void tor_mutex_init(tor_mutex_t *m)
void tor_mutex_release(tor_mutex_t *m)