C Language and Libraries Help (clang.hlp) (Table of Contents; Topic list)
_dos_allocmem
 Summary Example                         Up Contents Index Back
─────Run-Time Library───────────────────────────────────────────────────────
 
     The _dos_allocmem function allocates a block of memory <size>
     paragraphs long. (A paragraph is 16 bytes.) Allocated blocks are
     always paragraph aligned. The segment descriptor for the initial
     segment of the new block is returned in the word pointed to by
     <seg>. If the request cannot be satisfied, the maximum possible
     size (in paragraphs) is returned in this word instead.
 
     Return Value
 
     If successful, _dos_allocmem returns 0. Otherwise, it returns the
     DOS error code and sets errno to ENOMEM, indicating insufficient
     memory or invalid arena (memory area) headers.
                                    -♦-