[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 _xfree()
 Free allocated memory
------------------------------------------------------------------------------
 C Prototype

     #include "fm.api"
     void _xfree(
                  void far * vlpMem
                )

 Arguments

     vlpMem is a far pointer to memory allocated with _xalloc() or
     _xgrab().

 Returns

     _xfree() has no return value.

 Description

     _xfree() releases memory allocated by _xalloc() or _xgrab().  Note that
     the pointer returned by _xalloc() or _xgrab() must be passed as the
     argument to _xfree().

     Note:  In Fm.api, _exmback() is defined (using #define) to _xfree()
     to maintain compatibility with Summer '87.

 Examples

     .  From C:

        char *mem;
        mem = _xgrab(320);
        _xfree(mem);

     .  From Assembly language:

        EXTRN __xgrab:FAR
        EXTRN __xfree:FAR
              mov   ax, 320
              push  ax
              call  __xgrab            ; pointer in DX:AX
              add   sp, 2              ; reset stack pointer
              push  dx
              push  ax
              call  __xfree            ; give it right back
              add   sp, 4

 Files  Library is CLIPPER.LIB, header file is Fm.api.


See Also: _xalloc() _xgrab()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson