~vcs-imports/gawk/master

« back to all changes in this revision

Viewing changes to missing/dup2.c

  • Committer: Arnold D. Robbins
  • Date: 2010-07-16 08:58:26 UTC
  • Revision ID: git-v1:765c7494b3dac62207e6cd57fb839997e237f292
Moving to 2.13.2.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
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
}