home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / GCC / GERLIB_USR08B.LHA / gerlib / support / blib / libgpp.a / remove.c next >
Encoding:
C/C++ Source or Header  |  1993-10-16  |  488 b   |  32 lines

  1. #ifdef amiga
  2.  
  3. #include <exec/types.h>
  4. #include <exec/ports.h>
  5. #include <exec/memory.h>
  6. #include <exec/execbase.h>
  7. #include <dos/dos.h>
  8. #include <dos/dosextens.h>
  9. #include <dos/exall.h>
  10. #include <inline/stubs.h>
  11. #ifdef __OPTIMIZE__
  12. #include <inline/dos.h>
  13. #else
  14. #include <clib/dos_protos.h>
  15. #endif
  16.  
  17. #endif
  18.  
  19. #include <stdioprivate.h>
  20.  
  21. int remove(const char* filename)
  22. {
  23. #ifdef amiga
  24.   if(!Delete ((STRPTR) filename))
  25. #else
  26.   if (unlink (filename) == -1)
  27. #endif
  28.    return -1;
  29.  
  30.   return 0;
  31. }
  32.