OSDN Git Service

(split) [JM:00125] Fix a translation mistake in isupper(3).
[linuxjm/LDP_man-pages.git] / release / man3 / ttyname.3
1 .\" Copyright (c) 1995 Jim Van Zandt <jrv@vanzandt.mv.com>
2 .\"
3 .\" This is free documentation; you can redistribute it and/or
4 .\" modify it under the terms of the GNU General Public License as
5 .\" published by the Free Software Foundation; either version 2 of
6 .\" the License, or (at your option) any later version.
7 .\"
8 .\" The GNU General Public License's references to "object code"
9 .\" and "executables" are to be interpreted as the output of any
10 .\" document formatting or typesetting system, including
11 .\" intermediate and printed output.
12 .\"
13 .\" This manual is distributed in the hope that it will be useful,
14 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
15 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 .\" GNU General Public License for more details.
17 .\"
18 .\" You should have received a copy of the GNU General Public
19 .\" License along with this manual; if not, write to the Free
20 .\" Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111,
21 .\" USA.
22 .\"
23 .\" Modified 2001-12-13, Martin Schulze <joey@infodrom.org>
24 .\" Added ttyname_r, aeb, 2002-07-20
25 .\"
26 .\" Japanese Version Copyright (c) 1997 Hiroaki Nagoya
27 .\"       all rights reserved.
28 .\" Translated Mon Feb 10 1997 by Hiroaki Nagoya <nagoya@is.titech.ac.jp>
29 .\" Updated Fri Dec 21 JST 2001 by Kentaro Shirakata <argrath@ub32.org>
30 .\" Updated Fri Oct 16 JST 2002 by Kentaro Shirakata <argrath@ub32.org>
31 .\"
32 .TH TTYNAME 3 2008-07-14 "Linux" "Linux Programmer's Manual"
33 .SH Ì¾Á°
34 ttyname, ttyname_r \- Ã¼Ëö̾¤òÊÖ¤¹
35 .SH ½ñ¼°
36 .nf
37 .B #include <unistd.h>
38 .sp
39 .BI "char *ttyname(int " fd );
40
41 .BI "int ttyname_r(int " fd ", char *" buf ", size_t " buflen );
42 .fi
43 .SH ÀâÌÀ
44 .BR ttyname ()
45 ´Ø¿ô¤Ï¡¢¥Õ¥¡¥¤¥ë¥Ç¥£¥¹¥¯¥ê¥×¥¿ \fIfd\fP ¤¬¥ª¡¼¥×¥ó¤·¤Æ¤¤¤ëüËö¥Ç¥Ð¥¤¥¹¤Î
46 NULL ½ªÃ¼¤µ¤ì¤¿¥Ñ¥¹Ì¾¤Ø¤Î¥Ý¥¤¥ó¥¿¤òÊÖ¤¹¡£
47 ¥¨¥é¡¼¤¬µ¯¤­¤¿¤Ê¤é¤Ð NULL ¤òÊÖ¤¹
48 (¤¿¤È¤¨¤Ð¡¢\fIfd\fP ¤¬Ã¼Ëö¤ò»²¾È¤·¤Æ¤¤¤Ê¤¤¤È¤­)¡£
49 ÊÖ¤êÃͤÏÀÅŪ¥Ç¡¼¥¿¤ò»Ø¤·¤Æ¤¤¤ë¤Î¤Ç¡¢¼¡¤Î¸Æ¤Ó½Ð¤·¤Ç¾å½ñ¤­¤µ¤ì¤ë²ÄǽÀ­¤¬¤¢¤ë¡£
50 .BR ttyname_r ()
51 ´Ø¿ô¤Ï¡¢¤³¤Î¥Ñ¥¹Ì¾¤òŤµ
52 .I buflen
53 ¤Î¥Ð¥Ã¥Õ¥¡
54 .I buf
55 ¤Ë³ÊǼ¤¹¤ë¡£
56 .SH ÊÖ¤êÃÍ
57 .BR ttyname ()
58 ´Ø¿ô¤Ï¡¢À®¸ù»þ¤Ï¥Ñ¥¹Ì¾¤Ø¤Î¥Ý¥¤¥ó¥¿¤òÊÖ¤¹¡£
59 ¥¨¥é¡¼»þ¤Ï NULL ¤òÊÖ¤·¡¢
60 .I errno
61 ¤¬Å¬ÀÚ¤ËÀßÄꤵ¤ì¤ë¡£
62 .BR ttyname_r ()
63 ´Ø¿ô¤Ï¡¢À®¸ù»þ¤Ë¤Ï 0 ¤òÊÖ¤·¡¢¥¨¥é¡¼»þ¤Ë¤Ï¥¨¥é¡¼ÈÖ¹æ¤òÊÖ¤¹¡£
64 .SH ¥¨¥é¡¼
65 .BR ttyname_r ():
66 .TP
67 .B EBADF
68 ¥Õ¥¡¥¤¥ë¥Ç¥£¥¹¥¯¥ê¥×¥¿¤¬ÉÔÀµ¡£
69 .TP
70 .B ENOTTY
71 ¥Õ¥¡¥¤¥ë¥Ç¥£¥¹¥¯¥ê¥×¥¿¤¬Ã¼Ëö¥Ç¥Ð¥¤¥¹¤ò¼¨¤·¤Æ¤¤¤Ê¤¤¡£
72 .TP
73 .B ERANGE
74 .I buflen
75 ¤¬¥Ñ¥¹Ì¾¤ò³ÊǼ¤¹¤ë¤Ë¤Ïû¤¹¤®¤ë¡£
76 .SH ½àµò
77 4.2BSD, POSIX.1-2001.
78 .SH ´ØÏ¢¹àÌÜ
79 .BR fstat (2),
80 .BR isatty (3)