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

  1. /*
  2.     (C) 1995-96 AROS - The Amiga Replacement OS
  3.     $Id: freedosentry.c,v 1.5 1996/10/24 15:50:30 aros Exp $
  4.     $Log: freedosentry.c,v $
  5.     Revision 1.5  1996/10/24 15:50:30  aros
  6.     Use the official AROS macros over the __AROS versions.
  7.  
  8.     Revision 1.4  1996/10/10 13:20:49  digulla
  9.     Use dol_DevName(STRPTR) instead of dol_Name(BSTR) (Fleischer)
  10.  
  11.     Revision 1.3  1996/08/13 13:52:47  digulla
  12.     Replaced <dos/dosextens.h> by "dos_intern.h" or added "dos_intern.h"
  13.     Replaced AROS_LA by AROS_LHA
  14.  
  15.     Revision 1.2  1996/08/01 17:40:52  digulla
  16.     Added standard header for all files
  17.  
  18.     Desc:
  19.     Lang: english
  20. */
  21. #include <clib/exec_protos.h>
  22. #include "dos_intern.h"
  23.  
  24. /*****************************************************************************
  25.  
  26.     NAME */
  27.     #include <clib/dos_protos.h>
  28.  
  29.     AROS_LH1(void, FreeDosEntry,
  30.  
  31. /*  SYNOPSIS */
  32.     AROS_LHA(struct DosList *, dlist, D1),
  33.  
  34. /*  LOCATION */
  35.     struct DosLibrary *, DOSBase, 117, Dos)
  36.  
  37. /*  FUNCTION
  38.     Frees a dos list entry created with MakeDosEntry().
  39.  
  40.     INPUTS
  41.     dlist - pointer to dos list entry. May be NULL.
  42.  
  43.     RESULT
  44.  
  45.     NOTES
  46.  
  47.     EXAMPLE
  48.  
  49.     BUGS
  50.  
  51.     SEE ALSO
  52.  
  53.     INTERNALS
  54.  
  55.     HISTORY
  56.     29-10-95    digulla automatically created from
  57.                 dos_lib.fd and clib/dos_protos.h
  58.  
  59. *****************************************************************************/
  60. {
  61.     AROS_LIBFUNC_INIT
  62.     AROS_LIBBASE_EXT_DECL(struct DosLibrary *,DOSBase)
  63.  
  64.     if(dlist!=NULL)
  65.     {
  66.     STRPTR s2;
  67.     s2=dlist->dol_DevName;
  68.     while(*s2++)
  69.        ;
  70.     FreeMem(dlist->dol_DevName-1,s2-dlist->dol_DevName+2);
  71.     FreeMem(dlist,sizeof(struct DosList));
  72.     }
  73.  
  74.     AROS_LIBFUNC_EXIT
  75. } /* FreeDosEntry */
  76.