DOS Fn 4aH: Shrink or Expand a Memory Block
Compatibility: 2.0+
Expects: AH 4aH
ES segment of an allocated memory block
BX desired size for the block, in paragraphs (16-byte chunks)
──────────────────────────────────────────────────────────────────
Returns: AX error code if CF is set to CY
BX largest block available (if a "grow" request fails)
──────────────────────────────────────────────────────────────────
Info: Changes the size of an existing memory block.
When a program receives control, the 4bH EXEC function has
allocated a memory block starting at the PSP that contains all of
available memory. To make memory available to EXEC a child
process, shrink the block starting at your PSP paragraph.
Notes: ■ DOS Fn 31H and INT 27H shrink the block at the PSP.
■ .COM programs: Move your stack down BEFORE shrinking your
block!
See Also: Memory Control Functions
Memory Control Block
DOS Functions
-♦-