Subversion Repositories Kolibri OS

Rev

Rev 4921 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 4921 Rev 6099
Line 15... Line 15...
15
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
15
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
16
 */
16
 */
Line 17... Line 17...
17
 
17
 
18
/*
18
/*
19
FUNCTION
19
FUNCTION
Line 20... Line 20...
20
<>---get a character from a file or stream
20
<>, <>---get a character from a file or stream
21
 
21
 
22
INDEX
22
INDEX
-
 
23
	fgetc
-
 
24
INDEX
23
	fgetc
25
	fgetc_unlocked
-
 
26
INDEX
-
 
27
	_fgetc_r
Line 24... Line 28...
24
INDEX
28
INDEX
25
	_fgetc_r
29
	_fgetc_unlocked_r
26
 
30
 
Line -... Line 31...
-
 
31
ANSI_SYNOPSIS
-
 
32
	#include 
-
 
33
	int fgetc(FILE *<[fp]>);
-
 
34
 
27
ANSI_SYNOPSIS
35
	#define _BSD_SOURCE
28
	#include 
36
	#include 
Line -... Line 37...
-
 
37
	int fgetc_unlocked(FILE *<[fp]>);
-
 
38
 
-
 
39
	#include 
-
 
40
	int _fgetc_r(struct _reent *<[ptr]>, FILE *<[fp]>);
29
	int fgetc(FILE *<[fp]>);
41
 
30
 
42
	#define _BSD_SOURCE
31
	#include 
43
	#include 
32
	int _fgetc_r(struct _reent *<[ptr]>, FILE *<[fp]>);
44
	int _fgetc_unlocked_r(struct _reent *<[ptr]>, FILE *<[fp]>);
Line -... Line 45...
-
 
45
 
-
 
46
TRAD_SYNOPSIS
-
 
47
	#include 
-
 
48
	int fgetc(<[fp]>)
-
 
49
	FILE *<[fp]>;
33
 
50
 
34
TRAD_SYNOPSIS
51
	#define _BSD_SOURCE
35
	#include 
52
	#include 
36
	int fgetc(<[fp]>)
53
	int fgetc_unlocked(<[fp]>)
Line -... Line 54...
-
 
54
	FILE *<[fp]>;
-
 
55
 
-
 
56
	#include 
-
 
57
	int _fgetc_r(<[ptr]>, <[fp]>)
-
 
58
	struct _reent *<[ptr]>;
-
 
59
	FILE *<[fp]>;
37
	FILE *<[fp]>;
60
 
38
 
61
	#define _BSD_SOURCE
39
	#include 
62
	#include 
40
	int _fgetc_r(<[ptr]>, <[fp]>)
63
	int _fgetc_unlocked_r(<[ptr]>, <[fp]>)
Line 41... Line 64...
41
	struct _reent *<[ptr]>;
64
	struct _reent *<[ptr]>;
Line -... Line 65...
-
 
65
	FILE *<[fp]>;
-
 
66
 
-
 
67
DESCRIPTION
-
 
68
Use <> to get the next single character from the file or stream
-
 
69
identified by <[fp]>.  As a side effect, <> advances the file's
-
 
70
current position indicator.
-
 
71
 
-
 
72
For a macro version of this function, see <>.
-
 
73
 
42
	FILE *<[fp]>;
74
<> is a non-thread-safe version of <>.
43
 
75
<> may only safely be used within a scope
44
DESCRIPTION
76
protected by flockfile() (or ftrylockfile()) and funlockfile().  This
Line 45... Line 77...
45
Use <> to get the next single character from the file or stream
77
function may safely be used in a multi-threaded program if and only
46
identified by <[fp]>.  As a side effect, <> advances the file's
78
if they are called while the invoking thread owns the (FILE *)
47
current position indicator.
79
object, as is the case after a successful call to the flockfile() or
48
 
80
ftrylockfile() functions.  If threads are disabled, then
Line 61... Line 93...
61
using the <> and <> functions.
93
using the <> and <> functions.
Line 62... Line 94...
62
 
94
 
63
PORTABILITY
95
PORTABILITY
Line -... Line 96...
-
 
96
ANSI C requires <>.
-
 
97
 
64
ANSI C requires <>.
98
<> is a BSD extension also provided by GNU libc.
65
 
99
 
66
Supporting OS subroutines required: <>, <>, <>,
100
Supporting OS subroutines required: <>, <>, <>,
Line 67... Line 101...
67
<>, <>, <>, <>.
101
<>, <>, <>, <>.