*** UNIX MANUAL PAGE BROWSER ***

A Nergahak database for man pages research.

Navigation

Directory Browser

1Browse 4.4BSD4.4BSD
1Browse Digital UNIXDigital UNIX 4.0e
1Browse FreeBSDFreeBSD 14.3
1Browse MINIXMINIX 3.4.0rc6-d5e4fc0
1Browse NetBSDNetBSD 10.1
1Browse OpenBSDOpenBSD 7.7
1Browse UNIX v7Version 7 UNIX
1Browse UNIX v10Version 10 UNIX

Manual Page Search

Manual Page Result

0 Command: dup | Section: 2 | Source: UNIX v10 | File: dup.2
DUP(2) System Calls Manual DUP(2) NAME dup, dup2 - duplicate an open file descriptor SYNOPSIS int dup(fildes) int fildes; int dup2(fildes, fildes2) int fildes, fildes2; DESCRIPTION Given a file descriptor dup allocates another file descriptor synony- mous with the original. The new file descriptor is returned. In dup2, fildes is a file descriptor referring to an open file, and fildes2 is an integer in the range of legal file descriptors. Dup2 causes fildes2 to refer to the same file and returns fildes2. If fildes2 already referred to another open file, it is closed first. SEE ALSO open(2), pipe(2), fd(4) DIAGNOSTICS EBADF, EMFILE BUGS Dup of a file descriptor greater than 63 turns into a dup2 with a ran- dom second argument. DUP(2)

Navigation Options