466
|
1 <refentry id="dup">
|
|
2 <refnamediv>
|
468
|
3 <refname>Dup</refname>
|
|
4 <refpurpose>duplicate an open path number</refpurpose>
|
466
|
5 </refnamediv>
|
|
6
|
|
7 <refsynopsisdiv>
|
|
8 <funcsynopsis>
|
|
9 <funcprototype>
|
|
10 <funcdef><function>dup</function></funcdef>
|
541
|
11 <paramdef>int <parameter>pn</parameter></paramdef>
|
466
|
12 </funcprototype>
|
|
13 </funcsynopsis>
|
|
14
|
|
15 </refsynopsisdiv>
|
|
16
|
541
|
17 <refsect1><title>Assembler Equivalent</title>
|
|
18 <para>
|
|
19 os9 I$DUP
|
|
20 </para>
|
|
21 </refsect1>
|
466
|
22 <refsect1><title>Description</title>
|
|
23 <para>
|
541
|
24 Dup takes the path number, "pn", as returned from "open()" or
|
|
25 "creat()" and returns another path number associated with the
|
|
26 same file.
|
|
27 </para>
|
|
28 </refsect1>
|
|
29 <refsect1><title>Diagnostics</title>
|
|
30 <para>
|
|
31 A -1 is returned is the call fails because there are too many
|
|
32 files open or the path nmber is invalid.
|
|
33 </para>
|
|
34 </refsect1>
|
|
35 <refsect1><title>See Also</title>
|
|
36 <para>
|
|
37 <link linkend="open">open()</link>,
|
|
38 <link linkend="creat">creat()</link>,
|
|
39 <link linkend="close">close()</link>
|
466
|
40 </para>
|
|
41 </refsect1>
|
|
42 </refentry>
|