1
0

flockfile.c 172 B

123456789
  1. #include "stdio_impl.h"
  2. #include "pthread_impl.h"
  3. void flockfile(FILE *f)
  4. {
  5. if (!ftrylockfile(f)) return;
  6. __lockfile(f);
  7. __register_locked_file(f, __pthread_self());
  8. }