SEGBRK man page on Plan9

Man page or keyword search:  
man Server   549 pages
apropos Keyword Search (all sections)
Output format
Plan9 logo
[printable version]

SEGBRK(2)							     SEGBRK(2)

       segbrk - change memory allocation

       #include <u.h>
       #include <libc.h>

       void* segbrk(void *saddr, void *addr)

       Segbrk  sets  the system's idea of the lowest unused location of a seg‐
       ment to addr rounded up to the next multiple of a page size,  typically
       4096  bytes.  The segment is identified by saddr which may be any valid
       address within the segment.

       A call to segbrk with a zero addr argument returns the address  of  the
       top of bss.

       The  system  will  prevent segments from overlapping and will not allow
       the length of the text, data, or stack segment to be altered.


       brk(2), segattach(2), segflush(2)

       Sets errstr.  Segbrk returns (void*)-1 on error.

       Segbrk is not fully defined or implemented.  In particular,  it	cannot
       always  return  the  top	 of bss when called with a zero addr argument.
       The segbrk system call may go away or be re-implemented	to  give  more
       general segment control, subsuming the functions of brk(2), segflush(2)
       and segfree in segattach(2).

                             _         _         _ 
                            | |       | |       | |     
                            | |       | |       | |     
                         __ | | __ __ | | __ __ | | __  
                         \ \| |/ / \ \| |/ / \ \| |/ /  
                          \ \ / /   \ \ / /   \ \ / /   
                           \   /     \   /     \   /    
                            \_/       \_/       \_/ 
More information is available in HTML format for server Plan9

List of man pages available for Plan9

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
Vote for polarhome
Free Shell Accounts :: the biggest list on the net