summaryrefslogtreecommitdiff
path: root/lib/libc/stdio/fgetc_unlocked.c
blob: 5cccfd874e7cb9d0fbbee3dc5cfd3013350b9ebc (plain)
1
2
3
4
5
6
7
8
9
10
11
#include <stdio.h>

int fgetc_unlocked(FILE *stream)
{
	int c;

	if (fread_unlocked(&c, 1, 1, stream) < 0)
		return -1;

	return c;
}