Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
alexbevi
GitHub Repository: alexbevi/BizHawk
Path: blob/master/waterbox/libc/functions/stdio/funlockfile.c
2 views
1
/* funlockfile( FILE * )
2
3
This file is part of the Public Domain C Library (PDCLib).
4
Permission is granted to use, modify, and / or redistribute at will.
5
*/
6
7
#include <stdio.h>
8
#include <stdarg.h>
9
10
#ifndef REGTEST
11
#include "_PDCLIB_io.h"
12
#include <threads.h>
13
#include <stdlib.h>
14
15
void _PDCLIB_funlockfile( FILE * file )
16
{
17
int res = mtx_unlock( &file->lock );
18
switch(res) {
19
case thrd_success:
20
return;
21
22
default:
23
abort();
24
}
25
}
26
27
#endif
28
29
#ifdef TEST
30
#include "_PDCLIB_test.h"
31
32
int main( void )
33
{
34
// Not tested here - tested by other stdio test drivers
35
return TEST_RESULTS;
36
}
37
38
#endif
39
40