add proper locking for libfmt!
This commit is contained in:
parent
a3add39bbc
commit
5787ba4d73
1 changed files with 16 additions and 0 deletions
16
src/lib9/fmtlock2.c
Normal file
16
src/lib9/fmtlock2.c
Normal file
|
|
@ -0,0 +1,16 @@
|
||||||
|
#include <u.h>
|
||||||
|
#include <libc.h>
|
||||||
|
|
||||||
|
static QLock fmtlock;
|
||||||
|
|
||||||
|
void
|
||||||
|
__fmtlock(void)
|
||||||
|
{
|
||||||
|
qlock(&fmtlock);
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
__fmtunlock(void)
|
||||||
|
{
|
||||||
|
qunlock(&fmtlock);
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue