blob: 768bb52b6ebb100777dc033939a038e6cc56fa5d [file] [log] [blame]
#include "stdio_impl.h"
#include "pthread_impl.h"
void flockfile(FILE* f) {
while (ftrylockfile(f)) {
int owner = f->lock;
if (owner)
__wait(&f->lock, &f->waiters, owner, 1);
}
}