home *** CD-ROM | disk | FTP | other *** search
/ MACD 4 / MACD4.iso / Emulatory / AROS / utility / freetagitems.c < prev    next >
Encoding:
C/C++ Source or Header  |  1978-03-06  |  1.8 KB  |  82 lines

  1. /*
  2.     $Id: freetagitems.c,v 1.4 1996/10/24 15:51:35 aros Exp $
  3.     $Log: freetagitems.c,v $
  4.     Revision 1.4  1996/10/24 15:51:35  aros
  5.     Use the official AROS macros over the __AROS versions.
  6.  
  7.     Revision 1.3  1996/09/13 17:36:37  digulla
  8.     Use IPTR
  9.  
  10.     Revision 1.2  1996/09/12 14:52:47  digulla
  11.     Better way to separate public and private parts of the library base
  12.  
  13.     Revision 1.1  1996/08/31 12:58:12  aros
  14.     Merged in/modified for FreeBSD.
  15.  
  16.     Desc: FreeTagItems()
  17.     Lang: english
  18. */
  19. #include "utility_intern.h"
  20.  
  21. /*****************************************************************************
  22.  
  23.     NAME */
  24.     #include <utility/tagitem.h>
  25.     #include <clib/utility_protos.h>
  26.  
  27.     AROS_LH1(void, FreeTagItems,
  28.  
  29. /*  SYNOPSIS */
  30.     AROS_LHA(struct TagItem *, tagList, A0),
  31.  
  32. /*  LOCATION */
  33.     struct UtilityBase *, UtilityBase, 13, Utility)
  34.  
  35. /*  FUNCTION
  36.     Free a list of TagItems which was allocated by AllocateTagItems().
  37.  
  38.     INPUTS
  39.     tagList     - A list of TagItems - must have been allocated by
  40.               AllocateTagItems() or CloneTagItems().
  41.  
  42.     RESULT
  43.     The memory containing the tagList is returned to the system.
  44.  
  45.     NOTES
  46.     The memory will only be freed if the input is non-NULL.
  47.  
  48.     EXAMPLE
  49.     struct TagItem *tagList;
  50.  
  51.     tagList =  AllocateTagItems( 4 );
  52.  
  53.     tagList[0].ti_Tag  = NA_Name;
  54.     tagList[0].ti_Data = (IPTR)"A list of tags";
  55.     tagList[3].ti_Tag  = TAG_DONE;
  56.  
  57.     \* Do what you want with your TagList here ... *\
  58.  
  59.     FreeTagItems( tagList );
  60.  
  61.     BUGS
  62.  
  63.     SEE ALSO
  64.     utility/tagitem.h, utility/AllocateTagItems()
  65.  
  66.     INTERNALS
  67.  
  68.     HISTORY
  69.     29-10-95    digulla automatically created from
  70.                 utility_lib.fd and clib/utility_protos.h
  71.     11-08-96    iaint   Moved into AROS source tree.
  72.  
  73. *****************************************************************************/
  74. {
  75.     AROS_LIBFUNC_INIT
  76.  
  77.     if( tagList )
  78.     FreeVec( tagList );
  79.  
  80.     AROS_LIBFUNC_EXIT
  81. } /* FreeTagItems */
  82.