home *** CD-ROM | disk | FTP | other *** search
/ Garbo / Garbo.cdr / mac / unix / gawk.sit / source / missing.d / dup2.c next >
Encoding:
C/C++ Source or Header  |  1990-08-20  |  136 b   |  13 lines  |  [TEXT/MPS ]

  1. #ifndef F_DUPFD
  2. #include <fcntl.h>
  3. #endif
  4.  
  5. int
  6. dup2 (old, new)
  7. int old, new;
  8. {
  9.     (void) close(new);
  10.  
  11.     return fcntl(old, F_DUPFD, new);
  12. }
  13.