|
|
1.1 root 1:
2:
3: sbrk() COHERENT System Call sbrk()
4:
5:
6:
7:
8: Increase a program's data space
9:
10: cchhaarr *ssbbrrkk(_i_n_c_r_e_m_e_n_t) uunnssiiggnneedd iinntt _i_n_c_r_e_m_e_n_t;
11:
12: sbrk increases a program's data space by increment bytes. It in-
13: crements the variable _ _end; this variable is set by the C run-
14: time startup routine, and points to the end of the program's
15: data space. The memory allocation routine malloc calls sbrk
16: should you attempt to allocate more space than is available in
17: the program's data space.
18:
19: sbrk returns a pointer to the previous setting of _ _end if the
20: requested memory is available, or NULL if it is not.
21:
22: ***** See Also *****
23:
24: brk(), COHERENT system calls, malloc()
25:
26: ***** Notes *****
27:
28: sbrk will not increase the size of the program data area if the
29: physical memory requested exceeds the physical memory allocated
30: by COHERENT, or if the requested memory exceeds the limit set in
31: the user-defined variable maxmem. sbrk does not keep track of
32: how space is used; therefore, memory seized with sbrk cannot be
33: freed. Caveat utilitor.
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64: COHERENT Lexicon Page 1
65:
66:
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.