summaryrefslogtreecommitdiff
path: root/src/stdio/ferror.c
blob: b5a4a0855388275788081869ae82bd82c8126711 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#include <stdio.h>
#include "_assert.h"
#include "_stdio.h"

/** tests the file stream error indicator **/

int ferror(FILE *stream)
{
	ASSERT_NONNULL(stream);
	/*
	RETURN(0, the error indicator is not set);
	RETURN(NONZERO, the error indicator is set);
	*/
	return stream->err;
}

/***
tests the error indicator of ARGUMENT(stream).
***/

/*
STDC(1)
*/