projects
/
imager.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
blame
|
history
|
raw
|
HEAD
improved thread safety for Imager
[imager.git]
/
mutexnull.c
1
/*
2
dummy mutexes, for non-threaded builds
3
*/
4
5
#include "imageri.h"
6
7
#include <pthread.h>
8
9
/* documented in mutexwin.c */
10
11
struct i_mutex_tag {
12
int dummy;
13
};
14
15
i_mutex_t
16
i_mutex_new(void) {
17
i_mutex_t m;
18
19
if (!m)
20
i_fatal(3, "Cannot allocate mutex object");
21
m = malloc(sizeof(*m));
22
23
return m;
24
}
25
26
void
27
i_mutex_destroy(i_mutex_t m) {
28
free(m);
29
}
30
31
void
32
i_mutex_lock(i_mutex_t m) {
33
(void)m;
34
}
35
36
void
37
i_mutex_unlock(i_mutex_t m) {
38
(void)m;
39
}