home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c082_144 / 1.ddi / CLIBSRC.ZIP / DELF.CPP < prev    next >
Encoding:
C/C++ Source or Header  |  1992-06-10  |  623 b   |  28 lines

  1. /*-----------------------------------------------------------------------*
  2.  * filename - delf.cpp
  3.  * C++ DELETE
  4.  *-----------------------------------------------------------------------*/
  5.  
  6. /*
  7.  *      C/C++ Run Time Library - Version 5.0
  8.  *
  9.  *      Copyright (c) 1990, 1992 by Borland International
  10.  *      All Rights Reserved.
  11.  *
  12.  */
  13.  
  14.  
  15. #include <stddef.h>
  16. #include <alloc.h>
  17. #include <dos.h>
  18.  
  19. #if defined(__TINY__) || defined(__SMALL__) || defined(__MEDIUM__)
  20. void operator delete( void far *ptr )
  21. {
  22.     if (FP_SEG(ptr) == _DS)
  23.         free((void *) ptr);
  24.     else
  25.         farfree(ptr);
  26. }
  27. #endif
  28.