OSDN Git Service

(split) LDP: Update POT and ja.po to LDP v3.51.
[linuxjm/LDP_man-pages.git] / po4a / stdio / po / ja.po
1 # SOME DESCRIPTIVE TITLE
2 # Copyright (C) YEAR Free Software Foundation, Inc.
3 # This file is distributed under the same license as the PACKAGE package.
4 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
5 #
6 msgid ""
7 msgstr ""
8 "Project-Id-Version: PACKAGE VERSION\n"
9 "POT-Creation-Date: 2013-04-30 20:30+0900\n"
10 "PO-Revision-Date: 2013-03-27 00:54+0900\n"
11 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
12 "Language-Team: LANGUAGE <LL@li.org>\n"
13 "Language: \n"
14 "MIME-Version: 1.0\n"
15 "Content-Type: text/plain; charset=UTF-8\n"
16 "Content-Transfer-Encoding: 8bit\n"
17
18 #. type: TH
19 #: build/C/man3/asprintf.3:27
20 #, no-wrap
21 msgid "ASPRINTF"
22 msgstr "ASPRINTF"
23
24 #. type: TH
25 #: build/C/man3/asprintf.3:27
26 #, no-wrap
27 msgid "2001-12-18"
28 msgstr "2001-12-18"
29
30 #. type: TH
31 #: build/C/man3/asprintf.3:27 build/C/man3/ctermid.3:26
32 #: build/C/man3/dprintf.3:26 build/C/man3/fclose.3:44
33 #: build/C/man3/fcloseall.3:25 build/C/man3/fflush.3:45
34 #: build/C/man3/fgetwc.3:18 build/C/man3/fmemopen.3:10 build/C/man3/fopen.3:44
35 #: build/C/man3/fputwc.3:16 build/C/man3/fread.3:45 build/C/man3/fseek.3:42
36 #: build/C/man3/getline.3:26 build/C/man3/gets.3:27 build/C/man3/getw.3:25
37 #: build/C/man3/popen.3:40 build/C/man3/printf.3:34 build/C/man3/puts.3:26
38 #: build/C/man3/remove.3:31 build/C/man3/scanf.3:52 build/C/man3/wprintf.3:16
39 #, no-wrap
40 msgid "GNU"
41 msgstr "GNU"
42
43 #. type: TH
44 #: build/C/man3/asprintf.3:27 build/C/man3/ctermid.3:26
45 #: build/C/man3/dprintf.3:26 build/C/man3/fclose.3:44
46 #: build/C/man3/fcloseall.3:25 build/C/man3/ferror.3:44
47 #: build/C/man3/fflush.3:45 build/C/man3/fgetwc.3:18
48 #: build/C/man3/flockfile.3:25 build/C/man3/fmemopen.3:10
49 #: build/C/man3/fmtmsg.3:13 build/C/man3/fopen.3:44
50 #: build/C/man3/fopencookie.3:26 build/C/man3/fpurge.3:25
51 #: build/C/man3/fputwc.3:16 build/C/man3/fread.3:45 build/C/man3/fseek.3:42
52 #: build/C/man3/fseeko.3:25 build/C/man3/getline.3:26 build/C/man3/gets.3:27
53 #: build/C/man3/getw.3:25 build/C/man2/link.2:31 build/C/man2/llseek.2:28
54 #: build/C/man2/lseek.2:47 build/C/man3/lseek64.3:25 build/C/man2/open.2:52
55 #: build/C/man3/perror.3:31 build/C/man2/pipe.2:36 build/C/man3/popen.3:40
56 #: build/C/man3/printf.3:34 build/C/man3/puts.3:26 build/C/man2/read.2:35
57 #: build/C/man2/readlink.2:43 build/C/man2/readv.2:32 build/C/man3/remove.3:31
58 #: build/C/man2/rename.2:32 build/C/man2/rmdir.2:30 build/C/man3/scanf.3:52
59 #: build/C/man3/setbuf.3:48 build/C/man3/stdin.3:13 build/C/man3/stdio.3:39
60 #: build/C/man3/stdio_ext.3:25 build/C/man2/symlink.2:32
61 #: build/C/man7/symlink.7:36 build/C/man3/tempnam.3:25
62 #: build/C/man3/tmpfile.3:31 build/C/man3/tmpnam.3:27 build/C/man2/unlink.2:32
63 #: build/C/man3/unlocked_stdio.3:25 build/C/man3/wprintf.3:16
64 #: build/C/man2/write.2:39
65 #, no-wrap
66 msgid "Linux Programmer's Manual"
67 msgstr "Linux Programmer's Manual"
68
69 #. type: SH
70 #: build/C/man3/asprintf.3:28 build/C/man3/ctermid.3:27
71 #: build/C/man3/dprintf.3:27 build/C/man3/fclose.3:45
72 #: build/C/man3/fcloseall.3:26 build/C/man3/ferror.3:45
73 #: build/C/man3/fflush.3:46 build/C/man3/fgetwc.3:19
74 #: build/C/man3/flockfile.3:26 build/C/man3/fmemopen.3:11
75 #: build/C/man3/fmtmsg.3:14 build/C/man3/fopen.3:45
76 #: build/C/man3/fopencookie.3:27 build/C/man3/fpurge.3:26
77 #: build/C/man3/fputwc.3:17 build/C/man3/fread.3:46 build/C/man3/fseek.3:43
78 #: build/C/man3/fseeko.3:26 build/C/man3/getline.3:27 build/C/man3/gets.3:28
79 #: build/C/man3/getw.3:26 build/C/man2/link.2:32 build/C/man2/llseek.2:29
80 #: build/C/man2/lseek.2:48 build/C/man3/lseek64.3:26 build/C/man2/open.2:53
81 #: build/C/man3/perror.3:32 build/C/man2/pipe.2:37 build/C/man3/popen.3:41
82 #: build/C/man3/printf.3:35 build/C/man3/puts.3:27 build/C/man2/read.2:36
83 #: build/C/man2/readlink.2:44 build/C/man2/readv.2:33 build/C/man3/remove.3:32
84 #: build/C/man2/rename.2:33 build/C/man2/rmdir.2:31 build/C/man3/scanf.3:53
85 #: build/C/man3/setbuf.3:49 build/C/man3/stdin.3:14 build/C/man3/stdio.3:40
86 #: build/C/man3/stdio_ext.3:26 build/C/man2/symlink.2:33
87 #: build/C/man7/symlink.7:37 build/C/man3/tempnam.3:26
88 #: build/C/man3/tmpfile.3:32 build/C/man3/tmpnam.3:28 build/C/man2/unlink.2:33
89 #: build/C/man3/unlocked_stdio.3:26 build/C/man3/wprintf.3:17
90 #: build/C/man2/write.2:40
91 #, no-wrap
92 msgid "NAME"
93 msgstr "名前"
94
95 #. type: Plain text
96 #: build/C/man3/asprintf.3:30
97 msgid "asprintf, vasprintf - print to allocated string"
98 msgstr "asprintf, vasprintf - 文字列を割り当ててそれに出力する"
99
100 #. type: SH
101 #: build/C/man3/asprintf.3:30 build/C/man3/ctermid.3:29
102 #: build/C/man3/dprintf.3:29 build/C/man3/fclose.3:47
103 #: build/C/man3/fcloseall.3:28 build/C/man3/ferror.3:47
104 #: build/C/man3/fflush.3:48 build/C/man3/fgetwc.3:21
105 #: build/C/man3/flockfile.3:28 build/C/man3/fmemopen.3:13
106 #: build/C/man3/fmtmsg.3:16 build/C/man3/fopen.3:47
107 #: build/C/man3/fopencookie.3:29 build/C/man3/fpurge.3:28
108 #: build/C/man3/fputwc.3:19 build/C/man3/fread.3:48 build/C/man3/fseek.3:45
109 #: build/C/man3/fseeko.3:28 build/C/man3/getline.3:29 build/C/man3/gets.3:30
110 #: build/C/man3/getw.3:28 build/C/man2/link.2:34 build/C/man2/llseek.2:31
111 #: build/C/man2/lseek.2:50 build/C/man3/lseek64.3:28 build/C/man2/open.2:55
112 #: build/C/man3/perror.3:34 build/C/man2/pipe.2:39 build/C/man3/popen.3:43
113 #: build/C/man3/printf.3:38 build/C/man3/puts.3:29 build/C/man2/read.2:38
114 #: build/C/man2/readlink.2:46 build/C/man2/readv.2:35 build/C/man3/remove.3:34
115 #: build/C/man2/rename.2:35 build/C/man2/rmdir.2:33 build/C/man3/scanf.3:55
116 #: build/C/man3/setbuf.3:51 build/C/man3/stdin.3:16 build/C/man3/stdio.3:42
117 #: build/C/man3/stdio_ext.3:30 build/C/man2/symlink.2:35
118 #: build/C/man3/tempnam.3:28 build/C/man3/tmpfile.3:34
119 #: build/C/man3/tmpnam.3:30 build/C/man2/unlink.2:35
120 #: build/C/man3/unlocked_stdio.3:29 build/C/man3/wprintf.3:20
121 #: build/C/man2/write.2:42
122 #, no-wrap
123 msgid "SYNOPSIS"
124 msgstr "書式"
125
126 #. type: Plain text
127 #: build/C/man3/asprintf.3:32
128 msgid "B<#define _GNU_SOURCE> /* See feature_test_macros(7) */"
129 msgstr "B<#define _GNU_SOURCE> /* feature_test_macros(7) 参照 */"
130
131 #. type: Plain text
132 #: build/C/man3/asprintf.3:34 build/C/man3/dprintf.3:31
133 #: build/C/man3/fclose.3:49 build/C/man3/ferror.3:49 build/C/man3/fflush.3:50
134 #: build/C/man3/fseek.3:47 build/C/man3/perror.3:36 build/C/man3/printf.3:40
135 #: build/C/man3/remove.3:36 build/C/man2/rename.2:37 build/C/man3/stdio.3:44
136 #: build/C/man3/stdio_ext.3:32
137 msgid "B<#include E<lt>stdio.hE<gt>>"
138 msgstr "B<#include E<lt>stdio.hE<gt>>"
139
140 #. type: Plain text
141 #: build/C/man3/asprintf.3:36
142 msgid "B<int asprintf(char **>I<strp>B<, const char *>I<fmt>B<, ...);>"
143 msgstr "B<int asprintf(char **>I<strp>B<, const char *>I<fmt>B<, ...);>"
144
145 #. type: Plain text
146 #: build/C/man3/asprintf.3:38
147 msgid ""
148 "B<int vasprintf(char **>I<strp>B<, const char *>I<fmt>B<, va_list >I<ap>B<);>"
149 msgstr ""
150 "B<int vasprintf(char **>I<strp>B<, const char *>I<fmt>B<, va_list >I<ap>B<);>"
151
152 #. type: SH
153 #: build/C/man3/asprintf.3:38 build/C/man3/ctermid.3:46
154 #: build/C/man3/dprintf.3:55 build/C/man3/fclose.3:51
155 #: build/C/man3/fcloseall.3:35 build/C/man3/ferror.3:65
156 #: build/C/man3/fflush.3:52 build/C/man3/fgetwc.3:30
157 #: build/C/man3/flockfile.3:51 build/C/man3/fmemopen.3:46
158 #: build/C/man3/fmtmsg.3:26 build/C/man3/fopen.3:65
159 #: build/C/man3/fopencookie.3:37 build/C/man3/fpurge.3:42
160 #: build/C/man3/fputwc.3:28 build/C/man3/fread.3:58 build/C/man3/fseek.3:57
161 #: build/C/man3/fseeko.3:37 build/C/man3/getline.3:58 build/C/man3/gets.3:46
162 #: build/C/man3/getw.3:59 build/C/man2/link.2:38 build/C/man2/llseek.2:43
163 #: build/C/man2/lseek.2:56 build/C/man3/lseek64.3:36 build/C/man2/open.2:66
164 #: build/C/man3/perror.3:55 build/C/man2/pipe.2:51 build/C/man3/popen.3:64
165 #: build/C/man3/printf.3:76 build/C/man3/puts.3:43 build/C/man2/read.2:44
166 #: build/C/man2/readlink.2:63 build/C/man2/readv.2:58 build/C/man3/remove.3:38
167 #: build/C/man2/rename.2:39 build/C/man2/rmdir.2:37 build/C/man3/scanf.3:87
168 #: build/C/man3/setbuf.3:73 build/C/man3/stdin.3:24 build/C/man3/stdio.3:50
169 #: build/C/man3/stdio_ext.3:54 build/C/man2/symlink.2:52
170 #: build/C/man3/tempnam.3:42 build/C/man3/tmpfile.3:40
171 #: build/C/man3/tmpnam.3:36 build/C/man2/unlink.2:39
172 #: build/C/man3/unlocked_stdio.3:106 build/C/man3/wprintf.3:60
173 #: build/C/man2/write.2:46
174 #, no-wrap
175 msgid "DESCRIPTION"
176 msgstr "説明"
177
178 #. type: Plain text
179 #: build/C/man3/asprintf.3:53
180 msgid ""
181 "The functions B<asprintf>()  and B<vasprintf>()  are analogs of B<sprintf>"
182 "(3)  and B<vsprintf>(3), except that they allocate a string large enough to "
183 "hold the output including the terminating null byte, and return a pointer to "
184 "it via the first argument.  This pointer should be passed to B<free>(3)  to "
185 "release the allocated storage when it is no longer needed."
186 msgstr ""
187 "B<asprintf>()  関数と B<vasprintf>()  関数とは、それぞれ B<sprintf>(3)  関数"
188 "と B<vsprintf>(3)  関数とに似ているが、 出力文字列を (終端の NULL バイトも含"
189 "めて)  保持するのに十分な大きさのメモリを確保し、 最初の引数にその文字列への"
190 "ポインタを返す。 このポインタは、不要になったら B<free>(3)  に渡し、割り当て"
191 "られた記憶領域を解放すべきである。"
192
193 #. type: SH
194 #: build/C/man3/asprintf.3:53 build/C/man3/ctermid.3:59
195 #: build/C/man3/fclose.3:59 build/C/man3/fcloseall.3:50
196 #: build/C/man3/fflush.3:74 build/C/man3/fgetwc.3:55
197 #: build/C/man3/flockfile.3:114 build/C/man3/fmemopen.3:176
198 #: build/C/man3/fmtmsg.3:152 build/C/man3/fopen.3:189
199 #: build/C/man3/fopencookie.3:238 build/C/man3/fpurge.3:58
200 #: build/C/man3/fputwc.3:54 build/C/man3/fread.3:83 build/C/man3/fseek.3:121
201 #: build/C/man3/fseeko.3:65 build/C/man3/getline.3:110 build/C/man3/gets.3:111
202 #: build/C/man3/getw.3:73 build/C/man2/link.2:52 build/C/man2/llseek.2:62
203 #: build/C/man2/lseek.2:162 build/C/man2/open.2:477 build/C/man2/pipe.2:92
204 #: build/C/man3/popen.3:123 build/C/man3/puts.3:84 build/C/man2/read.2:81
205 #: build/C/man2/readlink.2:77 build/C/man2/readv.2:177
206 #: build/C/man3/remove.3:60 build/C/man2/rename.2:91 build/C/man2/rmdir.2:40
207 #: build/C/man3/scanf.3:531 build/C/man3/setbuf.3:152
208 #: build/C/man2/symlink.2:84 build/C/man3/tempnam.3:87
209 #: build/C/man3/tmpfile.3:47 build/C/man3/tmpnam.3:70 build/C/man2/unlink.2:55
210 #: build/C/man3/wprintf.3:187 build/C/man2/write.2:89
211 #, no-wrap
212 msgid "RETURN VALUE"
213 msgstr "返り値"
214
215 #. type: Plain text
216 #: build/C/man3/asprintf.3:61
217 msgid ""
218 "When successful, these functions return the number of bytes printed, just "
219 "like B<sprintf>(3).  If memory allocation wasn't possible, or some other "
220 "error occurs, these functions will return -1, and the contents of I<strp> is "
221 "undefined."
222 msgstr ""
223 "成功すると、これらの関数は出力されたバイト数を (B<sprintf>(3)  のように) 返"
224 "す。 メモリの割り当てができなかったり、 その他エラーが生じると、 これらの関数"
225 "は -1 を返し、 I<strp> の内容は未定義となる。"
226
227 #. type: SH
228 #: build/C/man3/asprintf.3:61 build/C/man3/ctermid.3:61
229 #: build/C/man3/dprintf.3:69 build/C/man3/fclose.3:90
230 #: build/C/man3/fcloseall.3:55 build/C/man3/ferror.3:106
231 #: build/C/man3/fflush.3:93 build/C/man3/fgetwc.3:67
232 #: build/C/man3/flockfile.3:121 build/C/man3/fmemopen.3:195
233 #: build/C/man3/fmtmsg.3:225 build/C/man3/fopen.3:246
234 #: build/C/man3/fopencookie.3:245 build/C/man3/fpurge.3:70
235 #: build/C/man3/fputwc.3:65 build/C/man3/fread.3:103 build/C/man3/fseek.3:168
236 #: build/C/man3/fseeko.3:77 build/C/man3/getline.3:134 build/C/man3/gets.3:138
237 #: build/C/man3/getw.3:80 build/C/man2/link.2:138 build/C/man2/llseek.2:81
238 #: build/C/man2/lseek.2:200 build/C/man2/open.2:629 build/C/man3/perror.3:111
239 #: build/C/man2/pipe.2:118 build/C/man3/popen.3:169 build/C/man3/printf.3:806
240 #: build/C/man3/puts.3:103 build/C/man2/read.2:173 build/C/man2/readlink.2:125
241 #: build/C/man2/readv.2:214 build/C/man3/remove.3:70 build/C/man2/rename.2:232
242 #: build/C/man2/rmdir.2:127 build/C/man3/scanf.3:578 build/C/man3/setbuf.3:164
243 #: build/C/man3/stdin.3:113 build/C/man3/stdio.3:246
244 #: build/C/man2/symlink.2:149 build/C/man3/tempnam.3:96
245 #: build/C/man3/tmpfile.3:76 build/C/man3/tmpnam.3:77
246 #: build/C/man2/unlink.2:141 build/C/man3/unlocked_stdio.3:113
247 #: build/C/man3/wprintf.3:195 build/C/man2/write.2:185
248 #, no-wrap
249 msgid "CONFORMING TO"
250 msgstr "準拠"
251
252 #. type: Plain text
253 #: build/C/man3/asprintf.3:67
254 msgid ""
255 "These functions are GNU extensions, not in C or POSIX.  They are also "
256 "available under *BSD.  The FreeBSD implementation sets I<strp> to NULL on "
257 "error."
258 msgstr ""
259 "これらの関数は GNU の拡張であり、C や POSIX のものではない。 これらは *BSD で"
260 "も利用できる。 FreeBSD の実装では、エラーの際には I<strp> を NULL にセットす"
261 "る。"
262
263 #. type: SH
264 #: build/C/man3/asprintf.3:67 build/C/man3/ctermid.3:71
265 #: build/C/man3/dprintf.3:95 build/C/man3/fclose.3:102
266 #: build/C/man3/fcloseall.3:57 build/C/man3/ferror.3:113
267 #: build/C/man3/fflush.3:108 build/C/man3/fgetwc.3:84
268 #: build/C/man3/flockfile.3:129 build/C/man3/fmemopen.3:341
269 #: build/C/man3/fmtmsg.3:297 build/C/man3/fopen.3:348
270 #: build/C/man3/fopencookie.3:437 build/C/man3/fpurge.3:80
271 #: build/C/man3/fputwc.3:82 build/C/man3/fread.3:105 build/C/man3/fseek.3:170
272 #: build/C/man3/fseeko.3:83 build/C/man3/getline.3:168 build/C/man3/gets.3:173
273 #: build/C/man3/getw.3:86 build/C/man2/link.2:187 build/C/man2/llseek.2:87
274 #: build/C/man2/lseek.2:245 build/C/man3/lseek64.3:159 build/C/man2/open.2:901
275 #: build/C/man3/perror.3:139 build/C/man2/pipe.2:190 build/C/man3/popen.3:198
276 #: build/C/man3/printf.3:1080 build/C/man3/puts.3:112 build/C/man2/read.2:187
277 #: build/C/man2/readlink.2:214 build/C/man2/readv.2:284
278 #: build/C/man3/remove.3:81 build/C/man2/rename.2:245 build/C/man2/rmdir.2:132
279 #: build/C/man3/scanf.3:716 build/C/man3/setbuf.3:200 build/C/man3/stdin.3:154
280 #: build/C/man3/stdio.3:250 build/C/man3/stdio_ext.3:132
281 #: build/C/man2/symlink.2:164 build/C/man7/symlink.7:471
282 #: build/C/man3/tempnam.3:166 build/C/man3/tmpfile.3:88
283 #: build/C/man3/tmpnam.3:153 build/C/man2/unlink.2:148
284 #: build/C/man3/unlocked_stdio.3:136 build/C/man3/wprintf.3:231
285 #: build/C/man2/write.2:211
286 #, no-wrap
287 msgid "SEE ALSO"
288 msgstr "関連項目"
289
290 #. type: Plain text
291 #: build/C/man3/asprintf.3:71
292 msgid "B<free>(3), B<malloc>(3), B<printf>(3)"
293 msgstr "B<free>(3), B<malloc>(3), B<printf>(3)"
294
295 #. type: SH
296 #: build/C/man3/asprintf.3:71 build/C/man3/ctermid.3:73
297 #: build/C/man3/dprintf.3:97 build/C/man3/fclose.3:108
298 #: build/C/man3/fcloseall.3:63 build/C/man3/ferror.3:118
299 #: build/C/man3/fflush.3:116 build/C/man3/fgetwc.3:89
300 #: build/C/man3/flockfile.3:131 build/C/man3/fmemopen.3:344
301 #: build/C/man3/fmtmsg.3:300 build/C/man3/fopen.3:354
302 #: build/C/man3/fopencookie.3:442 build/C/man3/fpurge.3:85
303 #: build/C/man3/fputwc.3:86 build/C/man3/fread.3:111 build/C/man3/fseek.3:173
304 #: build/C/man3/fseeko.3:85 build/C/man3/getline.3:175 build/C/man3/gets.3:189
305 #: build/C/man3/getw.3:92 build/C/man2/link.2:197 build/C/man2/llseek.2:90
306 #: build/C/man2/lseek.2:252 build/C/man3/lseek64.3:162 build/C/man2/open.2:923
307 #: build/C/man3/perror.3:144 build/C/man2/pipe.2:197 build/C/man3/popen.3:208
308 #: build/C/man3/printf.3:1089 build/C/man3/puts.3:124 build/C/man2/read.2:200
309 #: build/C/man2/readlink.2:222 build/C/man2/readv.2:288
310 #: build/C/man3/remove.3:92 build/C/man2/rename.2:254 build/C/man2/rmdir.2:141
311 #: build/C/man3/scanf.3:723 build/C/man3/setbuf.3:208 build/C/man3/stdin.3:160
312 #: build/C/man3/stdio.3:257 build/C/man3/stdio_ext.3:135
313 #: build/C/man2/symlink.2:176 build/C/man7/symlink.7:489
314 #: build/C/man3/tempnam.3:171 build/C/man3/tmpfile.3:94
315 #: build/C/man3/tmpnam.3:158 build/C/man2/unlink.2:161
316 #: build/C/man3/unlocked_stdio.3:139 build/C/man3/wprintf.3:238
317 #: build/C/man2/write.2:223
318 #, no-wrap
319 msgid "COLOPHON"
320 msgstr "この文書について"
321
322 #. type: Plain text
323 #: build/C/man3/asprintf.3:78 build/C/man3/ctermid.3:80
324 #: build/C/man3/dprintf.3:104 build/C/man3/fclose.3:115
325 #: build/C/man3/fcloseall.3:70 build/C/man3/ferror.3:125
326 #: build/C/man3/fflush.3:123 build/C/man3/fgetwc.3:96
327 #: build/C/man3/flockfile.3:138 build/C/man3/fmemopen.3:351
328 #: build/C/man3/fmtmsg.3:307 build/C/man3/fopen.3:361
329 #: build/C/man3/fopencookie.3:449 build/C/man3/fpurge.3:92
330 #: build/C/man3/fputwc.3:93 build/C/man3/fread.3:118 build/C/man3/fseek.3:180
331 #: build/C/man3/fseeko.3:92 build/C/man3/getline.3:182 build/C/man3/gets.3:196
332 #: build/C/man3/getw.3:99 build/C/man2/link.2:204 build/C/man2/llseek.2:97
333 #: build/C/man2/lseek.2:259 build/C/man3/lseek64.3:169 build/C/man2/open.2:930
334 #: build/C/man3/perror.3:151 build/C/man2/pipe.2:204 build/C/man3/popen.3:215
335 #: build/C/man3/printf.3:1096 build/C/man3/puts.3:131 build/C/man2/read.2:207
336 #: build/C/man2/readlink.2:229 build/C/man2/readv.2:295
337 #: build/C/man3/remove.3:99 build/C/man2/rename.2:261 build/C/man2/rmdir.2:148
338 #: build/C/man3/scanf.3:730 build/C/man3/setbuf.3:215 build/C/man3/stdin.3:167
339 #: build/C/man3/stdio.3:264 build/C/man3/stdio_ext.3:142
340 #: build/C/man2/symlink.2:183 build/C/man7/symlink.7:496
341 #: build/C/man3/tempnam.3:178 build/C/man3/tmpfile.3:101
342 #: build/C/man3/tmpnam.3:165 build/C/man2/unlink.2:168
343 #: build/C/man3/unlocked_stdio.3:146 build/C/man3/wprintf.3:245
344 #: build/C/man2/write.2:230
345 #, fuzzy
346 #| msgid ""
347 #| "This page is part of release 3.50 of the Linux I<man-pages> project.  A "
348 #| "description of the project, and information about reporting bugs, can be "
349 #| "found at http://www.kernel.org/doc/man-pages/."
350 msgid ""
351 "This page is part of release 3.51 of the Linux I<man-pages> project.  A "
352 "description of the project, and information about reporting bugs, can be "
353 "found at http://www.kernel.org/doc/man-pages/."
354 msgstr ""
355 "この man ページは Linux I<man-pages> プロジェクトのリリース 3.50 の一部\n"
356 "である。プロジェクトの説明とバグ報告に関する情報は\n"
357 "http://www.kernel.org/doc/man-pages/ に書かれている。"
358
359 #. type: TH
360 #: build/C/man3/ctermid.3:26
361 #, no-wrap
362 msgid "CTERMID"
363 msgstr "CTERMID"
364
365 #. type: TH
366 #: build/C/man3/ctermid.3:26
367 #, no-wrap
368 msgid "2007-07-26"
369 msgstr "2007-07-26"
370
371 #. type: Plain text
372 #: build/C/man3/ctermid.3:29
373 msgid "ctermid - get controlling terminal name"
374 msgstr "ctermid - 制御端末名の取得"
375
376 #. type: Plain text
377 #: build/C/man3/ctermid.3:34 build/C/man3/fgetwc.3:24
378 #: build/C/man3/flockfile.3:31 build/C/man3/fmemopen.3:16
379 #: build/C/man3/fopen.3:50 build/C/man3/fputwc.3:22 build/C/man3/fread.3:51
380 #: build/C/man3/fseeko.3:31 build/C/man3/getline.3:32 build/C/man3/gets.3:33
381 #: build/C/man3/getw.3:31 build/C/man3/popen.3:46 build/C/man3/puts.3:32
382 #: build/C/man3/scanf.3:58 build/C/man3/setbuf.3:54 build/C/man3/stdin.3:19
383 #: build/C/man3/tempnam.3:31 build/C/man3/tmpfile.3:37
384 #: build/C/man3/tmpnam.3:33 build/C/man3/unlocked_stdio.3:32
385 #, no-wrap
386 msgid "B<#include E<lt>stdio.hE<gt>>\n"
387 msgstr "B<#include E<lt>stdio.hE<gt>>\n"
388
389 #. type: Plain text
390 #: build/C/man3/ctermid.3:36
391 #, no-wrap
392 msgid "B<char *ctermid(char *>I<s>B<);>\n"
393 msgstr "B<char *ctermid(char *>I<s>B<);>\n"
394
395 #. type: Plain text
396 #: build/C/man3/ctermid.3:41 build/C/man3/dprintf.3:39
397 #: build/C/man3/ferror.3:61 build/C/man3/flockfile.3:42
398 #: build/C/man3/fmemopen.3:29 build/C/man3/fopen.3:61
399 #: build/C/man3/getline.3:42 build/C/man3/getw.3:40 build/C/man3/perror.3:50
400 #: build/C/man3/popen.3:55 build/C/man3/printf.3:63 build/C/man2/readlink.2:54
401 #: build/C/man2/readv.2:53 build/C/man3/scanf.3:73 build/C/man3/setbuf.3:68
402 #: build/C/man2/symlink.2:43 build/C/man3/tempnam.3:38
403 #: build/C/man3/unlocked_stdio.3:68 build/C/man3/wprintf.3:39
404 msgid ""
405 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
406 msgstr "glibc 向けの機能検査マクロの要件 (B<feature_test_macros>(7)  参照):"
407
408 #.  From <unistd.h>: _XOPEN_SOURCE
409 #. type: Plain text
410 #: build/C/man3/ctermid.3:46
411 msgid ""
412 "B<ctermid>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
413 msgstr ""
414 "B<ctermid>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
415
416 #. type: Plain text
417 #: build/C/man3/ctermid.3:59
418 msgid ""
419 "B<ctermid>()  returns a string which is the pathname for the current "
420 "controlling terminal for this process.  If I<s> is NULL, a static buffer is "
421 "used, otherwise I<s> points to a buffer used to hold the terminal pathname.  "
422 "The symbolic constant B<L_ctermid> is the maximum number of characters in "
423 "the returned pathname."
424 msgstr ""
425 "B<ctermid>()  はプロセスの現在の制御端末のパス名を返す。 I<s> が NULL の場"
426 "合、静的なバッファを用いる。それ以外の場合、 I<s> は端末パス名を保持するのに"
427 "使用されるバッファへのポインタとなる。 シンボル定数 B<L_ctermid> は返されるパ"
428 "ス名の最大文字数である。"
429
430 #. type: Plain text
431 #: build/C/man3/ctermid.3:61
432 msgid "The pointer to the pathname."
433 msgstr "パス名へのポインタ。"
434
435 #. type: Plain text
436 #: build/C/man3/ctermid.3:63
437 msgid "Svr4, POSIX.1-2001."
438 msgstr "SVr4, POSIX.1-2001."
439
440 #. type: SH
441 #: build/C/man3/ctermid.3:63 build/C/man3/fmemopen.3:213
442 #: build/C/man3/fopen.3:331 build/C/man3/gets.3:152 build/C/man3/getw.3:82
443 #: build/C/man2/link.2:181 build/C/man2/open.2:890 build/C/man3/popen.3:175
444 #: build/C/man3/printf.3:929 build/C/man3/puts.3:105 build/C/man2/readv.2:258
445 #: build/C/man3/remove.3:78 build/C/man2/rename.2:234 build/C/man2/rmdir.2:129
446 #: build/C/man3/scanf.3:647 build/C/man3/setbuf.3:170
447 #: build/C/man3/tempnam.3:156 build/C/man3/tmpnam.3:146
448 #: build/C/man2/unlink.2:145
449 #, no-wrap
450 msgid "BUGS"
451 msgstr "バグ"
452
453 #. type: Plain text
454 #: build/C/man3/ctermid.3:67
455 msgid ""
456 "The path returned may not uniquely identify the controlling terminal; it "
457 "may, for example, be I</dev/tty>."
458 msgstr ""
459 "返されたパスはたぶん制御端末を一意には特定できない。 たとえば I</dev/tty> の"
460 "ように。"
461
462 #.  in glibc 2.3.x, x >= 4, the glibc headers threw an error
463 #.  if ctermid() was given an argument; fixed in 2.4.
464 #. type: Plain text
465 #: build/C/man3/ctermid.3:71
466 msgid "It is not assured that the program can open the terminal."
467 msgstr "プログラムが端末をオープンできることは保証されていない。"
468
469 #. type: Plain text
470 #: build/C/man3/ctermid.3:73
471 msgid "B<ttyname>(3)"
472 msgstr "B<ttyname>(3)"
473
474 #. type: TH
475 #: build/C/man3/dprintf.3:26
476 #, no-wrap
477 msgid "DPRINTF"
478 msgstr "DPRINTF"
479
480 #. type: TH
481 #: build/C/man3/dprintf.3:26
482 #, no-wrap
483 msgid "2010-09-15"
484 msgstr "2010-09-15"
485
486 #. type: Plain text
487 #: build/C/man3/dprintf.3:29
488 msgid "dprintf, vdprintf - print to a file descriptor"
489 msgstr "dprintf, vdprintf - ファイルディスクリプタに文字出力する"
490
491 #. type: Plain text
492 #: build/C/man3/dprintf.3:33
493 msgid "B<int dprintf(int >I<fd>B<, const char *>I<format>B<, ...);>"
494 msgstr "B<int dprintf(int >I<fd>B<, const char *>I<format>B<, ...);>"
495
496 #. type: Plain text
497 #: build/C/man3/dprintf.3:35
498 msgid ""
499 "B<int vdprintf(int >I<fd>B<, const char *>I<format>B<, va_list >I<ap>B<);>"
500 msgstr ""
501 "B<int vdprintf(int >I<fd>B<, const char *>I<format>B<, va_list >I<ap>B<);>"
502
503 #. type: Plain text
504 #: build/C/man3/dprintf.3:43
505 msgid "B<dprintf>(), B<vdprintf>():"
506 msgstr "B<dprintf>(), B<vdprintf>():"
507
508 #. type: TP
509 #: build/C/man3/dprintf.3:46 build/C/man3/fmemopen.3:37
510 #: build/C/man3/getline.3:49
511 #, no-wrap
512 msgid "Since glibc 2.10:"
513 msgstr "glibc 2.10 以降:"
514
515 #. type: Plain text
516 #: build/C/man3/dprintf.3:49 build/C/man3/fmemopen.3:40
517 msgid "_XOPEN_SOURCE\\ E<gt>=\\ 700 || _POSIX_C_SOURCE\\ E<gt>=\\ 200809L"
518 msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 700 || _POSIX_C_SOURCE\\ E<gt>=\\ 200809L"
519
520 #. type: TP
521 #: build/C/man3/dprintf.3:49 build/C/man3/fmemopen.3:40
522 #: build/C/man3/getline.3:52
523 #, no-wrap
524 msgid "Before glibc 2.10:"
525 msgstr "glibc 2.10 より前:"
526
527 #. type: Plain text
528 #: build/C/man3/dprintf.3:52 build/C/man3/fmemopen.3:43
529 #: build/C/man3/getline.3:55 build/C/man3/unlocked_stdio.3:104
530 msgid "_GNU_SOURCE"
531 msgstr "_GNU_SOURCE"
532
533 #. type: Plain text
534 #: build/C/man3/dprintf.3:69
535 msgid ""
536 "The functions B<dprintf>()  and B<vdprintf>()  (as found in the glibc2 "
537 "library) are exact analogs of B<fprintf>(3)  and B<vfprintf>(3), except that "
538 "they output to a file descriptor I<fd> instead of to a I<stdio> stream."
539 msgstr ""
540 "(glibc2 ライブラリにおける)  B<dprintf>()  関数と B<vdprintf>()  関数とは、そ"
541 "れぞれ B<fprintf>(3)  関数と B<vfprintf>(3)  関数とにちょうど対応するが、 こ"
542 "れらは I<stdio> ストリームではなくファイルディスクリプタ I<fd> に対して出力を"
543 "行う。"
544
545 #.  .SH NOTES
546 #.  These functions are GNU extensions, not in C or POSIX.
547 #.  Clearly, the names were badly chosen.
548 #.  Many systems (like MacOS) have incompatible functions called
549 #.  .BR dprintf (),
550 #.  usually some debugging version of
551 #.  .BR printf (3),
552 #.  perhaps with a prototype like
553 #.  .BI "void dprintf(int level, const char *" format ", ...);"
554 #.  where the first argument is a debugging level (and output is to
555 #.  .IR stderr ).
556 #.  Moreover,
557 #.  .BR dprintf ()
558 #.  (or
559 #.  .BR DPRINTF )
560 #.  is also a popular macro name for a debugging printf.
561 #.  So, probably, it is better to avoid this function in programs
562 #.  intended to be portable.
563 #.  A better name would have been
564 #.  .BR fdprintf ().
565 #. type: Plain text
566 #: build/C/man3/dprintf.3:95
567 msgid ""
568 "These functions are GNU extensions that are nowadays specified in "
569 "POSIX.1-2008."
570 msgstr ""
571 "これらの関数は GNU による拡張であり、 現在では POSIX.1-2008 で規定されてい"
572 "る。"
573
574 #. type: Plain text
575 #: build/C/man3/dprintf.3:97
576 msgid "B<printf>(3)"
577 msgstr "B<printf>(3)"
578
579 #. type: TH
580 #: build/C/man3/fclose.3:44
581 #, no-wrap
582 msgid "FCLOSE"
583 msgstr "FCLOSE"
584
585 #. type: TH
586 #: build/C/man3/fclose.3:44
587 #, no-wrap
588 msgid "2009-02-23"
589 msgstr "2009-02-23"
590
591 #. type: Plain text
592 #: build/C/man3/fclose.3:47
593 msgid "fclose - close a stream"
594 msgstr "fclose - ストリームを閉じる"
595
596 #. type: Plain text
597 #: build/C/man3/fclose.3:51
598 msgid "B<int fclose(FILE *>I<fp>B<);>"
599 msgstr "B<int fclose(FILE *>I<fp>B<);>"
600
601 #. type: Plain text
602 #: build/C/man3/fclose.3:59
603 msgid ""
604 "The B<fclose>()  function flushes the stream pointed to by I<fp> (writing "
605 "any buffered output data using B<fflush>(3))  and closes the underlying file "
606 "descriptor."
607 msgstr ""
608 "B<fclose>() 関数は、 I<fp> が指すストリームを (バッファリングされて\n"
609 "いた全ての出力データを B<fflush>(3) を用いて書き込んで) フラッシュし、\n"
610 "対応するファイルディスクリプタをクローズする。"
611
612 #. type: Plain text
613 #: build/C/man3/fclose.3:70
614 msgid ""
615 "Upon successful completion 0 is returned.  Otherwise, B<EOF> is returned and "
616 "I<errno> is set to indicate the error.  In either case any further access "
617 "(including another call to B<fclose>())  to the stream results in undefined "
618 "behavior."
619 msgstr ""
620 "関数が正常に終了すると 0 が返される。 正常に終了しなかった場合には B<EOF> が"
621 "返され、 I<errno> がエラーを示すために設定される。 どちらの場合も、そのスト"
622 "リームに対する (B<fclose>()  へのさらなる呼び出しを含む) それ以上のアクセス"
623 "は 未定義の動作を生じさせる。"
624
625 #. type: SH
626 #: build/C/man3/fclose.3:70 build/C/man3/ferror.3:96 build/C/man3/fflush.3:81
627 #: build/C/man3/fgetwc.3:61 build/C/man3/flockfile.3:119
628 #: build/C/man3/fopen.3:201 build/C/man3/fpurge.3:65 build/C/man3/fputwc.3:60
629 #: build/C/man3/fseek.3:136 build/C/man3/fseeko.3:74
630 #: build/C/man3/getline.3:122 build/C/man2/link.2:57 build/C/man2/llseek.2:69
631 #: build/C/man2/lseek.2:170 build/C/man2/open.2:485 build/C/man2/pipe.2:97
632 #: build/C/man3/popen.3:143 build/C/man2/read.2:95 build/C/man2/readlink.2:85
633 #: build/C/man2/readv.2:188 build/C/man3/remove.3:65 build/C/man2/rename.2:96
634 #: build/C/man2/rmdir.2:45 build/C/man3/scanf.3:548 build/C/man2/symlink.2:89
635 #: build/C/man3/tempnam.3:92 build/C/man3/tmpfile.3:54
636 #: build/C/man3/tmpnam.3:75 build/C/man2/unlink.2:60 build/C/man2/write.2:107
637 #, no-wrap
638 msgid "ERRORS"
639 msgstr "エラー"
640
641 #. type: TP
642 #: build/C/man3/fclose.3:71 build/C/man3/fflush.3:82 build/C/man3/fpurge.3:66
643 #: build/C/man3/fseek.3:137 build/C/man2/llseek.2:70 build/C/man2/lseek.2:171
644 #: build/C/man2/read.2:114 build/C/man3/scanf.3:554 build/C/man2/write.2:126
645 #, no-wrap
646 msgid "B<EBADF>"
647 msgstr "B<EBADF>"
648
649 #.   This error cannot occur unless you are mixing ANSI C stdio operations and
650 #.   low-level file operations on the same stream. If you do get this error,
651 #.   you must have closed the stream's low-level file descriptor using
652 #.   something like close(fileno(fp)).
653 #. type: Plain text
654 #: build/C/man3/fclose.3:80
655 msgid "The file descriptor underlying I<fp> is not valid."
656 msgstr "I<fp> の基となるファイルディスクリプタが不正である。"
657
658 #. type: Plain text
659 #: build/C/man3/fclose.3:90
660 msgid ""
661 "The B<fclose>()  function may also fail and set I<errno> for any of the "
662 "errors specified for the routines B<close>(2), B<write>(2)  or B<fflush>(3)."
663 msgstr ""
664 "B<fclose>()  関数はこれ以外にも B<close>(2), B<write>(2), B<fflush>(3)  の"
665 "ルーチンで失敗することがある。その場合は I<errno> が、失敗したルーチンで設定"
666 "された値に設定される。"
667
668 #. type: Plain text
669 #: build/C/man3/fclose.3:92 build/C/man3/fseek.3:170 build/C/man3/puts.3:105
670 msgid "C89, C99."
671 msgstr "C89, C99."
672
673 #. type: SH
674 #: build/C/man3/fclose.3:92 build/C/man3/fflush.3:99 build/C/man3/fgetwc.3:69
675 #: build/C/man3/fmemopen.3:207 build/C/man3/fmtmsg.3:240
676 #: build/C/man3/fopen.3:255 build/C/man3/fpurge.3:78 build/C/man3/fputwc.3:67
677 #: build/C/man3/fseeko.3:79 build/C/man2/link.2:143 build/C/man2/llseek.2:84
678 #: build/C/man2/lseek.2:210 build/C/man2/open.2:655 build/C/man3/perror.3:124
679 #: build/C/man3/printf.3:867 build/C/man2/read.2:175
680 #: build/C/man2/readlink.2:130 build/C/man2/readv.2:226
681 #: build/C/man3/remove.3:72 build/C/man3/scanf.3:609 build/C/man3/stdin.3:122
682 #: build/C/man2/symlink.2:155 build/C/man3/tempnam.3:101
683 #: build/C/man3/tmpfile.3:78 build/C/man3/tmpnam.3:82
684 #: build/C/man3/wprintf.3:197 build/C/man2/write.2:194
685 #, no-wrap
686 msgid "NOTES"
687 msgstr "注意"
688
689 #. type: Plain text
690 #: build/C/man3/fclose.3:102
691 msgid ""
692 "Note that B<fclose>()  only flushes the user-space buffers provided by the C "
693 "library.  To ensure that the data is physically stored on disk the kernel "
694 "buffers must be flushed too, for example, with B<sync>(2)  or B<fsync>(2)."
695 msgstr ""
696 "B<fclose>()  は C ライブラリで提供されたユーザー空間バッファをフラッシュする"
697 "だけで ある点に注意すること。 データを確実に物理的にディスクに記録するために"
698 "は カーネルバッファも (B<sync>(2)  や B<fsync>(2)  を用いて) フラッシュしなけ"
699 "ればならない。"
700
701 #. type: Plain text
702 #: build/C/man3/fclose.3:108
703 msgid "B<close>(2), B<fcloseall>(3), B<fflush>(3), B<fopen>(3), B<setbuf>(3)"
704 msgstr "B<close>(2), B<fcloseall>(3), B<fflush>(3), B<fopen>(3), B<setbuf>(3)"
705
706 #. type: TH
707 #: build/C/man3/fcloseall.3:25
708 #, no-wrap
709 msgid "FCLOSEALL"
710 msgstr "FCLOSEALL"
711
712 #. type: TH
713 #: build/C/man3/fcloseall.3:25
714 #, no-wrap
715 msgid "2006-12-27"
716 msgstr "2006-12-27"
717
718 #. type: Plain text
719 #: build/C/man3/fcloseall.3:28
720 msgid "fcloseall - close all open streams"
721 msgstr "fcloseall - 開いているすべてのストリームを閉じる"
722
723 #. type: Plain text
724 #: build/C/man3/fcloseall.3:32 build/C/man3/fopencookie.3:33
725 #, no-wrap
726 msgid ""
727 "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
728 "B<#include E<lt>stdio.hE<gt>>\n"
729 msgstr ""
730 "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
731 "B<#include E<lt>stdio.hE<gt>>\n"
732
733 #. type: Plain text
734 #: build/C/man3/fcloseall.3:34
735 #, no-wrap
736 msgid "B<int fcloseall(void);>\n"
737 msgstr "B<int fcloseall(void);>\n"
738
739 #. type: Plain text
740 #: build/C/man3/fcloseall.3:43
741 msgid ""
742 "The B<fcloseall>()  function closes all of the calling process's open "
743 "streams.  Buffered output for each stream is written before it is closed (as "
744 "for B<fflush>(3)); buffered input is discarded."
745 msgstr ""
746 "B<fcloseall>()  関数は、呼び出し元プロセスが開いているすべてのストリームを閉"
747 "じる。 ストリームを閉じる前に、 (B<fflush>(3)  と同じように) 各ストリームの"
748 "バッファに溜っている出力データは書き出される。 入力バッファ内のデータは破棄さ"
749 "れる。"
750
751 #. type: Plain text
752 #: build/C/man3/fcloseall.3:50
753 msgid ""
754 "The standard streams, I<stdin>, I<stdout>, and I<stderr> are also closed."
755 msgstr "標準入出力 I<stdin>, I<stdout>, I<stderr> も閉じられる。"
756
757 #. type: Plain text
758 #: build/C/man3/fcloseall.3:55
759 msgid ""
760 "This function returns 0 if all files were successfully closed; on error, "
761 "B<EOF> is returned."
762 msgstr ""
763 "この関数は、すべてのファイルが正常に閉じられた場合 0 を返す。 エラーの場合、 "
764 "B<EOF> を返す。"
765
766 #. type: Plain text
767 #: build/C/man3/fcloseall.3:57
768 msgid "This function is a GNU extension."
769 msgstr "この関数は GNU 拡張である。"
770
771 #. type: Plain text
772 #: build/C/man3/fcloseall.3:63
773 msgid "B<close>(2), B<fclose>(3), B<fflush>(3), B<fopen>(3), B<setbuf>(3)"
774 msgstr "B<close>(2), B<fclose>(3), B<fflush>(3), B<fopen>(3), B<setbuf>(3)"
775
776 #. type: TH
777 #: build/C/man3/ferror.3:44
778 #, no-wrap
779 msgid "FERROR"
780 msgstr "FERROR"
781
782 #. type: TH
783 #: build/C/man3/ferror.3:44 build/C/man3/flockfile.3:25
784 #: build/C/man3/unlocked_stdio.3:25
785 #, no-wrap
786 msgid "2008-08-29"
787 msgstr "2008-08-29"
788
789 #. type: Plain text
790 #: build/C/man3/ferror.3:47
791 msgid "clearerr, feof, ferror, fileno - check and reset stream status"
792 msgstr ""
793 "clearerr, feof, ferror, fileno - ストリームステータスのチェックとリセット"
794
795 #. type: Plain text
796 #: build/C/man3/ferror.3:51
797 msgid "B<void clearerr(FILE *>I<stream>B<);>"
798 msgstr "B<void clearerr(FILE *>I<stream>B<);>"
799
800 #. type: Plain text
801 #: build/C/man3/ferror.3:53
802 msgid "B<int feof(FILE *>I<stream>B<);>"
803 msgstr "B<int feof(FILE *>I<stream>B<);>"
804
805 #. type: Plain text
806 #: build/C/man3/ferror.3:55
807 msgid "B<int ferror(FILE *>I<stream>B<);>"
808 msgstr "B<int ferror(FILE *>I<stream>B<);>"
809
810 #. type: Plain text
811 #: build/C/man3/ferror.3:57
812 msgid "B<int fileno(FILE *>I<stream>B<);>"
813 msgstr "B<int fileno(FILE *>I<stream>B<);>"
814
815 #. type: Plain text
816 #: build/C/man3/ferror.3:65
817 msgid ""
818 "B<fileno>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
819 msgstr ""
820 "B<fileno>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
821
822 #. type: Plain text
823 #: build/C/man3/ferror.3:70
824 msgid ""
825 "The function B<clearerr>()  clears the end-of-file and error indicators for "
826 "the stream pointed to by I<stream>."
827 msgstr ""
828 "関数 B<clearerr>()  は I<stream> で示されるストリームの EOF(end-of-file) 指示"
829 "子とエラー指示子をクリアする。"
830
831 #. type: Plain text
832 #: build/C/man3/ferror.3:78
833 #, fuzzy
834 #| msgid ""
835 #| "The function B<feof>()  tests the end-of-file indicator for the stream "
836 #| "pointed to by I<stream>, returning nonzero if it is set.  The end-of-file "
837 #| "indicator can only be cleared by the function B<clearerr>()."
838 msgid ""
839 "The function B<feof>()  tests the end-of-file indicator for the stream "
840 "pointed to by I<stream>, returning nonzero if it is set.  The end-of-file "
841 "indicator can be cleared only by the function B<clearerr>()."
842 msgstr ""
843 "関数 B<feof>()  は I<stream> で示されるストリームの EOF 指示子をテストし、 "
844 "セットされていれば 0 以外の数を返す。 EOF 指示子は、関数 B<clearerr>()  に"
845 "よってのみクリアすることができる。"
846
847 #. type: Plain text
848 #: build/C/man3/ferror.3:87
849 #, fuzzy
850 #| msgid ""
851 #| "The function B<ferror>()  tests the error indicator for the stream "
852 #| "pointed to by I<stream>, returning nonzero if it is set.  The error "
853 #| "indicator can only be reset by the B<clearerr>()  function."
854 msgid ""
855 "The function B<ferror>()  tests the error indicator for the stream pointed "
856 "to by I<stream>, returning nonzero if it is set.  The error indicator can be "
857 "reset only by the B<clearerr>()  function."
858 msgstr ""
859 "関数 B<ferror>()  は I<stream> で示されるストリームのエラー指示子をテスト"
860 "し、 セットされていれば 0 以外の数を返す。 エラー指示子は、関数 B<clearerr>"
861 "()  によってのみリセットすることができる。"
862
863 #. type: Plain text
864 #: build/C/man3/ferror.3:93
865 msgid ""
866 "The function B<fileno>()  examines the argument I<stream> and returns its "
867 "integer descriptor."
868 msgstr ""
869 "関数 B<fileno>()  は、引数 I<stream> を調べ、その整数のディスクリプタを返す。"
870
871 #. type: Plain text
872 #: build/C/man3/ferror.3:96 build/C/man3/fgetwc.3:55 build/C/man3/fputwc.3:54
873 #: build/C/man3/fread.3:83 build/C/man3/gets.3:111 build/C/man3/puts.3:84
874 msgid "For nonlocking counterparts, see B<unlocked_stdio>(3)."
875 msgstr ""
876 "これらの処理を停止せずに行いたいときは、 B<unlocked_stdio>(3)  を参照のこと。"
877
878 #. type: Plain text
879 #: build/C/man3/ferror.3:106
880 msgid ""
881 "These functions should not fail and do not set the external variable "
882 "I<errno>.  (However, in case B<fileno>()  detects that its argument is not a "
883 "valid stream, it must return -1 and set I<errno> to B<EBADF>.)"
884 msgstr ""
885 "これらの関数は失敗すべきではなく、また、外部変数 I<errno> に値をセットしな"
886 "い。 (しかし、 B<fileno>()  関数の場合で、引数が有効なストリームでなかった場"
887 "合、 関数は -1 を返し、 I<errno> に B<EBADF> を設定しなければならない。)"
888
889 #. type: Plain text
890 #: build/C/man3/ferror.3:113
891 msgid ""
892 "The functions B<clearerr>(), B<feof>(), and B<ferror>()  conform to C89 and "
893 "C99."
894 msgstr ""
895 "関数 B<clearerr>(), B<feof>(), B<ferror>()  は C89 と C99 に準拠している。"
896
897 #. type: Plain text
898 #: build/C/man3/ferror.3:118
899 msgid "B<open>(2), B<fdopen>(3), B<stdio>(3), B<unlocked_stdio>(3)"
900 msgstr "B<open>(2), B<fdopen>(3), B<stdio>(3), B<unlocked_stdio>(3)"
901
902 #. type: TH
903 #: build/C/man3/fflush.3:45
904 #, no-wrap
905 msgid "FFLUSH"
906 msgstr "FFLUSH"
907
908 #. type: TH
909 #: build/C/man3/fflush.3:45
910 #, no-wrap
911 msgid "2009-09-06"
912 msgstr "2009-09-06"
913
914 #. type: Plain text
915 #: build/C/man3/fflush.3:48
916 msgid "fflush - flush a stream"
917 msgstr "fflush - ストリームの内容を強制的に出力(フラッシュ)する"
918
919 #. type: Plain text
920 #: build/C/man3/fflush.3:52
921 msgid "B<int fflush(FILE *>I<stream>B<);>"
922 msgstr "B<int fflush(FILE *>I<stream>B<);>"
923
924 #. type: Plain text
925 #: build/C/man3/fflush.3:63
926 msgid ""
927 "For output streams, B<fflush>()  forces a write of all user-space buffered "
928 "data for the given output or update I<stream> via the stream's underlying "
929 "write function.  For input streams, B<fflush>()  discards any buffered data "
930 "that has been fetched from the underlying file, but has not been consumed by "
931 "the application.  The open status of the stream is unaffected."
932 msgstr ""
933 "出力ストリームに関しては、 B<fflush>()  は、ユーザー空間でバッファリングされ"
934 "ているすべてのデータを 指定された出力に書き出す (フラッシュする)、 もしくはス"
935 "トリーム I<stream> の下位にある書き込み関数を用いてこのストリームを更新す"
936 "る。 入力ストリームに関しては、 B<fflush>()  は、対応するファイルから取得され"
937 "たが、アプリケーションからは 読み出されていないバッファデータを全て破棄す"
938 "る。 ストリームは開いた状態のままであり、 この関数によって何の影響も受けな"
939 "い。"
940
941 #. type: Plain text
942 #: build/C/man3/fflush.3:71
943 msgid ""
944 "If the I<stream> argument is NULL, B<fflush>()  flushes I<all> open output "
945 "streams."
946 msgstr ""
947 "I<stream> 引数が .BR NULL ならば、 B<fflush>()  は開いているI<すべての>出力ス"
948 "トリームをフラッシュする。"
949
950 #. type: Plain text
951 #: build/C/man3/fflush.3:74
952 msgid "For a nonlocking counterpart, see B<unlocked_stdio>(3)."
953 msgstr ""
954 "これらの処理をロックせずに行いたいときは、 B<unlocked_stdio>(3)  を参照のこ"
955 "と。"
956
957 #. type: Plain text
958 #: build/C/man3/fflush.3:81
959 msgid ""
960 "Upon successful completion 0 is returned.  Otherwise, B<EOF> is returned and "
961 "I<errno> is set to indicate the error."
962 msgstr ""
963 "成功すると 0 が返される。 その他の場合には B<EOF> が返され、 I<errno> が、エ"
964 "ラーに対応した値に設定される。"
965
966 #. type: Plain text
967 #: build/C/man3/fflush.3:86
968 msgid "I<Stream> is not an open stream, or is not open for writing."
969 msgstr ""
970 "I<Stream> は開いているストリームではない。 あるいはストリームは書き込み用では"
971 "ない。"
972
973 #. type: Plain text
974 #: build/C/man3/fflush.3:93
975 msgid ""
976 "The function B<fflush>()  may also fail and set I<errno> for any of the "
977 "errors specified for B<write>(2)."
978 msgstr ""
979 "B<fflush>()  関数は B<write>(2)  に関して規定されているエラーで失敗することも"
980 "ある。 この場合 I<errno> もその値に設定される。"
981
982 #. type: Plain text
983 #: build/C/man3/fflush.3:95
984 msgid "C89, C99, POSIX.1-2001, POSIX.1-2008."
985 msgstr "C89, C99, POSIX.1-2001, POSIX.1-2008."
986
987 #.  Verified on: Solaris 8.
988 #. type: Plain text
989 #: build/C/man3/fflush.3:99
990 msgid ""
991 "The standards do not specify the behavior for input streams.  Most other "
992 "implementations behave the same as Linux."
993 msgstr ""
994 "標準では、入力ストリームに対する動作は規定されていない。 他のほとんどの実装"
995 "は Linux と同じ動作をする。"
996
997 #. type: Plain text
998 #: build/C/man3/fflush.3:108
999 msgid ""
1000 "Note that B<fflush>()  only flushes the user-space buffers provided by the C "
1001 "library.  To ensure that the data is physically stored on disk the kernel "
1002 "buffers must be flushed too, for example, with B<sync>(2)  or B<fsync>(2)."
1003 msgstr ""
1004 "B<fflush>()  は、 C ライブラリが与えているユーザー空間のバッファしかフラッ"
1005 "シュしない。 データが物理的にディスクに保存されることを保証したければ、 カー"
1006 "ネルバッファもフラッシュしなければならない。 これには例えば B<sync>(2)  や "
1007 "B<fsync>(2)  を用いる。"
1008
1009 #. type: Plain text
1010 #: build/C/man3/fflush.3:116
1011 msgid ""
1012 "B<fsync>(2), B<sync>(2), B<write>(2), B<fclose>(3), B<fopen>(3), B<setbuf>"
1013 "(3), B<unlocked_stdio>(3)"
1014 msgstr ""
1015 "B<fsync>(2), B<sync>(2), B<write>(2), B<fclose>(3), B<fopen>(3), B<setbuf>"
1016 "(3), B<unlocked_stdio>(3)"
1017
1018 #. type: TH
1019 #: build/C/man3/fgetwc.3:18
1020 #, no-wrap
1021 msgid "FGETWC"
1022 msgstr "FGETWC"
1023
1024 #. type: TH
1025 #: build/C/man3/fgetwc.3:18 build/C/man3/fputwc.3:16
1026 #, no-wrap
1027 msgid "1999-07-25"
1028 msgstr "1999-07-25"
1029
1030 #. type: Plain text
1031 #: build/C/man3/fgetwc.3:21
1032 msgid "fgetwc, getwc - read a wide character from a FILE stream"
1033 msgstr "fgetwc, getwc - ワイド文字を FILE ストリームから読み込む"
1034
1035 #. type: Plain text
1036 #: build/C/man3/fgetwc.3:26 build/C/man3/fmemopen.3:22
1037 #: build/C/man3/fputwc.3:24 build/C/man3/unlocked_stdio.3:54
1038 #, no-wrap
1039 msgid "B<#include E<lt>wchar.hE<gt>>\n"
1040 msgstr "B<#include E<lt>wchar.hE<gt>>\n"
1041
1042 #. type: Plain text
1043 #: build/C/man3/fgetwc.3:29
1044 #, no-wrap
1045 msgid ""
1046 "B<wint_t fgetwc(FILE *>I<stream>B<);>\n"
1047 "B<wint_t getwc(FILE *>I<stream>B<);>\n"
1048 msgstr ""
1049 "B<wint_t fgetwc(FILE *>I<stream>B<);>\n"
1050 "B<wint_t getwc(FILE *>I<stream>B<);>\n"
1051
1052 #. type: Plain text
1053 #: build/C/man3/fgetwc.3:44
1054 msgid ""
1055 "The B<fgetwc>()  function is the wide-character equivalent of the B<fgetc>"
1056 "(3)  function.  It reads a wide character from I<stream> and returns it.  If "
1057 "the end of stream is reached, or if I<ferror(stream)> becomes true, it "
1058 "returns B<WEOF>.  If a wide-character conversion error occurs, it sets "
1059 "I<errno> to B<EILSEQ> and returns B<WEOF>."
1060 msgstr ""
1061 "B<fgetwc>()  関数は、 B<fgetc>(3)  に対応するワイド文字関数である。 この関数"
1062 "は I<stream> からワイド文字を 1 文字読み込み、これを返す。 ストリームの終端に"
1063 "達するか、I<ferror(stream)> が真になった場合には、 この関数は B<WEOF> を返"
1064 "す。 ワイド文字変換でエラーが発生した場合は、 I<errno> に B<EILSEQ> をセット"
1065 "し、 B<WEOF> を返す。"
1066
1067 #. type: Plain text
1068 #: build/C/man3/fgetwc.3:52
1069 msgid ""
1070 "The B<getwc>()  function or macro functions identically to B<fgetwc>().  It "
1071 "may be implemented as a macro, and may evaluate its argument more than "
1072 "once.  There is no reason ever to use it."
1073 msgstr ""
1074 "B<getwc>()  関数あるいはマクロは、 B<fgetwc>()  と全く同じ動作をする。 この関"
1075 "数はマクロとして実装されるかもしれないので、引き数が複数回評価さ れるかもしれ"
1076 "ない。この関数を使う理由はもはや存在しない。"
1077
1078 #. type: Plain text
1079 #: build/C/man3/fgetwc.3:61
1080 msgid ""
1081 "The B<fgetwc>()  function returns the next wide-character from the stream, "
1082 "or B<WEOF>."
1083 msgstr ""
1084 "B<fgetwc>()  関数はストリームの次のワイド文字か、あるいは B<WEOF> を返す。"
1085
1086 #. type: Plain text
1087 #: build/C/man3/fgetwc.3:63 build/C/man3/fputwc.3:62
1088 msgid "Apart from the usual ones, there is"
1089 msgstr "通常のエラーに加えて、以下のエラーがある:"
1090
1091 #. type: TP
1092 #: build/C/man3/fgetwc.3:63 build/C/man3/fputwc.3:62 build/C/man3/scanf.3:559
1093 #, no-wrap
1094 msgid "B<EILSEQ>"
1095 msgstr "B<EILSEQ>"
1096
1097 #. type: Plain text
1098 #: build/C/man3/fgetwc.3:67
1099 msgid ""
1100 "The data obtained from the input stream does not form a valid character."
1101 msgstr "入力ストリームから取得したデータが、正しい文字でない。"
1102
1103 #. type: Plain text
1104 #: build/C/man3/fgetwc.3:69 build/C/man3/fputwc.3:67
1105 msgid "C99, POSIX.1-2001."
1106 msgstr "C99, POSIX.1-2001."
1107
1108 #. type: Plain text
1109 #: build/C/man3/fgetwc.3:76
1110 msgid ""
1111 "The behavior of B<fgetwc>()  depends on the B<LC_CTYPE> category of the "
1112 "current locale."
1113 msgstr ""
1114 "B<fgetwc>()  の動作は、現在のロケールの B<LC_CTYPE> カテゴリに依存する。"
1115
1116 #. type: Plain text
1117 #: build/C/man3/fgetwc.3:84
1118 msgid ""
1119 "In the absence of additional information passed to the B<fopen>(3)  call, it "
1120 "is reasonable to expect that B<fgetwc>()  will actually read a multibyte "
1121 "sequence from the stream and then convert it to a wide character."
1122 msgstr ""
1123 "B<fopen>(3)  システムコールに渡す追加情報がない場合には、 B<fgetwc>()  が実"
1124 "際 にはマルチバイトシーケンスをストリームから読み込み、これをワイド文字に 変"
1125 "換すると期待することは適切である。"
1126
1127 #. type: Plain text
1128 #: build/C/man3/fgetwc.3:89
1129 msgid "B<fgetws>(3), B<fputwc>(3), B<ungetwc>(3), B<unlocked_stdio>(3)"
1130 msgstr "B<fgetws>(3), B<fputwc>(3), B<ungetwc>(3), B<unlocked_stdio>(3)"
1131
1132 #. type: TH
1133 #: build/C/man3/flockfile.3:25
1134 #, no-wrap
1135 msgid "FLOCKFILE"
1136 msgstr "FLOCKFILE"
1137
1138 #. type: Plain text
1139 #: build/C/man3/flockfile.3:28
1140 msgid "flockfile, ftrylockfile, funlockfile - lock FILE for stdio"
1141 msgstr "flockfile, ftrylockfile, funlockfile - 標準入出力 FILE のロックを行う"
1142
1143 #. type: Plain text
1144 #: build/C/man3/flockfile.3:33
1145 #, no-wrap
1146 msgid "B<void flockfile(FILE *>I<filehandle>B<);>\n"
1147 msgstr "B<void flockfile(FILE *>I<filehandle>B<);>\n"
1148
1149 #. type: Plain text
1150 #: build/C/man3/flockfile.3:35
1151 #, no-wrap
1152 msgid "B<int ftrylockfile(FILE *>I<filehandle>B<);>\n"
1153 msgstr "B<int ftrylockfile(FILE *>I<filehandle>B<);>\n"
1154
1155 #. type: Plain text
1156 #: build/C/man3/flockfile.3:37
1157 #, no-wrap
1158 msgid "B<void funlockfile(FILE *>I<filehandle>B<);>\n"
1159 msgstr "B<void funlockfile(FILE *>I<filehandle>B<);>\n"
1160
1161 #. type: Plain text
1162 #: build/C/man3/flockfile.3:46 build/C/man3/wprintf.3:43
1163 msgid "All functions shown above:"
1164 msgstr "上記の全ての関数:"
1165
1166 #. type: Plain text
1167 #: build/C/man3/flockfile.3:49
1168 msgid ""
1169 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE "
1170 "|| _POSIX_SOURCE"
1171 msgstr ""
1172 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE "
1173 "|| _POSIX_SOURCE"
1174
1175 #. type: Plain text
1176 #: build/C/man3/flockfile.3:63
1177 msgid ""
1178 "The stdio functions are thread-safe.  This is achieved by assigning to each "
1179 "I<FILE> object a lockcount and (if the lockcount is nonzero)  an owning "
1180 "thread.  For each library call, these functions wait until the I<FILE> "
1181 "object is no longer locked by a different thread, then lock it, do the "
1182 "requested I/O, and unlock the object again."
1183 msgstr ""
1184 "標準入出力関数はスレッドセーフである。これは、各 I<FILE> オブジェクトに対し、"
1185 "ロック数 (lockcount) と (ロック数が 0 でない場合は) 所有者スレッド (owner "
1186 "thread)  を管理することで実現される。 ライブラリの呼び出しが行われる毎に、標"
1187 "準入出力関数は I<FILE> オブジェクトが他のスレッドによってロックされていない状"
1188 "態になるまで待ち、 I<FILE> オブジェクトをロックし、要求されて入出力を行い、 "
1189 "オブジェクトのロックを解除する。"
1190
1191 #. type: Plain text
1192 #: build/C/man3/flockfile.3:69
1193 msgid ""
1194 "(Note: this locking has nothing to do with the file locking done by "
1195 "functions like B<flock>(2)  and B<lockf>(3).)"
1196 msgstr ""
1197 "(注: このロックは、 B<flock>(2)  や B<lockf>(3)  といった関数が行うロックとは"
1198 "全く無関係である。)"
1199
1200 #. type: Plain text
1201 #: build/C/man3/flockfile.3:77
1202 msgid ""
1203 "All this is invisible to the C-programmer, but there may be two reasons to "
1204 "wish for more detailed control.  On the one hand, maybe a series of I/O "
1205 "actions by one thread belongs together, and should not be interrupted by the "
1206 "I/O of some other thread.  On the other hand, maybe the locking overhead "
1207 "should be avoided for greater efficiency."
1208 msgstr ""
1209 "これらのことはすべて C プログラマには見えない部分で行われるが、 より細かい制"
1210 "御ができた方がよい理由が2つあるだろう。一つは、一つのスレッドが 行う一連の入"
1211 "出力動作は一緒に行われ、他のスレッドの入出力によって中断されない 方がよいとい"
1212 "うことであろう。もう一つは、効率を大きく上げるためには ロックのオーバヘッドを"
1213 "避ける必要があるということであろう。"
1214
1215 #. type: Plain text
1216 #: build/C/man3/flockfile.3:94
1217 msgid ""
1218 "To this end, a thread can explicitly lock the I<FILE> object, then do its "
1219 "series of I/O actions, then unlock.  This prevents other threads from coming "
1220 "in between.  If the reason for doing this was to achieve greater efficiency, "
1221 "one does the I/O with the nonlocking versions of the stdio functions: with "
1222 "B<getc_unlocked>(3)  and B<putc_unlocked>(3)  instead of B<getc>(3)  and "
1223 "B<putc>(3)."
1224 msgstr ""
1225 "この目的を実現するために、 I<FILE> オブジェクトのロック、一連の入出力動作の実"
1226 "行、 ロックの解除をスレッドが明示的に指示することができる。 これにより、他の"
1227 "スレッドが途中で入出力を行うのを防止する。 このようなことを行う理由が効率の向"
1228 "上であるならば、 ロックを行わないバージョンの標準入出力関数を使うこともでき"
1229 "る。 例えば、 B<getc>(3)  や B<putc>(3)  の代わりに B<getc_unlocked>(3)  や "
1230 "B<putc_unlocked>(3)  を使用する。"
1231
1232 #. type: Plain text
1233 #: build/C/man3/flockfile.3:101
1234 msgid ""
1235 "The B<flockfile>()  function waits for I<*filehandle> to be no longer locked "
1236 "by a different thread, then makes the current thread owner of "
1237 "I<*filehandle>, and increments the lockcount."
1238 msgstr ""
1239 "B<flockfile>()  関数は、I<*filehandle> が他のスレッドにロックされていな い状"
1240 "態になるまで待ったのち、現在のスレッドを I<*filehandle> のオーナに設 定し、"
1241 "ロック数を加算する。"
1242
1243 #. type: Plain text
1244 #: build/C/man3/flockfile.3:105
1245 msgid "The B<funlockfile>()  function decrements the lock count."
1246 msgstr "B<funlockfile>()  関数は、ロック数を減算する。"
1247
1248 #. type: Plain text
1249 #: build/C/man3/flockfile.3:114
1250 msgid ""
1251 "The B<ftrylockfile>()  function is a nonblocking version of B<flockfile>().  "
1252 "It does nothing in case some other thread owns I<*filehandle>, and it "
1253 "obtains ownership and increments the lockcount otherwise."
1254 msgstr ""
1255 "B<ftrylockfile>()  関数は B<flockfile>()  のブロッキングを行わない バージョン"
1256 "である。他のスレッドが I<*filehandle> をロックしている時は 何も行わず、そうで"
1257 "ない場合は I<*filehandle> の所有権を獲得し、 ロック数を加算する。"
1258
1259 #. type: Plain text
1260 #: build/C/man3/flockfile.3:119
1261 msgid ""
1262 "The B<ftrylockfile>()  function returns zero for success (the lock was "
1263 "obtained), and nonzero for failure."
1264 msgstr ""
1265 "B<ftrylockfile>()  関数はロックに成功すると 0 を返し、 失敗した場合は 0 以外"
1266 "の値を返す。"
1267
1268 #. type: Plain text
1269 #: build/C/man3/flockfile.3:121
1270 msgid "None."
1271 msgstr "なし。"
1272
1273 #. type: Plain text
1274 #: build/C/man3/flockfile.3:123 build/C/man3/popen.3:171
1275 msgid "POSIX.1-2001."
1276 msgstr "POSIX.1-2001."
1277
1278 #. type: SH
1279 #: build/C/man3/flockfile.3:123
1280 #, no-wrap
1281 msgid "AVAILABILITY"
1282 msgstr "可用性"
1283
1284 #. type: Plain text
1285 #: build/C/man3/flockfile.3:129
1286 msgid ""
1287 "These functions are available when B<_POSIX_THREAD_SAFE_FUNCTIONS> is "
1288 "defined.  They are in libc since libc 5.1.1 and in glibc since glibc 2.0."
1289 msgstr ""
1290 "B<_POSIX_THREAD_SAFE_FUNCTIONS> が定義されているときにこれらの関数を使用する"
1291 "ことができる。 5.1.1 以降の libc と 2.0 以降の glibc に存在する。"
1292
1293 #. type: Plain text
1294 #: build/C/man3/flockfile.3:131
1295 msgid "B<unlocked_stdio>(3)"
1296 msgstr "B<unlocked_stdio>(3)"
1297
1298 #. type: TH
1299 #: build/C/man3/fmemopen.3:10
1300 #, no-wrap
1301 msgid "FMEMOPEN"
1302 msgstr "FMEMOPEN"
1303
1304 #. type: TH
1305 #: build/C/man3/fmemopen.3:10
1306 #, no-wrap
1307 msgid "2012-04-28"
1308 msgstr "2012-04-28"
1309
1310 #. type: Plain text
1311 #: build/C/man3/fmemopen.3:13
1312 msgid "fmemopen, open_memstream, open_wmemstream - open memory as stream"
1313 msgstr ""
1314 "fmemopen, open_memstream, open_wmemstream - メモリをストリームとしてオープン"
1315 "する"
1316
1317 #. type: Plain text
1318 #: build/C/man3/fmemopen.3:18
1319 #, no-wrap
1320 msgid "B<FILE *fmemopen(void *>I<buf>B<, size_t >I<size>B<, const char *>I<mode>B<);>\n"
1321 msgstr "B<FILE *fmemopen(void *>I<buf>B<, size_t >I<size>B<, const char *>I<mode>B<);>\n"
1322
1323 #. type: Plain text
1324 #: build/C/man3/fmemopen.3:20
1325 #, no-wrap
1326 msgid "B<FILE *open_memstream(char **>I<ptr>B<, size_t *>I<sizeloc>B<);>\n"
1327 msgstr "B<FILE *open_memstream(char **>I<ptr>B<, size_t *>I<sizeloc>B<);>\n"
1328
1329 #. type: Plain text
1330 #: build/C/man3/fmemopen.3:24
1331 #, no-wrap
1332 msgid "B<FILE *open_wmemstream(wchar_t **>I<ptr>B<, size_t *>I<sizeloc>B<);>\n"
1333 msgstr "B<FILE *open_wmemstream(wchar_t **>I<ptr>B<, size_t *>I<sizeloc>B<);>\n"
1334
1335 #. type: Plain text
1336 #: build/C/man3/fmemopen.3:34
1337 msgid "B<fmemopen>(), B<open_memstream>(), B<open_wmemstream>():"
1338 msgstr "B<fmemopen>(), B<open_memstream>(), B<open_wmemstream>():"
1339
1340 #. type: Plain text
1341 #: build/C/man3/fmemopen.3:57
1342 msgid ""
1343 "The B<fmemopen>()  function opens a stream that permits the access specified "
1344 "by I<mode>.  The stream allows I/O to be performed on the string or memory "
1345 "buffer pointed to by I<buf>.  This buffer must be at least I<size> bytes "
1346 "long."
1347 msgstr ""
1348 "B<fmemopen>()  関数は、ストリームをオープンし、そのストリームに I<mode> で指"
1349 "定されたアクセス許可を設定する。 そのストリームを通じて、 I<buf> で指定された"
1350 "文字列やメモリバッファへの読み書きができる。 このバッファは少なくとも "
1351 "I<size> バイトの長さでなければならない。"
1352
1353 #. type: Plain text
1354 #: build/C/man3/fmemopen.3:77
1355 msgid ""
1356 "The argument I<mode> is the same as for B<fopen>(3).  If I<mode> specifies "
1357 "an append mode, then the initial file position is set to the location of the "
1358 "first null byte (\\(aq\\e0\\(aq) in the buffer; otherwise the initial file "
1359 "position is set to the start of the buffer.  Since glibc 2.9, the letter "
1360 "\\(aqb\\(aq may be specified as the second character in I<mode>.  This "
1361 "provides \"binary\" mode: writes don't implicitly add a terminating null "
1362 "byte, and B<fseek>(3)  B<SEEK_END> is relative to the end of the buffer (i."
1363 "e., the value specified by the I<size> argument), rather than the current "
1364 "string length."
1365 msgstr ""
1366 "引き数 I<mode> は B<fopen>(3) の場合と同じである。 I<mode> で追記モード\n"
1367 "(append mode) が指定された場合、ファイル位置の初期値は バッファ中の\n"
1368 "最初の NULL バイト (\\(aq\\e0\\(aq) の位置に設定される。\n"
1369 "それ以外の場合は、ファイル位置の初期値はバッファの先頭になる。 \n"
1370 "glibc 2.9 以降では、文字 \\(aqb\\(aq を I<mode> の二番目の文字として指定\n"
1371 "することができる。 この文字は「バイナリ」モードを指定するものである。\n"
1372 "このモードでは、書き込み時に文字列終端のヌルバイトが黙って追加 される\n"
1373 "ことはない。また、 B<fseek>(3) B<SEEK_END> は、文字列の長さからの相対値\n"
1374 "ではなく、バッファの末尾 (I<size> で指定した値) からの相対値となる。"
1375
1376 #. type: Plain text
1377 #: build/C/man3/fmemopen.3:89
1378 msgid ""
1379 "When a stream that has been opened for writing is flushed (B<fflush>(3))  or "
1380 "closed (B<fclose>(3)), a null byte is written at the end of the buffer if "
1381 "there is space.  The caller should ensure that an extra byte is available in "
1382 "the buffer (and that I<size> counts that byte)  to allow for this."
1383 msgstr ""
1384 "書き込み用にオープンされたストリームをフラッシュ (B<fflush>(3))  やクローズ "
1385 "(B<fclose>(3))  した時に、 (バッファに空きがあれば) NULL バイトがバッファの末"
1386 "尾に書き込まれる。 このようにするためには、呼び出し元は バッファに 1バイト余"
1387 "裕を作る (I<size> にこの 1バイトを含めた値を指定する) 必要がある。"
1388
1389 #.  See http://sourceware.org/bugzilla/show_bug.cgi?id=1995
1390 #.  and
1391 #.  http://sources.redhat.com/ml/libc-alpha/2006-04/msg00064.html
1392 #. type: Plain text
1393 #: build/C/man3/fmemopen.3:107
1394 #, fuzzy
1395 #| msgid ""
1396 #| "Attempts to write more than I<size> bytes to the buffer result in an "
1397 #| "error.  (By default, such errors will only be visible when the I<stdio> "
1398 #| "buffer is flushed.  Disabling buffering with I<setbuf(fp,\\ NULL)> may be "
1399 #| "useful to detect errors at the time of an output operation.  "
1400 #| "Alternatively, the caller can explicitly set I<buf> as the stdio stream "
1401 #| "buffer, at the same time informing stdio of the buffer's size, using "
1402 #| "I<setbuffer(fp, buf, size)>.)"
1403 msgid ""
1404 "Attempts to write more than I<size> bytes to the buffer result in an error.  "
1405 "(By default, such errors will be visible only when the I<stdio> buffer is "
1406 "flushed.  Disabling buffering with I<setbuf(fp,\\ NULL)> may be useful to "
1407 "detect errors at the time of an output operation.  Alternatively, the caller "
1408 "can explicitly set I<buf> as the stdio stream buffer, at the same time "
1409 "informing stdio of the buffer's size, using I<setbuffer(fp, buf, size)>.)"
1410 msgstr ""
1411 "バッファに I<size> バイトよりたくさん書き込もうとした場合には、エラーとな"
1412 "る。 (デフォルトでは、このようなエラーが見えるのは I<stdio> バッファがフラッ"
1413 "シュされた時だけである。 I<setbuf(fp,\\ NULL)> を使ってバッファリングを無効に"
1414 "する方法は、 出力操作を行った時点でエラーを検出するのに役立つ。 別の方法とし"
1415 "ては、 I<setbuffer(fp, buf, size)> を使って、呼び出し側が明示的に stdio スト"
1416 "リームバッファとして I<buf> を指定し、バッファの指定時にバッファのサイズを "
1417 "stdio に教える方法がある。)"
1418
1419 #. type: Plain text
1420 #: build/C/man3/fmemopen.3:115
1421 msgid ""
1422 "In a stream opened for reading, null bytes (\\(aq\\e0\\(aq) in the buffer do "
1423 "not cause read operations to return an end-of-file indication.  A read from "
1424 "the buffer will only indicate end-of-file when the file pointer advances "
1425 "I<size> bytes past the start of the buffer."
1426 msgstr ""
1427 "読み出し用にオープンされたストリームでは、 バッファ内に NULL バイト (\\(aq"
1428 "\\e0\\(aq) があっても 読み出し操作がファイル末尾 (end-of-file) を返すことはな"
1429 "い。 バッファからの読み出しでファイル末尾が返るのは、 ファイルポインタがバッ"
1430 "ファの先頭から I<size> バイトを越えて先に進もうとした場合だけである。"
1431
1432 #. type: Plain text
1433 #: build/C/man3/fmemopen.3:130
1434 msgid ""
1435 "If I<buf> is specified as NULL, then B<fmemopen>()  dynamically allocates a "
1436 "buffer I<size> bytes long.  This is useful for an application that wants to "
1437 "write data to a temporary buffer and then read it back again.  The buffer is "
1438 "automatically freed when the stream is closed.  Note that the caller has no "
1439 "way to obtain a pointer to the temporary buffer allocated by this call (but "
1440 "see B<open_memstream>()  below)."
1441 msgstr ""
1442 "I<buf> に NULL が指定された場合、 B<fmemopen>()  は動的に I<size> バイトの長"
1443 "さのバッファを確保する。 この方法は、一時バッファにデータの書き込みを行ってか"
1444 "ら、 その内容を再度読み出すようなアプリケーションで有用である。 このバッファ"
1445 "はストリームがクローズされるときに自動的に解放される。 呼び出し元からはこの関"
1446 "数が割り当てた一時バッファへのポインタ値を 知る方法は存在しない点に注意 (下記"
1447 "の B<open_memstream>()  も参照)。"
1448
1449 #. type: Plain text
1450 #: build/C/man3/fmemopen.3:141
1451 msgid ""
1452 "The B<open_memstream>()  function opens a stream for writing to a buffer.  "
1453 "The buffer is dynamically allocated (as with B<malloc>(3)), and "
1454 "automatically grows as required.  After closing the stream, the caller "
1455 "should B<free>(3)  this buffer."
1456 msgstr ""
1457 "B<open_memstream>()  関数は、バッファへの書き込み用にストリームをオープンす"
1458 "る。 バッファは (B<malloc>(3)  を使って) 動的に割り当てられ、必要に応じて自動"
1459 "的に伸長する。 ストリームをクローズした後で、呼び出し元はこのバッファを "
1460 "B<free>(3)  すべきである。"
1461
1462 #. type: Plain text
1463 #: build/C/man3/fmemopen.3:156
1464 msgid ""
1465 "When the stream is closed (B<fclose>(3))  or flushed (B<fflush>(3)), the "
1466 "locations pointed to by I<ptr> and I<sizeloc> are updated to contain, "
1467 "respectively, a pointer to the buffer and the current size of the buffer.  "
1468 "These values remain valid only as long as the caller performs no further "
1469 "output on the stream.  If further output is performed, then the stream must "
1470 "again be flushed before trying to access these variables."
1471 msgstr ""
1472 "このストリームが クローズ (B<fclose>(3))  されたりフラッシュ (B<fflush>(3))  "
1473 "された時に、 I<ptr> と I<sizeloc> の値はそれぞれバッファへのポインタとそのサ"
1474 "イズに更新される。 これらの値は、呼び出し元がそのストリームに新たな書き込み"
1475 "を 行わない場合に限り有効である。 ストリームに書き込みを行った際には、これら"
1476 "の変数を参照する前に ストリームを再度フラッシュしなければならない。"
1477
1478 #. type: Plain text
1479 #: build/C/man3/fmemopen.3:162
1480 msgid ""
1481 "A null byte is maintained at the end of the buffer.  This byte is I<not> "
1482 "included in the size value stored at I<sizeloc>."
1483 msgstr ""
1484 "バッファ末尾の NULL バイトは保持される。 この NULL バイトは I<sizeloc> に格納"
1485 "されるサイズには「含まれない」。"
1486
1487 #. type: Plain text
1488 #: build/C/man3/fmemopen.3:170
1489 msgid ""
1490 "The stream's file position can be changed with B<fseek>(3)  or B<fseeko>"
1491 "(3).  Moving the file position past the end of the data already written "
1492 "fills the intervening space with zeros."
1493 msgstr ""
1494 "ストリームのファイル位置は B<fseek>(3)  や B<fseeko>(3)  で変更できる。 すで"
1495 "にデータが書き込まれた領域の末尾より先にファイル位置を動かすと、 その間の領域"
1496 "は 0 で埋められる。"
1497
1498 #. type: Plain text
1499 #: build/C/man3/fmemopen.3:176
1500 msgid ""
1501 "The B<open_wmemstream>()  is similar to B<open_memstream>(), but operates on "
1502 "wide characters instead of bytes."
1503 msgstr ""
1504 "B<open_wmemstream>()  は B<open_memstream>()  と同様だが、バイトではなくワイ"
1505 "ド文字に対して操作を行う点が異なる。"
1506
1507 #. type: Plain text
1508 #: build/C/man3/fmemopen.3:188
1509 msgid ""
1510 "Upon successful completion B<fmemopen>(), B<open_memstream>()  and "
1511 "B<open_wmemstream>()  return a I<FILE> pointer.  Otherwise, NULL is returned "
1512 "and I<errno> is set to indicate the error."
1513 msgstr ""
1514 "成功して終了した場合には、 B<fmemopen>(), B<open_memstream>(), "
1515 "B<open_wmemstream>()  は I<FILE> ポインタを返す。 失敗した場合は、 NULL を返"
1516 "し、 I<errno> にエラーを示す値をセットする。"
1517
1518 #. type: SH
1519 #: build/C/man3/fmemopen.3:188 build/C/man3/fmtmsg.3:222
1520 #: build/C/man3/getline.3:132 build/C/man2/pipe.2:113 build/C/man2/readv.2:209
1521 #, no-wrap
1522 msgid "VERSIONS"
1523 msgstr "バージョン"
1524
1525 #. type: Plain text
1526 #: build/C/man3/fmemopen.3:195
1527 msgid ""
1528 "B<fmemopen>()  and B<open_memstream>()  were already available in glibc 1.0."
1529 "x.  B<open_wmemstream>()  is available since glibc 2.4."
1530 msgstr ""
1531 "B<fmemopen>()  と B<open_memstream>()  は glibc 1.0.x ですでに利用可能であっ"
1532 "た。 B<open_wmemstream>()  は glibc 2.4 以降で利用可能である。"
1533
1534 #. type: Plain text
1535 #: build/C/man3/fmemopen.3:199
1536 msgid ""
1537 "POSIX.1-2008.  These functions are not specified in POSIX.1-2001, and are "
1538 "not widely available on other systems."
1539 msgstr ""
1540 "POSIX.1-2008.  これらの関数は POSIX.1-2001 では規定れていないが、 Linux 以外"
1541 "のシステムで広く利用可能である。"
1542
1543 #.  http://austingroupbugs.net/view.php?id=396
1544 #. type: Plain text
1545 #: build/C/man3/fmemopen.3:207
1546 msgid ""
1547 "POSIX.1-2008 specifies that \\(aqb\\(aq in I<mode> shall be ignored.  "
1548 "However, Technical Corrigendum 1 adjusts the standard to allow "
1549 "implementation-specific treatment for this case, thus permitting the glibc "
1550 "treatment of \\(aqb\\(aq."
1551 msgstr ""
1552 "POSIX.1-2008 では I<mode> の \\(aqb\\(aq は無視されるべきだと規定されて\n"
1553 "いる。一方、Technical Corrigendum (正誤表) 1 では、I<mode> の\n"
1554 "\\(aqb\\(aq が指定された場合の扱いは実装依存であることを許容するように\n"
1555 "標準規格が修正されており、glibc の \\(aqb\\(aq の扱いは許されている。"
1556
1557 #. type: Plain text
1558 #: build/C/man3/fmemopen.3:213
1559 msgid ""
1560 "There is no file descriptor associated with the file stream returned by "
1561 "these functions (i.e., B<fileno>(3)  will return an error if called on the "
1562 "returned stream)."
1563 msgstr ""
1564 "これらの関数が返すファイルストリームに対応するファイル ディスクリプタはない "
1565 "(つまり、返されたストリームに対して B<fileno>(3)  を呼び出すとエラーが返るこ"
1566 "とになる)。"
1567
1568 #.  http://sourceware.org/bugzilla/show_bug.cgi?id=1996
1569 #. type: Plain text
1570 #: build/C/man3/fmemopen.3:220
1571 msgid ""
1572 "In glibc before version 2.7, seeking past the end of a stream created by "
1573 "B<open_memstream>()  does not enlarge the buffer; instead the B<fseek>(3)  "
1574 "call fails, returning -1."
1575 msgstr ""
1576 "バージョン 2.7 より前の glibc では、 B<open_memstream>()  で作成されたスト"
1577 "リームの末尾より先にファイル位置を動かしても、 バッファが伸長されず、 "
1578 "B<fseek>(3)  が失敗し -1 が返る。"
1579
1580 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=11216
1581 #. type: Plain text
1582 #: build/C/man3/fmemopen.3:231
1583 msgid ""
1584 "If I<size> is specified as zero, B<fmemopen>()  fails with the error "
1585 "B<EINVAL>.  It would be more consistent if this case successfully created a "
1586 "stream that then returned end of file on the first attempt at reading.  "
1587 "Furthermore, POSIX.1-2008 does not specify a failure for this case."
1588 msgstr ""
1589 "I<size> に 0 が指定された場合、 B<fmemopen>() はエラー B<EINVAL> で失敗\n"
1590 "する。この場合にはストリームの作成に成功して、最初の読み出しを行った際に\n"
1591 "EOF (end of file) が返される方が、ストリームの扱いの一貫性が増すだろう。\n"
1592 "また、 POSIX.1-2008 ではこの場合のエラーは規定されていない。"
1593
1594 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=13152
1595 #. type: Plain text
1596 #: build/C/man3/fmemopen.3:239
1597 msgid ""
1598 "Specifying append mode (\"a\" or \"a+\") for B<fmemopen>()  sets the initial "
1599 "file position to the first null byte, but (if the file offset is reset to a "
1600 "location other than the end of the stream)  does not force subsequent writes "
1601 "to append at the end of the stream."
1602 msgstr ""
1603 "B<fmemopen>() に追記モード (\"a\" や \"a+\") を指定すると、\n"
1604 "ファイル位置の初期値は最初の NULL バイトに設定されるが、(ファイル\n"
1605 "オフセットをストリームの末尾以外の位置に再設定した場合)それ以降の\n"
1606 "書き込みではストリームの末尾への追記が行われる訳ではない。"
1607
1608 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=13151
1609 #. type: Plain text
1610 #: build/C/man3/fmemopen.3:255
1611 msgid ""
1612 "If the I<mode> argument to B<fmemopen>()  specifies append (\"a\" or \"a+"
1613 "\"), and the I<size> argument does not cover a null byte in I<buf> then, "
1614 "according to POSIX.1-2008, the initial file position should be set to the "
1615 "next byte after the end of the buffer.  However, in this case the glibc "
1616 "B<fmemopen>()  sets the file position to -1."
1617 msgstr ""
1618 "B<fmemopen>() の I<mode> 引き数に追記モード (\"a\" や \"a+\") を指定し、\n"
1619 "I<size> 引き数で指定した範囲の I<buf> 内に NULL バイトがない場合、\n"
1620 "POSIX.1-2008 では、ファイル位置の初期値はバッファの末尾の直後の\n"
1621 "バイトに設定すべきとされている。しかし、glibc の B<fmemopen>() では\n"
1622 "この場合ファイル位置は -1 に設定される。"
1623
1624 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=12836
1625 #. type: Plain text
1626 #: build/C/man3/fmemopen.3:268
1627 msgid ""
1628 "To specify binary mode for B<fmemopen>()  the \\(aqb\\(aq must be the "
1629 "I<second> character in I<mode>.  Thus, for example, \"wb+\" has the desired "
1630 "effect, but \"w+b\" does not.  This is inconsistent with the treatment of "
1631 "I<mode> by B<fopen>(3)."
1632 msgstr ""
1633 "B<fmemopen>() でバイナリモードを指定するには、\n"
1634 "\\(aqb\\(aq は I<mode> の I<2 文字目> でなければならない。\n"
1635 "例えば、 \"wb+\" は意図通りの効果になるが、 \"w+b\" はそうではない。\n"
1636 "これは B<fopen>(3) の I<mode> の扱いとは異なる。"
1637
1638 #.  http://sourceware.org/bugzilla/show_bug.cgi?id=6544
1639 #. type: Plain text
1640 #: build/C/man3/fmemopen.3:276
1641 msgid ""
1642 "The glibc 2.9 addition of \"binary\" mode for B<fmemopen>()  silently "
1643 "changed the ABI: previously, B<fmemopen>()  ignored \\(aqb\\(aq in I<mode>."
1644 msgstr ""
1645 "glibc 2.9 での B<fmemopen>() の「バイナリ」モードの追加は、\n"
1646 "ABI (Application Binary Interface) が黙って変更された。\n"
1647 "それ以前の B<fmemopen>() では I<mode> 内の \\(aqb\\(aq は無視されていた。"
1648
1649 #. type: SH
1650 #: build/C/man3/fmemopen.3:276 build/C/man3/fmtmsg.3:244
1651 #: build/C/man3/fopencookie.3:247 build/C/man3/getline.3:141
1652 #: build/C/man2/pipe.2:124 build/C/man3/printf.3:973
1653 #: build/C/man2/readlink.2:157 build/C/man2/readv.2:265
1654 #: build/C/man3/scanf.3:682
1655 #, no-wrap
1656 msgid "EXAMPLE"
1657 msgstr "例"
1658
1659 #. type: Plain text
1660 #: build/C/man3/fmemopen.3:286
1661 msgid ""
1662 "The program below uses B<fmemopen>()  to open an input buffer, and "
1663 "B<open_memstream>()  to open a dynamically sized output buffer.  The program "
1664 "scans its input string (taken from the program's first command-line "
1665 "argument) reading integers, and writes the squares of these integers to the "
1666 "output buffer.  An example of the output produced by this program is the "
1667 "following:"
1668 msgstr ""
1669 "このプログラムは B<fmemopen>()  を使って出力バッファをオープンし、 "
1670 "B<open_memstream>()  を使って動的にサイズが変化する出力バッファをオープンして"
1671 "いる。 (プログラムの第一コマンドライン引き数から取った) 入力文字列を スキャン"
1672 "して整数を読み込み、これらの整数の二乗を出力バッファに書き出す。 このプログラ"
1673 "ムの実行例は以下のようになる。"
1674
1675 #. type: Plain text
1676 #: build/C/man3/fmemopen.3:291
1677 #, no-wrap
1678 msgid ""
1679 "$B< ./a.out \\(aq1 23 43\\(aq>\n"
1680 "size=11; ptr=1 529 1849\n"
1681 msgstr ""
1682 "$B< ./a.out \\(aq1 23 43\\(aq>\n"
1683 "size=11; ptr=1 529 1849\n"
1684
1685 #. type: SS
1686 #: build/C/man3/fmemopen.3:293 build/C/man3/fopencookie.3:271
1687 #, no-wrap
1688 msgid "Program source"
1689 msgstr "プログラムのソース"
1690
1691 #. type: Plain text
1692 #: build/C/man3/fmemopen.3:300
1693 #, no-wrap
1694 msgid ""
1695 "#define _GNU_SOURCE\n"
1696 "#include E<lt>string.hE<gt>\n"
1697 "#include E<lt>stdio.hE<gt>\n"
1698 "#include E<lt>stdlib.hE<gt>\n"
1699 msgstr ""
1700 "#define _GNU_SOURCE\n"
1701 "#include E<lt>string.hE<gt>\n"
1702 "#include E<lt>stdio.hE<gt>\n"
1703 "#include E<lt>stdlib.hE<gt>\n"
1704
1705 #. type: Plain text
1706 #: build/C/man3/fmemopen.3:303
1707 #, no-wrap
1708 msgid ""
1709 "#define handle_error(msg) \\e\n"
1710 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
1711 msgstr ""
1712 "#define handle_error(msg) \\e\n"
1713 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
1714
1715 #. type: Plain text
1716 #: build/C/man3/fmemopen.3:311
1717 #, no-wrap
1718 msgid ""
1719 "int\n"
1720 "main(int argc, char *argv[])\n"
1721 "{\n"
1722 "    FILE *out, *in;\n"
1723 "    int v, s;\n"
1724 "    size_t size;\n"
1725 "    char *ptr;\n"
1726 msgstr ""
1727 "int\n"
1728 "main(int argc, char *argv[])\n"
1729 "{\n"
1730 "    FILE *out, *in;\n"
1731 "    int v, s;\n"
1732 "    size_t size;\n"
1733 "    char *ptr;\n"
1734
1735 #. type: Plain text
1736 #: build/C/man3/fmemopen.3:316
1737 #, no-wrap
1738 msgid ""
1739 "    if (argc != 2) {\n"
1740 "\tfprintf(stderr, \"Usage: %s E<lt>fileE<gt>\\en\", argv[0]);\n"
1741 "\texit(EXIT_FAILURE);\n"
1742 "    }\n"
1743 msgstr ""
1744 "    if (argc != 2) {\n"
1745 "\tfprintf(stderr, \"Usage: %s E<lt>fileE<gt>\\en\", argv[0]);\n"
1746 "\texit(EXIT_FAILURE);\n"
1747 "    }\n"
1748
1749 #. type: Plain text
1750 #: build/C/man3/fmemopen.3:320
1751 #, no-wrap
1752 msgid ""
1753 "    in = fmemopen(argv[1], strlen(argv[1]), \"r\");\n"
1754 "    if (in == NULL)\n"
1755 "        handle_error(\"fmemopen\");\n"
1756 msgstr ""
1757 "    in = fmemopen(argv[1], strlen(argv[1]), \"r\");\n"
1758 "    if (in == NULL)\n"
1759 "        handle_error(\"fmemopen\");\n"
1760
1761 #. type: Plain text
1762 #: build/C/man3/fmemopen.3:324
1763 #, no-wrap
1764 msgid ""
1765 "    out = open_memstream(&ptr, &size);\n"
1766 "    if (out == NULL)\n"
1767 "        handle_error(\"open_memstream\");\n"
1768 msgstr ""
1769 "    out = open_memstream(&ptr, &size);\n"
1770 "    if (out == NULL)\n"
1771 "        handle_error(\"open_memstream\");\n"
1772
1773 #. type: Plain text
1774 #: build/C/man3/fmemopen.3:329
1775 #, no-wrap
1776 msgid ""
1777 "    for (;;) {\n"
1778 "        s = fscanf(in, \"%d\", &v);\n"
1779 "        if (s E<lt>= 0)\n"
1780 "            break;\n"
1781 msgstr ""
1782 "    for (;;) {\n"
1783 "        s = fscanf(in, \"%d\", &v);\n"
1784 "        if (s E<lt>= 0)\n"
1785 "            break;\n"
1786
1787 #. type: Plain text
1788 #: build/C/man3/fmemopen.3:340
1789 #, no-wrap
1790 msgid ""
1791 "        s = fprintf(out, \"%d \", v * v);\n"
1792 "        if (s == -1)\n"
1793 "            handle_error(\"fprintf\");\n"
1794 "    }\n"
1795 "    fclose(in);\n"
1796 "    fclose(out);\n"
1797 "    printf(\"size=%ld; ptr=%s\\en\", (long) size, ptr);\n"
1798 "    free(ptr);\n"
1799 "    exit(EXIT_SUCCESS);\n"
1800 "}\n"
1801 msgstr ""
1802 "        s = fprintf(out, \"%d \", v * v);\n"
1803 "        if (s == -1)\n"
1804 "            handle_error(\"fprintf\");\n"
1805 "    }\n"
1806 "    fclose(in);\n"
1807 "    fclose(out);\n"
1808 "    printf(\"size=%ld; ptr=%s\\en\", (long) size, ptr);\n"
1809 "    free(ptr);\n"
1810 "    exit(EXIT_SUCCESS);\n"
1811 "}\n"
1812
1813 #. type: Plain text
1814 #: build/C/man3/fmemopen.3:344
1815 msgid "B<fopen>(3), B<fopencookie>(3)"
1816 msgstr "B<fopen>(3), B<fopencookie>(3)"
1817
1818 #. type: TH
1819 #: build/C/man3/fmtmsg.3:13
1820 #, no-wrap
1821 msgid "FMTMSG"
1822 msgstr "FMTMSG"
1823
1824 #. type: TH
1825 #: build/C/man3/fmtmsg.3:13
1826 #, no-wrap
1827 msgid "2008-06-14"
1828 msgstr "2008-06-14"
1829
1830 #. type: Plain text
1831 #: build/C/man3/fmtmsg.3:16
1832 msgid "fmtmsg - print formatted error messages"
1833 msgstr "fmtmsg - 整形されたエラーメッセージを表示する"
1834
1835 #. type: Plain text
1836 #: build/C/man3/fmtmsg.3:19
1837 #, no-wrap
1838 msgid "B<#include E<lt>fmtmsg.hE<gt>>\n"
1839 msgstr "B<#include E<lt>fmtmsg.hE<gt>>\n"
1840
1841 #. type: Plain text
1842 #: build/C/man3/fmtmsg.3:21
1843 #, no-wrap
1844 msgid "B<int fmtmsg(long >I<classification>B<, const char *>I<label>B<,>\n"
1845 msgstr "B<int fmtmsg(long >I<classification>B<, const char *>I<label>B<,>\n"
1846
1847 #. type: Plain text
1848 #: build/C/man3/fmtmsg.3:23
1849 #, no-wrap
1850 msgid "B<           int >I<severity>B<, const char *>I<text>B<,>\n"
1851 msgstr "B<           int >I<severity>B<, const char *>I<text>B<,>\n"
1852
1853 #. type: Plain text
1854 #: build/C/man3/fmtmsg.3:25
1855 #, no-wrap
1856 msgid "B<           const char *>I<action>B<, const char *>I<tag>B<);>\n"
1857 msgstr "B<           const char *>I<action>B<, const char *>I<tag>B<);>\n"
1858
1859 #. type: Plain text
1860 #: build/C/man3/fmtmsg.3:36
1861 msgid ""
1862 "This function displays a message described by its arguments on the device"
1863 "(s)  specified in the I<classification> argument.  For messages written to "
1864 "I<stderr>, the format depends on the B<MSGVERB> environment variable."
1865 msgstr ""
1866 "この関数は、引き数で記述されたメッセージを、 I<classification> 引き数で指定さ"
1867 "れたデバイス上に表示する。 I<stderr> に書き出されるメッセージのフォーマット"
1868 "は、 B<MSGVERB> 環境変数に依存する。"
1869
1870 #. type: Plain text
1871 #: build/C/man3/fmtmsg.3:43
1872 msgid ""
1873 "The I<label> argument identifies the source of the message.  The string must "
1874 "consist of two colon separated parts where the first part has not more than "
1875 "10 and the second part not more than 14 characters."
1876 msgstr ""
1877 "I<label> 引き数はメッセージの発生源を識別する。 この文字列はコロンで区切られ"
1878 "た 2 つの部分から構成されていなければならない。 1 つ目の部分は 10 文字以内で"
1879 "なければならず、 2 つ目の部分は 14 文字以内でなければならない。"
1880
1881 #. type: Plain text
1882 #: build/C/man3/fmtmsg.3:47
1883 msgid "The I<text> argument describes the condition of the error."
1884 msgstr "I<text> 引き数にはエラー条件を記述する。"
1885
1886 #. type: Plain text
1887 #: build/C/man3/fmtmsg.3:52
1888 msgid ""
1889 "The I<action> argument describes possible steps to recover from the error.  "
1890 "If it is printed, it is prefixed by \"TO FIX: \"."
1891 msgstr ""
1892 "I<action> 引き数にはエラーから回復するために利用可能なステップを記述する。 こ"
1893 "れが表示される場合、\"TO FIX: \" が前に付く。"
1894
1895 #. type: Plain text
1896 #: build/C/man3/fmtmsg.3:60
1897 msgid ""
1898 "The I<tag> argument is a reference to the online documentation where more "
1899 "information can be found.  It should contain the I<label> value and a unique "
1900 "identification number."
1901 msgstr ""
1902 "I<tag> 引き数はより多くの情報を見つけるためのオンラインドキュメントへの参照で"
1903 "ある。 これは I<label> 値とユニークな識別番号を含んでいるべきである。"
1904
1905 #. type: SS
1906 #: build/C/man3/fmtmsg.3:60
1907 #, no-wrap
1908 msgid "Dummy arguments"
1909 msgstr "ダミー引き数"
1910
1911 #. type: Plain text
1912 #: build/C/man3/fmtmsg.3:79
1913 msgid ""
1914 "Each of the arguments can have a dummy value.  The dummy classification "
1915 "value B<MM_NULLMC> (0L) does not specify any output, so nothing is printed.  "
1916 "The dummy severity value B<NO_SEV> (0) says that no severity is supplied.  "
1917 "The values B<MM_NULLLBL>, B<MM_NULLTXT>, B<MM_NULLACT>, B<MM_NULLTAG> are "
1918 "synonyms for I<((char *) 0)>, the empty string, and B<MM_NULLSEV> is a "
1919 "synonym for B<NO_SEV>."
1920 msgstr ""
1921 "各引き数にはダミーの値を入れることができる。 ダミーの I<classification> 値 "
1922 "B<MM_NULLMC> (0L) は出力を何も指定しない。そのため何も表示されない。 ダミー"
1923 "の I<severity> 値 B<NO_SEV> (0) は重大度 (severity) が与えられていないことを"
1924 "表す。 値 B<MM_NULLLBL>, B<MM_NULLTXT>, B<MM_NULLACT>, B<MM_NULLTAG> は I<"
1925 "((char *) 0)> と空文字列の別名であり、 B<MM_NULLSEV> は B<NO_SEV> の別名であ"
1926 "る。"
1927
1928 #. type: SS
1929 #: build/C/man3/fmtmsg.3:79
1930 #, no-wrap
1931 msgid "The classification argument"
1932 msgstr "classification 引き数"
1933
1934 #. type: Plain text
1935 #: build/C/man3/fmtmsg.3:83
1936 msgid ""
1937 "The I<classification> argument is the sum of values describing 4 types of "
1938 "information."
1939 msgstr "I<classification> 引き数は 4 種類の情報を記述する値の和である。"
1940
1941 #. type: Plain text
1942 #: build/C/man3/fmtmsg.3:86
1943 msgid "The first value defines the output channel."
1944 msgstr "最初の値は出力チャンネルを定義する。"
1945
1946 #. type: TP
1947 #: build/C/man3/fmtmsg.3:86
1948 #, no-wrap
1949 msgid "B<MM_PRINT>"
1950 msgstr "B<MM_PRINT>"
1951
1952 #. type: Plain text
1953 #: build/C/man3/fmtmsg.3:90
1954 msgid "Output to I<stderr>."
1955 msgstr "I<stderr> に出力する。"
1956
1957 #. type: TP
1958 #: build/C/man3/fmtmsg.3:90
1959 #, no-wrap
1960 msgid "B<MM_CONSOLE>"
1961 msgstr "B<MM_CONSOLE>"
1962
1963 #. type: Plain text
1964 #: build/C/man3/fmtmsg.3:93
1965 msgid "Output to the system console."
1966 msgstr "システムコンソールに出力する。"
1967
1968 #. type: TP
1969 #: build/C/man3/fmtmsg.3:93
1970 #, no-wrap
1971 msgid "B<MM_PRINT | MM_CONSOLE>"
1972 msgstr "B<MM_PRINT | MM_CONSOLE>"
1973
1974 #. type: Plain text
1975 #: build/C/man3/fmtmsg.3:96
1976 msgid "Output to both."
1977 msgstr "両方に出力する。"
1978
1979 #. type: Plain text
1980 #: build/C/man3/fmtmsg.3:98
1981 msgid "The second value is the source of the error:"
1982 msgstr "2 番目の値はエラーの発生源である:"
1983
1984 #. type: TP
1985 #: build/C/man3/fmtmsg.3:98
1986 #, no-wrap
1987 msgid "B<MM_HARD>"
1988 msgstr "B<MM_HARD>"
1989
1990 #. type: Plain text
1991 #: build/C/man3/fmtmsg.3:101
1992 msgid "A hardware error occurred."
1993 msgstr "ハードウェアエラーが起こった。"
1994
1995 #. type: TP
1996 #: build/C/man3/fmtmsg.3:101
1997 #, no-wrap
1998 msgid "B<MM_FIRM>"
1999 msgstr "B<MM_FIRM>"
2000
2001 #. type: Plain text
2002 #: build/C/man3/fmtmsg.3:104
2003 msgid "A firmware error occurred."
2004 msgstr "ファームウェアエラーが起こった。"
2005
2006 #. type: TP
2007 #: build/C/man3/fmtmsg.3:104
2008 #, no-wrap
2009 msgid "B<MM_SOFT>"
2010 msgstr "B<MM_SOFT>"
2011
2012 #. type: Plain text
2013 #: build/C/man3/fmtmsg.3:107
2014 msgid "A software error occurred."
2015 msgstr "ソフトウェアエラーが起こった。"
2016
2017 #. type: Plain text
2018 #: build/C/man3/fmtmsg.3:109
2019 msgid "The third value encodes the detector of the problem:"
2020 msgstr "3 番目の値は問題の検知を行ったものをエンコードする:"
2021
2022 #. type: TP
2023 #: build/C/man3/fmtmsg.3:109
2024 #, no-wrap
2025 msgid "B<MM_APPL>"
2026 msgstr "B<MM_APPL>"
2027
2028 #. type: Plain text
2029 #: build/C/man3/fmtmsg.3:112
2030 msgid "It is detected by an application."
2031 msgstr "アプリケーションによって検知された。"
2032
2033 #. type: TP
2034 #: build/C/man3/fmtmsg.3:112
2035 #, no-wrap
2036 msgid "B<MM_UTIL>"
2037 msgstr "B<MM_UTIL>"
2038
2039 #. type: Plain text
2040 #: build/C/man3/fmtmsg.3:115
2041 msgid "It is detected by a utility."
2042 msgstr "ユーティリティによって検知された。"
2043
2044 #. type: TP
2045 #: build/C/man3/fmtmsg.3:115
2046 #, no-wrap
2047 msgid "B<MM_OPSYS>"
2048 msgstr "B<MM_OPSYS>"
2049
2050 #. type: Plain text
2051 #: build/C/man3/fmtmsg.3:118
2052 msgid "It is detected by the operating system."
2053 msgstr "オペレーティングシステムによって検知された。"
2054
2055 #. type: Plain text
2056 #: build/C/man3/fmtmsg.3:120
2057 msgid "The fourth value shows the severity of the incident:"
2058 msgstr "4 番目の値は問題の重大度を表す:"
2059
2060 #. type: TP
2061 #: build/C/man3/fmtmsg.3:120
2062 #, no-wrap
2063 msgid "B<MM_RECOVER>"
2064 msgstr "B<MM_RECOVER>"
2065
2066 #. type: Plain text
2067 #: build/C/man3/fmtmsg.3:123
2068 msgid "It is a recoverable error."
2069 msgstr "回復可能なエラーである。"
2070
2071 #. type: TP
2072 #: build/C/man3/fmtmsg.3:123
2073 #, no-wrap
2074 msgid "B<MM_NRECOV>"
2075 msgstr "B<MM_NRECOV>"
2076
2077 #. type: Plain text
2078 #: build/C/man3/fmtmsg.3:126
2079 msgid "It is a nonrecoverable error."
2080 msgstr "回復不可能なエラーである。"
2081
2082 #. type: SS
2083 #: build/C/man3/fmtmsg.3:126
2084 #, no-wrap
2085 msgid "The severity argument"
2086 msgstr "severity 引き数"
2087
2088 #. type: Plain text
2089 #: build/C/man3/fmtmsg.3:130
2090 msgid "The I<severity> argument can take one of the following values:"
2091 msgstr "I<severity> 引き数は以下の 1 つの値をとることができる。"
2092
2093 #. type: TP
2094 #: build/C/man3/fmtmsg.3:130
2095 #, no-wrap
2096 msgid "B<MM_NOSEV>"
2097 msgstr "B<MM_NOSEV>"
2098
2099 #. type: Plain text
2100 #: build/C/man3/fmtmsg.3:133
2101 msgid "No severity is printed."
2102 msgstr "重大度は表示されない。"
2103
2104 #. type: TP
2105 #: build/C/man3/fmtmsg.3:133
2106 #, no-wrap
2107 msgid "B<MM_HALT>"
2108 msgstr "B<MM_HALT>"
2109
2110 #. type: Plain text
2111 #: build/C/man3/fmtmsg.3:136
2112 msgid "This value is printed as HALT."
2113 msgstr "この値は HALT として表示される。"
2114
2115 #. type: TP
2116 #: build/C/man3/fmtmsg.3:136
2117 #, no-wrap
2118 msgid "B<MM_ERROR>"
2119 msgstr "B<MM_ERROR>"
2120
2121 #. type: Plain text
2122 #: build/C/man3/fmtmsg.3:139
2123 msgid "This value is printed as ERROR."
2124 msgstr "この値は ERROR として表示される。"
2125
2126 #. type: TP
2127 #: build/C/man3/fmtmsg.3:139
2128 #, no-wrap
2129 msgid "B<MM_WARNING>"
2130 msgstr "B<MM_WARNING>"
2131
2132 #. type: Plain text
2133 #: build/C/man3/fmtmsg.3:142
2134 msgid "This value is printed as WARNING."
2135 msgstr "この値は WARNING として表示される。"
2136
2137 #. type: TP
2138 #: build/C/man3/fmtmsg.3:142
2139 #, no-wrap
2140 msgid "B<MM_INFO>"
2141 msgstr "B<MM_INFO>"
2142
2143 #. type: Plain text
2144 #: build/C/man3/fmtmsg.3:145
2145 msgid "This value is printed as INFO."
2146 msgstr "この値は INFO として表示される。"
2147
2148 #. type: Plain text
2149 #: build/C/man3/fmtmsg.3:152
2150 msgid ""
2151 "The numeric values are between 0 and 4.  Using B<addseverity>(3)  or the "
2152 "environment variable B<SEV_LEVEL> you can add more levels and strings to "
2153 "print."
2154 msgstr ""
2155 "数値の場合は 0 から 4 である。 B<addseverity>(3)  または環境変数 "
2156 "B<SEV_LEVEL> を使うことにより、表示するレベルと文字列を更に追加できる。"
2157
2158 #. type: Plain text
2159 #: build/C/man3/fmtmsg.3:154
2160 msgid "The function can return 4 values:"
2161 msgstr "関数は 4 つの値を返す:"
2162
2163 #. type: TP
2164 #: build/C/man3/fmtmsg.3:154
2165 #, no-wrap
2166 msgid "B<MM_OK>"
2167 msgstr "B<MM_OK>"
2168
2169 #. type: Plain text
2170 #: build/C/man3/fmtmsg.3:157
2171 msgid "Everything went smooth."
2172 msgstr "全てがうまくいった。"
2173
2174 #. type: TP
2175 #: build/C/man3/fmtmsg.3:157
2176 #, no-wrap
2177 msgid "B<MM_NOTOK>"
2178 msgstr "B<MM_NOTOK>"
2179
2180 #. type: Plain text
2181 #: build/C/man3/fmtmsg.3:160
2182 msgid "Complete failure."
2183 msgstr "完全に失敗した。"
2184
2185 #. type: TP
2186 #: build/C/man3/fmtmsg.3:160
2187 #, no-wrap
2188 msgid "B<MM_NOMSG>"
2189 msgstr "B<MM_NOMSG>"
2190
2191 #. type: Plain text
2192 #: build/C/man3/fmtmsg.3:164
2193 msgid "Error writing to I<stderr>."
2194 msgstr "I<stderr> に書き込むときにエラーが起こった。"
2195
2196 #. type: TP
2197 #: build/C/man3/fmtmsg.3:164
2198 #, no-wrap
2199 msgid "B<MM_NOCON>"
2200 msgstr "B<MM_NOCON>"
2201
2202 #. type: Plain text
2203 #: build/C/man3/fmtmsg.3:167
2204 msgid "Error writing to the console."
2205 msgstr "コンソールに書き込むときにエラーが起こった。"
2206
2207 #. type: SH
2208 #: build/C/man3/fmtmsg.3:167
2209 #, no-wrap
2210 msgid "ENVIRONMENT"
2211 msgstr "環境変数"
2212
2213 #. type: Plain text
2214 #: build/C/man3/fmtmsg.3:178
2215 msgid ""
2216 "The environment variable B<MSGVERB> (\"message verbosity\") can be used to "
2217 "suppress parts of the output to I<stderr>.  (It does not influence output to "
2218 "the console.)  When this variable is defined, is non-NULL, and is a colon-"
2219 "separated list of valid keywords, then only the parts of the message "
2220 "corresponding to these keywords is printed.  Valid keywords are \"label\", "
2221 "\"severity\", \"text\", \"action\" and \"tag\"."
2222 msgstr ""
2223 "環境変数 B<MSGVERB> (\"message verbosity\") は I<stderr> への出力の一部を抑制"
2224 "するのに使うことができる。 (コンソールへの出力には影響しない。)  この変数が定"
2225 "義されて、NULL でなく、 コロンで区切られた有効なキーワードのリストである場"
2226 "合、 キーワードに対応するメッセージの一部のみが表示される。 有効なキーワード"
2227 "は \"label\", \"severity\", \"text\", \"action\", \"tag\" である。"
2228
2229 #. type: Plain text
2230 #: build/C/man3/fmtmsg.3:190
2231 msgid ""
2232 "The environment variable B<SEV_LEVEL> can be used to introduce new severity "
2233 "levels.  By default, only the five severity levels described above are "
2234 "available.  Any other numeric value would make B<fmtmsg>()  print nothing.  "
2235 "If the user puts B<SEV_LEVEL> with a format like"
2236 msgstr ""
2237 "環境変数 B<SEV_LEVEL> は新しい重大度レベルを導入するのに使用できる。 デフォル"
2238 "トでは、上記の 5 つの重大度レベルのみが利用可能である。 他の数値の場合、 "
2239 "B<fmtmsg>()  は何も表示しない。 B<fmtmsg>()  を初めて呼び出す前に、ユーザが "
2240 "B<SEV_LEVEL> を"
2241
2242 #. type: Plain text
2243 #: build/C/man3/fmtmsg.3:193
2244 msgid "SEV_LEVEL=[description[:description[:...]]]"
2245 msgstr "SEV_LEVEL=[description[:description[:...]]]"
2246
2247 #. type: Plain text
2248 #: build/C/man3/fmtmsg.3:198
2249 msgid ""
2250 "in the environment of the process before the first call to B<fmtmsg>(), "
2251 "where each description is of the form"
2252 msgstr ""
2253 "のような形式でプロセスの環境に設定すると、 B<fmtmsg>()  は (標準のレベル 0-4 "
2254 "に加えて) level に指定された値も受け付け、 そのようなレベルの問題が発生すると"
2255 "指定された printstring を表示する。 各 description は"
2256
2257 #. type: Plain text
2258 #: build/C/man3/fmtmsg.3:201
2259 msgid "severity-keyword,level,printstring"
2260 msgstr "severity-keyword,level,printstring"
2261
2262 #. type: Plain text
2263 #: build/C/man3/fmtmsg.3:208
2264 msgid ""
2265 "then B<fmtmsg>()  will also accept the indicated values for the level (in "
2266 "addition to the standard levels 0-4), and use the indicated printstring when "
2267 "such a level occurs."
2268 msgstr "という形式である。"
2269
2270 #. type: Plain text
2271 #: build/C/man3/fmtmsg.3:222
2272 msgid ""
2273 "The severity-keyword part is not used by B<fmtmsg>()  but it has to be "
2274 "present.  The level part is a string representation of a number.  The "
2275 "numeric value must be a number greater than 4.  This value must be used in "
2276 "the severity argument of B<fmtmsg>()  to select this class.  It is not "
2277 "possible to overwrite any of the predefined classes.  The printstring is the "
2278 "string printed when a message of this class is processed by B<fmtmsg>()."
2279 msgstr ""
2280 "severity-keyword 部は B<fmtmsg>()  に使用されないが、存在しなければならな"
2281 "い。 level 部は数値を文字列で表したものである。 数値は 4 より大きい値でなけれ"
2282 "ばならない。 この値は B<fmtmsg>()  の severity 引き数で使用されなければなら"
2283 "ず、この重大度を選択する。 前もって宣言された重大度を上書きすることはできな"
2284 "い。 printstring は、 この重大度のメッセージが B<fmtmsg>()  によって生成され"
2285 "た場合に表示される文字列である。"
2286
2287 #. type: Plain text
2288 #: build/C/man3/fmtmsg.3:225
2289 msgid "B<fmtmsg>()  is provided in glibc since version 2.1."
2290 msgstr "B<fmtmsg>()  は、バージョン 2.1 以降の glibc で提供されている。"
2291
2292 #. type: Plain text
2293 #: build/C/man3/fmtmsg.3:240
2294 msgid ""
2295 "The functions B<fmtmsg>()  and B<addseverity>(3), and environment variables "
2296 "B<MSGVERB> and B<SEV_LEVEL> come from System V.  The function B<fmtmsg>()  "
2297 "and the environment variable B<MSGVERB> are described in POSIX.1-2001."
2298 msgstr ""
2299 "関数 B<fmtmsg>()  と B<addseverity>(3)  と環境変数 B<MSGVERB> と "
2300 "B<SEV_LEVEL> は System V に由来している。 関数 B<fmtmsg>()  と環境変数 "
2301 "B<MSGVERB> は POSIX.1-2001 に記述されている。"
2302
2303 #. type: Plain text
2304 #: build/C/man3/fmtmsg.3:244
2305 msgid ""
2306 "System V and UnixWare man pages tell us that these functions have been "
2307 "replaced by \"pfmt() and addsev()\" or by \"pfmt(), vpfmt(), lfmt(), and "
2308 "vlfmt()\", and will be removed later."
2309 msgstr ""
2310 "System V と UnixWare の man ページには、 「これらの関数は \"pfmt() と addsev"
2311 "()\" または \"pfmt(), vpfmt(), lfmt(), vlfmt()\" で置き換えられており、 将来"
2312 "は削除される予定である」と書かれている。"
2313
2314 #. type: Plain text
2315 #: build/C/man3/fmtmsg.3:249
2316 #, no-wrap
2317 msgid ""
2318 "#include E<lt>stdio.hE<gt>\n"
2319 "#include E<lt>stdlib.hE<gt>\n"
2320 "#include E<lt>fmtmsg.hE<gt>\n"
2321 msgstr ""
2322 "#include E<lt>stdio.hE<gt>\n"
2323 "#include E<lt>stdlib.hE<gt>\n"
2324 "#include E<lt>fmtmsg.hE<gt>\n"
2325
2326 #. type: Plain text
2327 #: build/C/man3/fmtmsg.3:255
2328 #, no-wrap
2329 msgid ""
2330 "int\n"
2331 "main(void)\n"
2332 "{\n"
2333 "    long class = MM_PRINT | MM_SOFT | MM_OPSYS | MM_RECOVER;\n"
2334 "    int err;\n"
2335 msgstr ""
2336 "int\n"
2337 "main(void)\n"
2338 "{\n"
2339 "    long class = MM_PRINT | MM_SOFT | MM_OPSYS | MM_RECOVER;\n"
2340 "    int err;\n"
2341
2342 #. type: Plain text
2343 #: build/C/man3/fmtmsg.3:276
2344 #, no-wrap
2345 msgid ""
2346 "    err = fmtmsg(class, \"util-linux:mount\", MM_ERROR,\n"
2347 "                \"unknown mount option\", \"See mount(8).\",\n"
2348 "                \"util-linux:mount:017\");\n"
2349 "    switch (err) {\n"
2350 "    case MM_OK:\n"
2351 "        break;\n"
2352 "    case MM_NOTOK:\n"
2353 "        printf(\"Nothing printed\\en\");\n"
2354 "        break;\n"
2355 "    case MM_NOMSG:\n"
2356 "        printf(\"Nothing printed to stderr\\en\");\n"
2357 "        break;\n"
2358 "    case MM_NOCON:\n"
2359 "        printf(\"No console output\\en\");\n"
2360 "        break;\n"
2361 "    default:\n"
2362 "        printf(\"Unknown error from fmtmsg()\\en\");\n"
2363 "    }\n"
2364 "    exit(EXIT_SUCCESS);\n"
2365 "}\n"
2366 msgstr ""
2367 "    err = fmtmsg(class, \"util-linux:mount\", MM_ERROR,\n"
2368 "                \"unknown mount option\", \"See mount(8).\",\n"
2369 "                \"util-linux:mount:017\");\n"
2370 "    switch (err) {\n"
2371 "    case MM_OK:\n"
2372 "      break;\n"
2373 "    case MM_NOTOK:\n"
2374 "        printf(\"Nothing printed\\en\");\n"
2375 "        break;\n"
2376 "    case MM_NOMSG:\n"
2377 "        printf(\"Nothing printed to stderr\\en\");\n"
2378 "        break;\n"
2379 "    case MM_NOCON:\n"
2380 "        printf(\"No console output\\en\");\n"
2381 "        break;\n"
2382 "    default:\n"
2383 "        printf(\"Unknown error from fmtmsg()\\en\");\n"
2384 "    }\n"
2385 "    exit(EXIT_SUCCESS);\n"
2386 "}\n"
2387
2388 #. type: Plain text
2389 #: build/C/man3/fmtmsg.3:279
2390 msgid "The output should be:"
2391 msgstr "出力は"
2392
2393 #. type: Plain text
2394 #: build/C/man3/fmtmsg.3:283
2395 #, no-wrap
2396 msgid ""
2397 "    util-linux:mount: ERROR: unknown mount option\n"
2398 "    TO FIX: See mount(8).  util-linux:mount:017\n"
2399 msgstr ""
2400 "    util-linux:mount: ERROR: unknown mount option\n"
2401 "    TO FIX: See mount(8).  util-linux:mount:017\n"
2402
2403 #. type: Plain text
2404 #: build/C/man3/fmtmsg.3:286
2405 msgid "and after"
2406 msgstr "のようになり、"
2407
2408 #. type: Plain text
2409 #: build/C/man3/fmtmsg.3:289
2410 #, no-wrap
2411 msgid "    MSGVERB=text:action; export MSGVERB\n"
2412 msgstr "    MSGVERB=text:action; export MSGVERB\n"
2413
2414 #. type: Plain text
2415 #: build/C/man3/fmtmsg.3:292
2416 msgid "the output becomes:"
2417 msgstr "を実行すると、次のようになる。"
2418
2419 #. type: Plain text
2420 #: build/C/man3/fmtmsg.3:296
2421 #, no-wrap
2422 msgid ""
2423 "    unknown mount option\n"
2424 "    TO FIX: See mount(8).\n"
2425 msgstr ""
2426 "    unknown mount option\n"
2427 "    TO FIX: See mount(8).\n"
2428
2429 #. type: Plain text
2430 #: build/C/man3/fmtmsg.3:300
2431 msgid "B<addseverity>(3), B<perror>(3)"
2432 msgstr "B<addseverity>(3), B<perror>(3)"
2433
2434 #. type: TH
2435 #: build/C/man3/fopen.3:44
2436 #, no-wrap
2437 msgid "FOPEN"
2438 msgstr "FOPEN"
2439
2440 #. type: TH
2441 #: build/C/man3/fopen.3:44
2442 #, no-wrap
2443 msgid "2012-04-22"
2444 msgstr "2012-04-22"
2445
2446 #. type: Plain text
2447 #: build/C/man3/fopen.3:47
2448 msgid "fopen, fdopen, freopen - stream open functions"
2449 msgstr "fopen, fdopen, freopen - ストリームを開く関数"
2450
2451 #. type: Plain text
2452 #: build/C/man3/fopen.3:52
2453 #, no-wrap
2454 msgid "B<FILE *fopen(const char *>I<path>B<, const char *>I<mode>B<);>\n"
2455 msgstr "B<FILE *fopen(const char *>I<path>B<, const char *>I<mode>B<);>\n"
2456
2457 #. type: Plain text
2458 #: build/C/man3/fopen.3:54
2459 #, no-wrap
2460 msgid "B<FILE *fdopen(int >I<fd>B<, const char *>I<mode>B<);>\n"
2461 msgstr "B<FILE *fdopen(int >I<fd>B<, const char *>I<mode>B<);>\n"
2462
2463 #. type: Plain text
2464 #: build/C/man3/fopen.3:56
2465 #, no-wrap
2466 msgid "B<FILE *freopen(const char *>I<path>B<, const char *>I<mode>B<, FILE *>I<stream>B<);>\n"
2467 msgstr "B<FILE *freopen(const char *>I<path>B<, const char *>I<mode>B<, FILE *>I<stream>B<);>\n"
2468
2469 #. type: Plain text
2470 #: build/C/man3/fopen.3:65
2471 msgid ""
2472 "B<fdopen>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
2473 msgstr ""
2474 "B<fdopen>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
2475
2476 #. type: Plain text
2477 #: build/C/man3/fopen.3:71
2478 msgid ""
2479 "The B<fopen>()  function opens the file whose name is the string pointed to "
2480 "by I<path> and associates a stream with it."
2481 msgstr ""
2482 "B<fopen>()  関数は、 I<path> で指定された名前のファイルを開き、ストリームと結"
2483 "びつける。"
2484
2485 #. type: Plain text
2486 #: build/C/man3/fopen.3:76
2487 msgid ""
2488 "The argument I<mode> points to a string beginning with one of the following "
2489 "sequences (possibly followed by additional characters, as described below):"
2490 msgstr ""
2491 "引数 I<mode> は、以下に続く文字のひとつから始まる文字列へのポインタであ\n"
2492 "る (以下の述べる、追加の文字が後に続くこともある):"
2493
2494 #. type: TP
2495 #: build/C/man3/fopen.3:76
2496 #, no-wrap
2497 msgid "B<r>"
2498 msgstr "B<r>"
2499
2500 #. type: Plain text
2501 #: build/C/man3/fopen.3:80
2502 msgid ""
2503 "Open text file for reading.  The stream is positioned at the beginning of "
2504 "the file."
2505 msgstr ""
2506 "テキストファイルを読み出すために開く。 ストリームはファイルの先頭に位置され"
2507 "る。"
2508
2509 #. type: TP
2510 #: build/C/man3/fopen.3:80
2511 #, no-wrap
2512 msgid "B<r+>"
2513 msgstr "B<r+>"
2514
2515 #. type: Plain text
2516 #: build/C/man3/fopen.3:84
2517 msgid ""
2518 "Open for reading and writing.  The stream is positioned at the beginning of "
2519 "the file."
2520 msgstr ""
2521 "読み出しおよび書き込みするために開く。 ストリームはファイルの先頭に位置され"
2522 "る。"
2523
2524 #. type: TP
2525 #: build/C/man3/fopen.3:84
2526 #, no-wrap
2527 msgid "B<w>"
2528 msgstr "B<w>"
2529
2530 #. type: Plain text
2531 #: build/C/man3/fopen.3:88
2532 msgid ""
2533 "Truncate file to zero length or create text file for writing.  The stream is "
2534 "positioned at the beginning of the file."
2535 msgstr ""
2536 "ファイルを書き込みのために開く。 ファイルが既に存在する場合には長さゼロに切り"
2537 "詰める。 ファイルがなかった場合には新たに作成する。 ストリームはファイルの先"
2538 "頭に位置される。"
2539
2540 #. type: TP
2541 #: build/C/man3/fopen.3:88
2542 #, no-wrap
2543 msgid "B<w+>"
2544 msgstr "B<w+>"
2545
2546 #. type: Plain text
2547 #: build/C/man3/fopen.3:94
2548 msgid ""
2549 "Open for reading and writing.  The file is created if it does not exist, "
2550 "otherwise it is truncated.  The stream is positioned at the beginning of the "
2551 "file."
2552 msgstr ""
2553 "読み出しおよび書き込みのために開く。 ファイルが存在していない場合には新たに作"
2554 "成する。 存在している場合には長さゼロに切り詰められる。 ストリームはファイル"
2555 "の先頭に位置される。"
2556
2557 #. type: TP
2558 #: build/C/man3/fopen.3:94 build/C/man3/scanf.3:447
2559 #, no-wrap
2560 msgid "B<a>"
2561 msgstr "B<a>"
2562
2563 #. type: Plain text
2564 #: build/C/man3/fopen.3:99
2565 msgid ""
2566 "Open for appending (writing at end of file).  The file is created if it does "
2567 "not exist.  The stream is positioned at the end of the file."
2568 msgstr ""
2569 "追加 (ファイルの最後に書き込む) のために開く。 ファイルが存在していない場合に"
2570 "は新たに作成する。 ストリームはファイルの最後に位置される。"
2571
2572 #. type: TP
2573 #: build/C/man3/fopen.3:99
2574 #, no-wrap
2575 msgid "B<a+>"
2576 msgstr "B<a+>"
2577
2578 #. type: Plain text
2579 #: build/C/man3/fopen.3:105
2580 msgid ""
2581 "Open for reading and appending (writing at end of file).  The file is "
2582 "created if it does not exist.  The initial file position for reading is at "
2583 "the beginning of the file, but output is always appended to the end of the "
2584 "file."
2585 msgstr ""
2586 "読み出しおよび追加 (ファイルの最後に書き込む) のために開く。 ファイルが存在し"
2587 "ていない場合には新たに作成する。 読み出しの初期ファイル位置はファイルの先頭で"
2588 "あるが、 書き込みは常にファイルの最後に追加される。"
2589
2590 #. type: Plain text
2591 #: build/C/man3/fopen.3:118
2592 msgid ""
2593 "The I<mode> string can also include the letter \\(aqb\\(aq either as a last "
2594 "character or as a character between the characters in any of the two-"
2595 "character strings described above.  This is strictly for compatibility with "
2596 "C89 and has no effect; the \\(aqb\\(aq is ignored on all POSIX conforming "
2597 "systems, including Linux.  (Other systems may treat text files and binary "
2598 "files differently, and adding the \\(aqb\\(aq may be a good idea if you do I/"
2599 "O to a binary file and expect that your program may be ported to non-UNIX "
2600 "environments.)"
2601 msgstr ""
2602 "I<mode> 文字列には文字 \\(aqb\\(aq を追加指定することができ、 I<mode> 文字列"
2603 "の最後の文字として指定する。 上記のうち 2 文字のモードの場合には 2 つの文字の"
2604 "間に指定することもできる。 これは C89 との互換性のためだけに用意された もので"
2605 "あり、関数の実行に対してはいかなる影響も持たない。 すなわち、Linux を含む全て"
2606 "の POSIX 準拠システムでは、 この \\(aqb\\(aq は無視される。 (その他のシステム"
2607 "ではテキストファイルとバイナリファイルを別々に扱うものもあるので、 もしバイナ"
2608 "リファイルの入出力を行い、 そのプログラムが非 UNIX 環境へ移植されると予測する"
2609 "なら、 \\(aqb\\(aqを付けておくのは良い考えである)"
2610
2611 #. type: Plain text
2612 #: build/C/man3/fopen.3:121
2613 msgid "See NOTES below for details of glibc extensions for I<mode>."
2614 msgstr "I<mode> の glibc による拡張の詳細については下記の「注意」を参照。"
2615
2616 #. type: Plain text
2617 #: build/C/man3/fopen.3:126
2618 msgid ""
2619 "Any created files will have mode B<S_IRUSR> | B<S_IWUSR> | B<S_IRGRP> | "
2620 "B<S_IWGRP> | B<S_IROTH> | B<S_IWOTH> (0666), as modified by the process's "
2621 "umask value (see B<umask>(2))."
2622 msgstr ""
2623 "すべての生成されたファイルは、 B<S_IRUSR> | B<S_IWUSR> | B<S_IRGRP> | "
2624 "B<S_IWGRP> | B<S_IROTH> | B<S_IWOTH> (0666) のモードを そのプロセスの umask "
2625 "値によって修正したモードを持つ (B<umask>(2)  を見よ)。"
2626
2627 #. type: Plain text
2628 #: build/C/man3/fopen.3:141
2629 msgid ""
2630 "Reads and writes may be intermixed on read/write streams in any order.  Note "
2631 "that ANSI C requires that a file positioning function intervene between "
2632 "output and input, unless an input operation encounters end-of-file.  (If "
2633 "this condition is not met, then a read is allowed to return the result of "
2634 "writes other than the most recent.)  Therefore it is good practice (and "
2635 "indeed sometimes necessary under Linux) to put an B<fseek>(3)  or B<fgetpos>"
2636 "(3)  operation between write and read operations on such a stream.  This "
2637 "operation may be an apparent no-op (as in I<fseek(..., 0L, SEEK_CUR)> called "
2638 "for its synchronizing side effect."
2639 msgstr ""
2640 "読み出し/書き込みストリームに対しては任意の順序で読み書きを行うことができ"
2641 "る。 ただし ANSI C では、 (入力操作がファイルの末尾に到達した場合を除いて)  "
2642 "出力と入力の間にはファイルの位置決め関数を 挟まなければならないことになってい"
2643 "ることに注意されたい (この条件を満足しない場合には、読み込み操作は、 最後に書"
2644 "き込まれたものでなく、以前に書き込まれた 値を返すことを許されている)。 した"
2645 "がって、このようなストリームでの読み書き操作の間には B<fseek>(3)  または "
2646 "B<fgetpos>(3)  操作を挟んでおくと良いだろう (Linux では本当に必要となることも"
2647 "ときどきある)。 この操作は見かけ上何もしない操作 (no-op) でも良い (例えば "
2648 "I<fseek(..., 0L, SEEK_CUR)> を その副次的効果である同期のためだけに呼べば良"
2649 "い)。"
2650
2651 #. type: Plain text
2652 #: build/C/man3/fopen.3:146
2653 msgid ""
2654 "Opening a file in append mode (B<a> as the first character of I<mode>)  "
2655 "causes all subsequent write operations to this stream to occur at end-of-"
2656 "file, as if preceded the call:"
2657 msgstr ""
2658 "ファイルを追加モード (I<mode> の最初の文字を B<a> にする) で開くと、\n"
2659 "このストリームに対する書き込み操作は全て (先に以下の呼び出しを行った\n"
2660 "かのように) ファイルの末尾で行われる。"
2661
2662 #. type: Plain text
2663 #: build/C/man3/fopen.3:149
2664 #, no-wrap
2665 msgid "    fseek(stream, 0, SEEK_END);\n"
2666 msgstr "    fseek(stream, 0, SEEK_END);\n"
2667
2668 #. type: Plain text
2669 #: build/C/man3/fopen.3:171
2670 msgid ""
2671 "The B<fdopen>()  function associates a stream with the existing file "
2672 "descriptor, I<fd>.  The I<mode> of the stream (one of the values \"r\", \"r+"
2673 "\", \"w\", \"w+\", \"a\", \"a+\")  must be compatible with the mode of the "
2674 "file descriptor.  The file position indicator of the new stream is set to "
2675 "that belonging to I<fd>, and the error and end-of-file indicators are "
2676 "cleared.  Modes \"w\" or \"w+\" do not cause truncation of the file.  The "
2677 "file descriptor is not dup'ed, and will be closed when the stream created by "
2678 "B<fdopen>()  is closed.  The result of applying B<fdopen>()  to a shared "
2679 "memory object is undefined."
2680 msgstr ""
2681 "B<fdopen>()  関数は、既存のファイル記述子 I<fd> にストリームを結びつける。 ス"
2682 "トリームの I<mode> (\"r\", \"r+\", \"w\", \"w+\", \"a\", \"a+\" のいずれか) "
2683 "は ファイル記述子のモードと互換のものでなければならない。 新しいストリームの"
2684 "ファイル位置指示子は I<fd> に属している値に設定される。 error と end-of-file "
2685 "の各指示子はクリアされる。 \"w\" および \"w+\" モードでのファイルの切り詰めは"
2686 "行われない。 ファイル記述子の複製は行なわれない。 B<fdopen>()  で作成されたス"
2687 "トリームが閉じられたときにファイル記述子も 閉じられる。 共有メモリのオブジェ"
2688 "クトへ B<fdopen>()  を行ったときの結果は定義されていない。"
2689
2690 #. type: Plain text
2691 #: build/C/man3/fopen.3:189
2692 msgid ""
2693 "The B<freopen>()  function opens the file whose name is the string pointed "
2694 "to by I<path> and associates the stream pointed to by I<stream> with it.  "
2695 "The original stream (if it exists) is closed.  The I<mode> argument is used "
2696 "just as in the B<fopen>()  function.  The primary use of the B<freopen>()  "
2697 "function is to change the file associated with a standard text stream "
2698 "(I<stderr>, I<stdin>, or I<stdout>)."
2699 msgstr ""
2700 "B<freopen>()  関数は I<path> で名前が指定されたファイルを開き、 I<stream> で"
2701 "指定されたストリームに、そのファイルを結びつける。 もとのストリームは (もし存"
2702 "在する場合には) 閉じられる。 I<mode> 引数は B<fopen>()  関数と同じ形で使われ"
2703 "る。 B<freopen>()  関数の主な用途は、標準テキストストリーム (I<stderr>, "
2704 "I<stdin>, I<stdout>)  と対応付けられているファイルを変更することである。"
2705
2706 #. type: Plain text
2707 #: build/C/man3/fopen.3:201
2708 msgid ""
2709 "Upon successful completion B<fopen>(), B<fdopen>()  and B<freopen>()  return "
2710 "a I<FILE> pointer.  Otherwise, NULL is returned and I<errno> is set to "
2711 "indicate the error."
2712 msgstr ""
2713 "B<fopen>(), B<fdopen>(), B<freopen>()  は成功すると I<FILE> 型のポインタを返"
2714 "す。 失敗すると NULL が返され、 I<errno> がエラーを示す値にセットされる。"
2715
2716 #. type: TP
2717 #: build/C/man3/fopen.3:202 build/C/man3/fseek.3:142
2718 #: build/C/man3/getline.3:123 build/C/man2/llseek.2:77
2719 #: build/C/man2/lseek.2:175 build/C/man2/pipe.2:102 build/C/man2/read.2:126
2720 #: build/C/man2/read.2:137 build/C/man2/readlink.2:95
2721 #: build/C/man2/readlink.2:104 build/C/man2/readv.2:200
2722 #: build/C/man2/rename.2:139 build/C/man2/rmdir.2:67 build/C/man3/scanf.3:566
2723 #: build/C/man2/write.2:154
2724 #, no-wrap
2725 msgid "B<EINVAL>"
2726 msgstr "B<EINVAL>"
2727
2728 #. type: Plain text
2729 #: build/C/man3/fopen.3:212
2730 msgid ""
2731 "The I<mode> provided to B<fopen>(), B<fdopen>(), or B<freopen>()  was "
2732 "invalid."
2733 msgstr ""
2734 "B<fopen>(), B<fdopen>(), B<freopen>()  で与えられた I<mode> が不適切である。"
2735
2736 #. type: Plain text
2737 #: build/C/man3/fopen.3:222
2738 msgid ""
2739 "The B<fopen>(), B<fdopen>()  and B<freopen>()  functions may also fail and "
2740 "set I<errno> for any of the errors specified for the routine B<malloc>(3)."
2741 msgstr ""
2742 "B<fopen>(), B<fdopen>(), B<freopen>()  関数は B<malloc>(3)  ルーチンで規定さ"
2743 "れているエラーでも失敗することがあり、 その時は対応する値に I<errno> をセット"
2744 "する。"
2745
2746 #. type: Plain text
2747 #: build/C/man3/fopen.3:229
2748 msgid ""
2749 "The B<fopen>()  function may also fail and set I<errno> for any of the "
2750 "errors specified for the routine B<open>(2)."
2751 msgstr ""
2752 "B<fopen>()  関数は B<open>(2)  ルーチンで規定されているエラーでも失敗すること"
2753 "があり、 その時は対応する値に I<errno> をセットする。"
2754
2755 #. type: Plain text
2756 #: build/C/man3/fopen.3:236
2757 msgid ""
2758 "The B<fdopen>()  function may also fail and set I<errno> for any of the "
2759 "errors specified for the routine B<fcntl>(2)."
2760 msgstr ""
2761 "B<fdopen>()  関数は B<fcntl>(2)  ルーチンで規定されているエラーでも失敗するこ"
2762 "とがあり、 その時は対応する値に I<errno> をセットする。"
2763
2764 #. type: Plain text
2765 #: build/C/man3/fopen.3:246
2766 msgid ""
2767 "The B<freopen>()  function may also fail and set I<errno> for any of the "
2768 "errors specified for the routines B<open>(2), B<fclose>(3)  and B<fflush>(3)."
2769 msgstr ""
2770 "B<freopen>()  関数は B<open>(2), B<fclose>(3), B<fflush>(3)  各ルーチンで規定"
2771 "されているエラーでも失敗することがあり、 その時は対応する値に I<errno> をセッ"
2772 "トする。"
2773
2774 #. type: Plain text
2775 #: build/C/man3/fopen.3:255
2776 msgid ""
2777 "The B<fopen>()  and B<freopen>()  functions conform to C89.  The B<fdopen>"
2778 "()  function conforms to POSIX.1-1990."
2779 msgstr ""
2780 "B<fopen>()  関数と B<freopen>()  関数は C89に準拠している。 B<fdopen>()  関数"
2781 "は POSIX.1-1990 に準拠している。"
2782
2783 #. type: SS
2784 #: build/C/man3/fopen.3:256
2785 #, no-wrap
2786 msgid "Glibc notes"
2787 msgstr "glibc での注意"
2788
2789 #. type: Plain text
2790 #: build/C/man3/fopen.3:259
2791 msgid ""
2792 "The GNU C library allows the following extensions for the string specified "
2793 "in I<mode>:"
2794 msgstr ""
2795 "GNU C ライブラリでは、 I<mode> に指定できる文字列として、以下の拡張が行われて"
2796 "いる:"
2797
2798 #. type: TP
2799 #: build/C/man3/fopen.3:259
2800 #, no-wrap
2801 msgid "B<c> (since glibc 2.3.3)"
2802 msgstr "B<c> (glibc 2.3.3 以降)"
2803
2804 #. type: Plain text
2805 #: build/C/man3/fopen.3:266
2806 msgid ""
2807 "Do not make the open operation, or subsequent read and write operations, "
2808 "thread cancellation points.  This flag is ignored for B<fdopen>()."
2809 msgstr ""
2810 "open 操作、それに続く read/write 操作の、 スレッドの取り消しポイント\n"
2811 "(cancellation points) を作成しない。\n"
2812 "このフラグは B<fdopen>() では無視される。"
2813
2814 #. type: TP
2815 #: build/C/man3/fopen.3:266
2816 #, no-wrap
2817 msgid "B<e> (since glibc 2.7)"
2818 msgstr "B<e> (glibc 2.7 以降)"
2819
2820 #. type: Plain text
2821 #: build/C/man3/fopen.3:276
2822 msgid ""
2823 "Open the file with the B<O_CLOEXEC> flag.  See B<open>(2)  for more "
2824 "information.  This flag is ignored for B<fdopen>()."
2825 msgstr ""
2826 "B<O_CLOEXEC> フラグを有効にしてファイルをオープンする。詳細は\n"
2827 "B<open>(2) を参照。このフラグは B<fdopen>() では無視される。"
2828
2829 #. type: TP
2830 #: build/C/man3/fopen.3:276
2831 #, no-wrap
2832 msgid "B<m> (since glibc 2.3)"
2833 msgstr "B<m> (glibc 2.3 以降)"
2834
2835 #.  As at glibc 2.4:
2836 #. type: Plain text
2837 #: build/C/man3/fopen.3:288
2838 #, fuzzy
2839 #| msgid ""
2840 #| "Attempt to access the file using B<mmap>(2), rather than I/O system calls "
2841 #| "(B<read>(2), B<write>(2)).  Currently, use of B<mmap>(2)  is only "
2842 #| "attempted for a file opened for reading."
2843 msgid ""
2844 "Attempt to access the file using B<mmap>(2), rather than I/O system calls "
2845 "(B<read>(2), B<write>(2)).  Currently, use of B<mmap>(2)  is attempted only "
2846 "for a file opened for reading."
2847 msgstr ""
2848 "I/O システムコール (B<read>(2), B<write>(2))  ではなく、 B<mmap>(2)  を使って"
2849 "ファイルにアクセスしようとする。 B<mmap>(2)  を使おうとするのは、読み出し用に"
2850 "オープンするファイルについてだけである。"
2851
2852 #. type: TP
2853 #: build/C/man3/fopen.3:288 build/C/man3/scanf.3:421
2854 #, no-wrap
2855 msgid "B<x>"
2856 msgstr "B<x>"
2857
2858 #.  Since glibc 2.0?
2859 #.  FIXME C11 specifies this flag
2860 #. type: Plain text
2861 #: build/C/man3/fopen.3:305
2862 msgid ""
2863 "Open the file exclusively (like the B<O_EXCL> flag of B<open>(2)).  If the "
2864 "file already exists, B<fopen>()  fails, and sets I<errno> to B<EEXIST>.  "
2865 "This flag is ignored for B<fdopen>()."
2866 msgstr ""
2867 "ファイルを排他的にオープンする (B<open>(2)  の B<O_EXCL> フラグと同様)。 ファ"
2868 "イルがすでに存在する場合、 B<fopen>()  は失敗し、 I<errno> に B<EEXIST> が"
2869 "セットされる。 このフラグは B<fdopen>()  では無視される。"
2870
2871 #. type: Plain text
2872 #: build/C/man3/fopen.3:313
2873 msgid ""
2874 "In addition to the above characters, B<fopen>()  and B<freopen>()  support "
2875 "the following syntax in I<mode>:"
2876 msgstr ""
2877 "上記の文字に加えて、\n"
2878 "B<fopen>() と B<freopen>() では I<mode> に\n"
2879 "以下の書式を 指定することができる。"
2880
2881 #. type: Plain text
2882 #: build/C/man3/fopen.3:315
2883 msgid "B< ,ccs=>I<string>"
2884 msgstr "B< ,ccs=>I<string>"
2885
2886 #. type: Plain text
2887 #: build/C/man3/fopen.3:331
2888 msgid ""
2889 "The given I<string> is taken as the name of a coded character set and the "
2890 "stream is marked as wide-oriented.  Thereafter, internal conversion "
2891 "functions convert I/O to and from the character set I<string>.  If the B<,"
2892 "ccs=>I<string> syntax is not specified, then the wide-orientation of the "
2893 "stream is determined by the first file operation.  If that operation is a "
2894 "wide-character operation, the stream is marked wide-oriented, and functions "
2895 "to convert to the coded character set are loaded."
2896 msgstr ""
2897 "指定された I<string> は、符号化文字集合の名前と解釈され、\n"
2898 "ストリームではワイド文字のストリームとして扱われる。\n"
2899 "内部変換関数で入出力時に文字集合 I<string> との変換が行われる。\n"
2900 "書式 B<,ccs=>I<string> が指定されない場合は、\n"
2901 "ストリームをワイド文字のストリームとして扱うかは\n"
2902 "最初のファイル操作時に決定される。\n"
2903 "最初のファイル操作がワイド文字操作であった場合は、\n"
2904 "そのストリームはワイド文字のストリームとして扱われ、\n"
2905 "符号化文字集合との変換を行う関数が読み込まれる。"
2906
2907 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=12685
2908 #. type: Plain text
2909 #: build/C/man3/fopen.3:348
2910 msgid ""
2911 "When parsing for individual flag characters in I<mode> (i.e., the characters "
2912 "preceding the \"ccs\" specification), the glibc implementation of B<fopen>"
2913 "()  and B<freopen>()  limits the number of characters examined in I<mode> to "
2914 "7 (or, in glibc versions before 2.14, to 6, which was not enough to include "
2915 "possible specifications such as \"rb+cmxe\").  The current implementation of "
2916 "B<fdopen>()  parses at most 5 characters in I<mode>."
2917 msgstr ""
2918 "I<mode> の個々のフラグ文字 (\"ccs\" 指定の前の文字) を解釈する際に、\n"
2919 "glibc の B<fopen>() と B<freopen>() の実装では、\n"
2920 "I<mode> の確認を最大 7 文字しか行わないという制限がある\n"
2921 "(バージョン 2.14 より前の glibc では最大 6 文字だが、\n"
2922 "6 文字では \"rb+cmxe\" などの指定を行うには不十分であった)。\n"
2923 "B<fdopen>() の現在の実装では最大 5 文字の I<mode> しか解釈されない。"
2924
2925 #. type: Plain text
2926 #: build/C/man3/fopen.3:354
2927 msgid ""
2928 "B<open>(2), B<fclose>(3), B<fileno>(3), B<fmemopen>(3), B<fopencookie>(3)"
2929 msgstr ""
2930 "B<open>(2), B<fclose>(3), B<fileno>(3), B<fmemopen>(3), B<fopencookie>(3)"
2931
2932 #. type: TH
2933 #: build/C/man3/fopencookie.3:26
2934 #, no-wrap
2935 msgid "FOPENCOOKIE"
2936 msgstr "FOPENCOOKIE"
2937
2938 #. type: TH
2939 #: build/C/man3/fopencookie.3:26
2940 #, fuzzy, no-wrap
2941 #| msgid "2013-03-05"
2942 msgid "2013-03-17"
2943 msgstr "2013-03-05"
2944
2945 #. type: TH
2946 #: build/C/man3/fopencookie.3:26 build/C/man2/link.2:31
2947 #: build/C/man2/llseek.2:28 build/C/man2/lseek.2:47 build/C/man3/lseek64.3:25
2948 #: build/C/man2/open.2:52 build/C/man2/pipe.2:36 build/C/man2/read.2:35
2949 #: build/C/man2/readlink.2:43 build/C/man2/readv.2:32 build/C/man2/rename.2:32
2950 #: build/C/man2/rmdir.2:30 build/C/man3/setbuf.3:48 build/C/man3/stdin.3:13
2951 #: build/C/man2/symlink.2:32 build/C/man7/symlink.7:36
2952 #: build/C/man2/unlink.2:32 build/C/man2/write.2:39
2953 #, no-wrap
2954 msgid "Linux"
2955 msgstr "Linux"
2956
2957 #. type: Plain text
2958 #: build/C/man3/fopencookie.3:29
2959 msgid "fopencookie - opening a custom stream"
2960 msgstr ""
2961
2962 #. type: Plain text
2963 #: build/C/man3/fopencookie.3:36
2964 #, no-wrap
2965 msgid ""
2966 "B<FILE *fopencookie(void *>I<cookie>B<, const char *>I<mode>B<,>\n"
2967 "B<                  cookie_io_functions_t >I<io_funcs>B<);>\n"
2968 msgstr ""
2969 "B<FILE *fopencookie(void *>I<cookie>B<, const char *>I<mode>B<,>\n"
2970 "B<                  cookie_io_functions_t >I<io_funcs>B<);>\n"
2971
2972 #. type: Plain text
2973 #: build/C/man3/fopencookie.3:49
2974 msgid ""
2975 "The B<fopencookie>()  function allows the programmer to create a custom "
2976 "implementation for a standard I/O stream.  This implementation can store the "
2977 "stream's data at a location of its own choosing; for example, B<fopencookie>"
2978 "()  is used to implement B<fmemopen>(3), which provides a stream interface "
2979 "to data that is stored in a buffer in memory."
2980 msgstr ""
2981
2982 #. type: Plain text
2983 #: build/C/man3/fopencookie.3:51
2984 msgid "In order to create a custom stream the programmer must:"
2985 msgstr ""
2986
2987 #. type: IP
2988 #: build/C/man3/fopencookie.3:51 build/C/man3/fopencookie.3:54
2989 #: build/C/man3/fopencookie.3:65 build/C/man3/scanf.3:634
2990 #: build/C/man3/scanf.3:639 build/C/man3/scanf.3:645
2991 #: build/C/man7/symlink.7:249 build/C/man7/symlink.7:259
2992 #: build/C/man7/symlink.7:289 build/C/man7/symlink.7:349
2993 #: build/C/man7/symlink.7:378 build/C/man7/symlink.7:407
2994 #: build/C/man7/symlink.7:438 build/C/man7/symlink.7:451
2995 #, no-wrap
2996 msgid "*"
2997 msgstr "*"
2998
2999 #. type: Plain text
3000 #: build/C/man3/fopencookie.3:54
3001 msgid ""
3002 "Implement four \"hook\" functions that are used internally by the standard I/"
3003 "O library when performing I/O on the stream."
3004 msgstr ""
3005
3006 #. type: Plain text
3007 #: build/C/man3/fopencookie.3:65
3008 msgid ""
3009 "Define a \"cookie\" data type, a structure that provides bookkeeping "
3010 "information (e.g., where to store data) used by the aforementioned hook "
3011 "functions.  The standard I/O package knows nothing about the contents of "
3012 "this cookie (thus it is typed as I<void\\ *> when passed to B<fopencookie>"
3013 "()), but automatically supplies the cookie as the first argument when "
3014 "calling the hook functions."
3015 msgstr ""
3016
3017 #. type: Plain text
3018 #: build/C/man3/fopencookie.3:70
3019 msgid ""
3020 "Call B<fopencookie>()  to open a new stream and associate the cookie and "
3021 "hook functions with that stream."
3022 msgstr ""
3023
3024 #. type: Plain text
3025 #: build/C/man3/fopencookie.3:78
3026 msgid ""
3027 "The B<fopencookie>()  function serves a purpose similar to B<fopen>(3): it "
3028 "opens a new stream and returns a pointer to a I<FILE> object that is used to "
3029 "operate on that stream."
3030 msgstr ""
3031
3032 #. type: Plain text
3033 #: build/C/man3/fopencookie.3:85
3034 msgid ""
3035 "The I<cookie> argument is a pointer to the caller's cookie structure that is "
3036 "to be associated with the new stream.  This pointer is supplied as the first "
3037 "argument when the standard I/O library invokes any of the hook functions "
3038 "described below."
3039 msgstr ""
3040
3041 #. type: Plain text
3042 #: build/C/man3/fopencookie.3:101
3043 msgid ""
3044 "The I<mode> argument serves the same purpose as for B<fopen>(3).  The "
3045 "following modes are supported: I<r>, I<w>, I<a>, I<r+>, I<w+>, and I<a+>.  "
3046 "See B<fopen>(3)  for details."
3047 msgstr ""
3048
3049 #. type: Plain text
3050 #: build/C/man3/fopencookie.3:107
3051 msgid ""
3052 "The I<io_funcs> argument is a structure that contains four fields pointing "
3053 "to the programmer-defined hook functions that are used to implement this "
3054 "stream.  The structure is defined as follows"
3055 msgstr ""
3056
3057 #. type: Plain text
3058 #: build/C/man3/fopencookie.3:116
3059 #, fuzzy, no-wrap
3060 #| msgid ""
3061 #| "struct cookie_io_functions_t {\n"
3062 #| "    cookie_read_function_t  *read;\n"
3063 #| "    cookie_write_function_t *write;\n"
3064 #| "    cookie_seek_function_t  *seek;\n"
3065 #| "    cookie_close_function_t *close;\n"
3066 #| "};\n"
3067 msgid ""
3068 "typedef struct {\n"
3069 "    cookie_read_function_t  *read;\n"
3070 "    cookie_write_function_t *write;\n"
3071 "    cookie_seek_function_t  *seek;\n"
3072 "    cookie_close_function_t *close;\n"
3073 "} cookie_io_functions_t;\n"
3074 msgstr ""
3075 "struct cookie_io_functions_t {\n"
3076 "    cookie_read_function_t  *read;\n"
3077 "    cookie_write_function_t *write;\n"
3078 "    cookie_seek_function_t  *seek;\n"
3079 "    cookie_close_function_t *close;\n"
3080 "};\n"
3081
3082 #. type: Plain text
3083 #: build/C/man3/fopencookie.3:120
3084 msgid "The four fields are as follows:"
3085 msgstr ""
3086
3087 #. type: TP
3088 #: build/C/man3/fopencookie.3:120
3089 #, no-wrap
3090 msgid "I<cookie_read_function_t *read>"
3091 msgstr "I<cookie_read_function_t *read>"
3092
3093 #. type: Plain text
3094 #: build/C/man3/fopencookie.3:124
3095 msgid ""
3096 "This function implements read operations for the stream.  When called, it "
3097 "receives three arguments:"
3098 msgstr ""
3099
3100 #. type: Plain text
3101 #: build/C/man3/fopencookie.3:126
3102 #, no-wrap
3103 msgid "    ssize_t read(void *cookie, char *buf, size_t size);\n"
3104 msgstr "    ssize_t read(void *cookie, char *buf, size_t size);\n"
3105
3106 #. type: Plain text
3107 #: build/C/man3/fopencookie.3:141
3108 msgid ""
3109 "The I<buf> and I<size> arguments are, respectively, a buffer into which "
3110 "input data can be placed and the size of that buffer.  As its function "
3111 "result, the I<read> function should return the number of bytes copied into "
3112 "I<buf>, 0 on end of file, or -1 on error.  The I<read> function should "
3113 "update the stream offset appropriately."
3114 msgstr ""
3115
3116 #. type: Plain text
3117 #: build/C/man3/fopencookie.3:146
3118 msgid ""
3119 "If I<*read> is a NULL pointer, then reads from the custom stream always "
3120 "return end of file."
3121 msgstr ""
3122
3123 #. type: TP
3124 #: build/C/man3/fopencookie.3:146
3125 #, no-wrap
3126 msgid "I<cookie_write_function_t *write>"
3127 msgstr "I<cookie_write_function_t *write>"
3128
3129 #. type: Plain text
3130 #: build/C/man3/fopencookie.3:150
3131 msgid ""
3132 "This function implements write operations for the stream.  When called, it "
3133 "receives three arguments:"
3134 msgstr ""
3135
3136 #. type: Plain text
3137 #: build/C/man3/fopencookie.3:152
3138 #, no-wrap
3139 msgid "    ssize_t write(void *cookie, const char *buf, size_t size);\n"
3140 msgstr "    ssize_t write(void *cookie, const char *buf, size_t size);\n"
3141
3142 #. type: Plain text
3143 #: build/C/man3/fopencookie.3:168
3144 msgid ""
3145 "The I<buf> and I<size> arguments are, respectively, a buffer of data to be "
3146 "output to the stream and the size of that buffer.  As its function result, "
3147 "the I<write> function should return the number of bytes copied from I<buf>, "
3148 "or 0 on error.  (The function must not return a negative value.)  The "
3149 "I<write> function should update the stream offset appropriately."
3150 msgstr ""
3151
3152 #. type: Plain text
3153 #: build/C/man3/fopencookie.3:173
3154 msgid "If I<*write> is a NULL pointer, then output to the stream is discarded."
3155 msgstr ""
3156
3157 #. type: TP
3158 #: build/C/man3/fopencookie.3:173
3159 #, no-wrap
3160 msgid "I<cookie_seek_function_t *seek>"
3161 msgstr "I<cookie_seek_function_t *seek>"
3162
3163 #. type: Plain text
3164 #: build/C/man3/fopencookie.3:177
3165 msgid ""
3166 "This function implements seek operations on the stream.  When called, it "
3167 "receives three arguments:"
3168 msgstr ""
3169
3170 #. type: Plain text
3171 #: build/C/man3/fopencookie.3:179
3172 #, no-wrap
3173 msgid "    int seek(void *cookie, off64_t *offset, int whence);\n"
3174 msgstr "    int seek(void *cookie, off64_t *offset, int whence);\n"
3175
3176 #. type: Plain text
3177 #: build/C/man3/fopencookie.3:185
3178 msgid ""
3179 "The I<*offset> argument specifies the new file offset depending on which of "
3180 "the following three values is supplied in I<whence>:"
3181 msgstr ""
3182
3183 #. type: TP
3184 #: build/C/man3/fopencookie.3:186 build/C/man2/lseek.2:67
3185 #, no-wrap
3186 msgid "B<SEEK_SET>"
3187 msgstr "B<SEEK_SET>"
3188
3189 #. type: Plain text
3190 #: build/C/man3/fopencookie.3:191
3191 msgid ""
3192 "The stream offset should be set I<*offset> bytes from the start of the "
3193 "stream."
3194 msgstr ""
3195
3196 #. type: TP
3197 #: build/C/man3/fopencookie.3:191 build/C/man2/lseek.2:72
3198 #, no-wrap
3199 msgid "B<SEEK_CUR>"
3200 msgstr "B<SEEK_CUR>"
3201
3202 #. type: Plain text
3203 #: build/C/man3/fopencookie.3:195
3204 msgid "I<*offset> should be added to the current stream offset."
3205 msgstr ""
3206
3207 #. type: TP
3208 #: build/C/man3/fopencookie.3:195 build/C/man2/lseek.2:77
3209 #, no-wrap
3210 msgid "B<SEEK_END>"
3211 msgstr "B<SEEK_END>"
3212
3213 #. type: Plain text
3214 #: build/C/man3/fopencookie.3:199
3215 msgid ""
3216 "The stream offset should be set to the size of the stream plus I<*offset>."
3217 msgstr ""
3218
3219 #. type: Plain text
3220 #: build/C/man3/fopencookie.3:206
3221 msgid ""
3222 "Before returning, the I<seek> function should update I<*offset> to indicate "
3223 "the new stream offset."
3224 msgstr ""
3225
3226 #. type: Plain text
3227 #: build/C/man3/fopencookie.3:210
3228 msgid ""
3229 "As its function result, the I<seek> function should return 0 on success, and "
3230 "-1 on error."
3231 msgstr ""
3232
3233 #. type: Plain text
3234 #: build/C/man3/fopencookie.3:215
3235 msgid ""
3236 "If I<*seek> is a NULL pointer, then it is not possible to perform seek "
3237 "operations on the stream."
3238 msgstr ""
3239
3240 #. type: TP
3241 #: build/C/man3/fopencookie.3:215
3242 #, no-wrap
3243 msgid "I<cookie_close_function_t *close>"
3244 msgstr "I<cookie_close_function_t *close>"
3245
3246 #. type: Plain text
3247 #: build/C/man3/fopencookie.3:221
3248 msgid ""
3249 "This function closes the stream.  The hook function can do things such as "
3250 "freeing buffers allocated for the stream.  When called, it receives one "
3251 "argument:"
3252 msgstr ""
3253
3254 #. type: Plain text
3255 #: build/C/man3/fopencookie.3:223
3256 #, no-wrap
3257 msgid "    int close(void *cookie);\n"
3258 msgstr "    int close(void *cookie);\n"
3259
3260 #. type: Plain text
3261 #: build/C/man3/fopencookie.3:228
3262 msgid ""
3263 "The I<cookie> argument is the cookie that the programmer supplied when "
3264 "calling B<fopencookie>()."
3265 msgstr ""
3266
3267 #. type: Plain text
3268 #: build/C/man3/fopencookie.3:234
3269 msgid ""
3270 "As its function result, the I<close> function should return 0 on success, "
3271 "and B<EOF> on error."
3272 msgstr ""
3273
3274 #. type: Plain text
3275 #: build/C/man3/fopencookie.3:238
3276 msgid ""
3277 "If I<*close> is NULL, then no special action is performed when the stream is "
3278 "closed."
3279 msgstr ""
3280
3281 #.  .SH ERRORS
3282 #.  It's not clear if errno ever gets set...
3283 #. type: Plain text
3284 #: build/C/man3/fopencookie.3:245
3285 msgid ""
3286 "On success B<fopencookie>()  returns a pointer to the new stream.  On error, "
3287 "NULL is returned."
3288 msgstr ""
3289
3290 #. type: Plain text
3291 #: build/C/man3/fopencookie.3:247
3292 msgid "This function is a nonstandard GNU extension."
3293 msgstr ""
3294
3295 #. type: Plain text
3296 #: build/C/man3/fopencookie.3:256
3297 msgid ""
3298 "The program below implements a custom stream whose functionality is similar "
3299 "(but not identical) to that available via B<fmemopen>(3).  It implements a "
3300 "stream whose data is stored in a memory buffer.  The program writes its "
3301 "command-line arguments to the stream, and then seeks through the stream "
3302 "reading two out of every five characters and writing them to standard "
3303 "output.  The following shell session demonstrates the use of the program:"
3304 msgstr ""
3305
3306 #. type: Plain text
3307 #: build/C/man3/fopencookie.3:264
3308 #, no-wrap
3309 msgid ""
3310 "$B< ./a.out \\(aqhello world\\(aq>\n"
3311 "/he/\n"
3312 "/ w/\n"
3313 "/d/\n"
3314 "Reached end of file\n"
3315 msgstr ""
3316 "$B< ./a.out \\(aqhello world\\(aq>\n"
3317 "/he/\n"
3318 "/ w/\n"
3319 "/d/\n"
3320 "Reached end of file\n"
3321
3322 #. type: Plain text
3323 #: build/C/man3/fopencookie.3:271
3324 msgid ""
3325 "Note that a more general version of the program below could be improved to "
3326 "more robustly handle various error situations (e.g., opening a stream with a "
3327 "cookie that already has an open stream; closing a stream that has already "
3328 "been closed)."
3329 msgstr ""
3330
3331 #. type: Plain text
3332 #: build/C/man3/fopencookie.3:280
3333 #, no-wrap
3334 msgid ""
3335 "#define _GNU_SOURCE\n"
3336 "#include E<lt>sys/types.hE<gt>\n"
3337 "#include E<lt>stdio.hE<gt>\n"
3338 "#include E<lt>stdlib.hE<gt>\n"
3339 "#include E<lt>unistd.hE<gt>\n"
3340 "#include E<lt>string.hE<gt>\n"
3341 msgstr ""
3342 "#define _GNU_SOURCE\n"
3343 "#include E<lt>sys/types.hE<gt>\n"
3344 "#include E<lt>stdio.hE<gt>\n"
3345 "#include E<lt>stdlib.hE<gt>\n"
3346 "#include E<lt>unistd.hE<gt>\n"
3347 "#include E<lt>string.hE<gt>\n"
3348
3349 #. type: Plain text
3350 #: build/C/man3/fopencookie.3:282
3351 #, no-wrap
3352 msgid "#define INIT_BUF_SIZE 4\n"
3353 msgstr "#define INIT_BUF_SIZE 4\n"
3354
3355 #. type: Plain text
3356 #: build/C/man3/fopencookie.3:289
3357 #, no-wrap
3358 msgid ""
3359 "struct memfile_cookie {\n"
3360 "    char   *buf;        /* Dynamically sized buffer for data */\n"
3361 "    size_t  allocated;  /* Size of buf */\n"
3362 "    size_t  endpos;     /* Number of characters in buf */\n"
3363 "    off_t   offset;     /* Current file offset in buf */\n"
3364 "};\n"
3365 msgstr ""
3366 "struct memfile_cookie {\n"
3367 "    char   *buf;        /* Dynamically sized buffer for data */\n"
3368 "    size_t  allocated;  /* Size of buf */\n"
3369 "    size_t  endpos;     /* Number of characters in buf */\n"
3370 "    off_t   offset;     /* Current file offset in buf */\n"
3371 "};\n"
3372
3373 #. type: Plain text
3374 #: build/C/man3/fopencookie.3:295
3375 #, no-wrap
3376 msgid ""
3377 "ssize_t\n"
3378 "memfile_write(void *c, const char *buf, size_t size)\n"
3379 "{\n"
3380 "    char *new_buff;\n"
3381 "    struct memfile_cookie *cookie = c;\n"
3382 msgstr ""
3383 "ssize_t\n"
3384 "memfile_write(void *c, const char *buf, size_t size)\n"
3385 "{\n"
3386 "    char *new_buff;\n"
3387 "    struct memfile_cookie *cookie = c;\n"
3388
3389 #. type: Plain text
3390 #: build/C/man3/fopencookie.3:297
3391 #, no-wrap
3392 msgid "    /* Buffer too small? Keep doubling size until big enough */\n"
3393 msgstr "    /* Buffer too small? Keep doubling size until big enough */\n"
3394
3395 #. type: Plain text
3396 #: build/C/man3/fopencookie.3:307
3397 #, no-wrap
3398 msgid ""
3399 "    while (size + cookie-E<gt>offset E<gt> cookie-E<gt>allocated) {\n"
3400 "        new_buff = realloc(cookie-E<gt>buf, cookie-E<gt>allocated * 2);\n"
3401 "        if (new_buff == NULL) {\n"
3402 "            return -1;\n"
3403 "        } else {\n"
3404 "            cookie-E<gt>allocated *= 2;\n"
3405 "            cookie-E<gt>buf = new_buff;\n"
3406 "        }\n"
3407 "    }\n"
3408 msgstr ""
3409 "    while (size + cookie-E<gt>offset E<gt> cookie-E<gt>allocated) {\n"
3410 "        new_buff = realloc(cookie-E<gt>buf, cookie-E<gt>allocated * 2);\n"
3411 "        if (new_buff == NULL) {\n"
3412 "            return -1;\n"
3413 "        } else {\n"
3414 "            cookie-E<gt>allocated *= 2;\n"
3415 "            cookie-E<gt>buf = new_buff;\n"
3416 "        }\n"
3417 "    }\n"
3418
3419 #. type: Plain text
3420 #: build/C/man3/fopencookie.3:309
3421 #, no-wrap
3422 msgid "    memcpy(cookie-E<gt>buf + cookie-E<gt>offset, buf, size);\n"
3423 msgstr "    memcpy(cookie-E<gt>buf + cookie-E<gt>offset, buf, size);\n"
3424
3425 #. type: Plain text
3426 #: build/C/man3/fopencookie.3:313
3427 #, no-wrap
3428 msgid ""
3429 "    cookie-E<gt>offset += size;\n"
3430 "    if (cookie-E<gt>offset E<gt> cookie-E<gt>endpos)\n"
3431 "        cookie-E<gt>endpos = cookie-E<gt>offset;\n"
3432 msgstr ""
3433 "    cookie-E<gt>offset += size;\n"
3434 "    if (cookie-E<gt>offset E<gt> cookie-E<gt>endpos)\n"
3435 "        cookie-E<gt>endpos = cookie-E<gt>offset;\n"
3436
3437 #. type: Plain text
3438 #: build/C/man3/fopencookie.3:316
3439 #, no-wrap
3440 msgid ""
3441 "    return size;\n"
3442 "}\n"
3443 msgstr ""
3444 "    return size;\n"
3445 "}\n"
3446
3447 #. type: Plain text
3448 #: build/C/man3/fopencookie.3:322
3449 #, no-wrap
3450 msgid ""
3451 "ssize_t\n"
3452 "memfile_read(void *c, char *buf, size_t size)\n"
3453 "{\n"
3454 "    ssize_t xbytes;\n"
3455 "    struct memfile_cookie *cookie = c;\n"
3456 msgstr ""
3457 "ssize_t\n"
3458 "memfile_read(void *c, char *buf, size_t size)\n"
3459 "{\n"
3460 "    ssize_t xbytes;\n"
3461 "    struct memfile_cookie *cookie = c;\n"
3462
3463 #. type: Plain text
3464 #: build/C/man3/fopencookie.3:324
3465 #, no-wrap
3466 msgid "    /* Fetch minimum of bytes requested and bytes available */\n"
3467 msgstr "    /* Fetch minimum of bytes requested and bytes available */\n"
3468
3469 #. type: Plain text
3470 #: build/C/man3/fopencookie.3:330
3471 #, no-wrap
3472 msgid ""
3473 "    xbytes = size;\n"
3474 "    if (cookie-E<gt>offset + size E<gt> cookie-E<gt>endpos)\n"
3475 "        xbytes = cookie-E<gt>endpos - cookie-E<gt>offset;\n"
3476 "    if (xbytes E<lt> 0)     /* offset may be past endpos */\n"
3477 "       xbytes = 0;\n"
3478 msgstr ""
3479 "    xbytes = size;\n"
3480 "    if (cookie-E<gt>offset + size E<gt> cookie-E<gt>endpos)\n"
3481 "        xbytes = cookie-E<gt>endpos - cookie-E<gt>offset;\n"
3482 "    if (xbytes E<lt> 0)     /* offset may be past endpos */\n"
3483 "       xbytes = 0;\n"
3484
3485 #. type: Plain text
3486 #: build/C/man3/fopencookie.3:332
3487 #, no-wrap
3488 msgid "    memcpy(buf, cookie-E<gt>buf + cookie-E<gt>offset, xbytes);\n"
3489 msgstr "    memcpy(buf, cookie-E<gt>buf + cookie-E<gt>offset, xbytes);\n"
3490
3491 #. type: Plain text
3492 #: build/C/man3/fopencookie.3:336
3493 #, no-wrap
3494 msgid ""
3495 "    cookie-E<gt>offset += xbytes;\n"
3496 "    return xbytes;\n"
3497 "}\n"
3498 msgstr ""
3499 "    cookie-E<gt>offset += xbytes;\n"
3500 "    return xbytes;\n"
3501 "}\n"
3502
3503 #. type: Plain text
3504 #: build/C/man3/fopencookie.3:342
3505 #, no-wrap
3506 msgid ""
3507 "int\n"
3508 "memfile_seek(void *c, off64_t *offset, int whence)\n"
3509 "{\n"
3510 "    off64_t new_offset;\n"
3511 "    struct memfile_cookie *cookie = c;\n"
3512 msgstr ""
3513 "int\n"
3514 "memfile_seek(void *c, off64_t *offset, int whence)\n"
3515 "{\n"
3516 "    off64_t new_offset;\n"
3517 "    struct memfile_cookie *cookie = c;\n"
3518
3519 #. type: Plain text
3520 #: build/C/man3/fopencookie.3:351
3521 #, no-wrap
3522 msgid ""
3523 "    if (whence == SEEK_SET)\n"
3524 "        new_offset = *offset;\n"
3525 "    else if (whence == SEEK_END)\n"
3526 "        new_offset = cookie-E<gt>endpos + *offset;\n"
3527 "    else if (whence == SEEK_CUR)\n"
3528 "        new_offset = cookie-E<gt>offset + *offset;\n"
3529 "    else\n"
3530 "        return -1;\n"
3531 msgstr ""
3532 "    if (whence == SEEK_SET)\n"
3533 "        new_offset = *offset;\n"
3534 "    else if (whence == SEEK_END)\n"
3535 "        new_offset = cookie-E<gt>endpos + *offset;\n"
3536 "    else if (whence == SEEK_CUR)\n"
3537 "        new_offset = cookie-E<gt>offset + *offset;\n"
3538 "    else\n"
3539 "        return -1;\n"
3540
3541 #. type: Plain text
3542 #: build/C/man3/fopencookie.3:354
3543 #, no-wrap
3544 msgid ""
3545 "    if (new_offset E<lt> 0)\n"
3546 "        return -1;\n"
3547 msgstr ""
3548 "    if (new_offset E<lt> 0)\n"
3549 "        return -1;\n"
3550
3551 #. type: Plain text
3552 #: build/C/man3/fopencookie.3:359
3553 #, no-wrap
3554 msgid ""
3555 "    cookie-E<gt>offset = new_offset;\n"
3556 "    *offset = new_offset;\n"
3557 "    return 0;\n"
3558 "}\n"
3559 msgstr ""
3560 "    cookie-E<gt>offset = new_offset;\n"
3561 "    *offset = new_offset;\n"
3562 "    return 0;\n"
3563 "}\n"
3564
3565 #. type: Plain text
3566 #: build/C/man3/fopencookie.3:364
3567 #, no-wrap
3568 msgid ""
3569 "int\n"
3570 "memfile_close(void *c)\n"
3571 "{\n"
3572 "    struct memfile_cookie *cookie = c;\n"
3573 msgstr ""
3574 "int\n"
3575 "memfile_close(void *c)\n"
3576 "{\n"
3577 "    struct memfile_cookie *cookie = c;\n"
3578
3579 #. type: Plain text
3580 #: build/C/man3/fopencookie.3:368
3581 #, no-wrap
3582 msgid ""
3583 "    free(cookie-E<gt>buf);\n"
3584 "    cookie-E<gt>allocated = 0;\n"
3585 "    cookie-E<gt>buf = NULL;\n"
3586 msgstr ""
3587 "    free(cookie-E<gt>buf);\n"
3588 "    cookie-E<gt>allocated = 0;\n"
3589 "    cookie-E<gt>buf = NULL;\n"
3590
3591 #. type: Plain text
3592 #: build/C/man3/fopencookie.3:371
3593 #, no-wrap
3594 msgid ""
3595 "    return 0;\n"
3596 "}\n"
3597 msgstr ""
3598 "    return 0;\n"
3599 "}\n"
3600
3601 #. type: Plain text
3602 #: build/C/man3/fopencookie.3:387
3603 #, no-wrap
3604 msgid ""
3605 "int\n"
3606 "main(int argc, char *argv[])\n"
3607 "{\n"
3608 "    cookie_io_functions_t  memfile_func = {\n"
3609 "        .read  = memfile_read,\n"
3610 "        .write = memfile_write,\n"
3611 "        .seek  = memfile_seek,\n"
3612 "        .close = memfile_close\n"
3613 "    };\n"
3614 "    FILE *fp;\n"
3615 "    struct memfile_cookie mycookie;\n"
3616 "    ssize_t nread;\n"
3617 "    long p;\n"
3618 "    int j;\n"
3619 "    char buf[1000];\n"
3620 msgstr ""
3621 "int\n"
3622 "main(int argc, char *argv[])\n"
3623 "{\n"
3624 "    cookie_io_functions_t  memfile_func = {\n"
3625 "        .read  = memfile_read,\n"
3626 "        .write = memfile_write,\n"
3627 "        .seek  = memfile_seek,\n"
3628 "        .close = memfile_close\n"
3629 "    };\n"
3630 "    FILE *fp;\n"
3631 "    struct memfile_cookie mycookie;\n"
3632 "    ssize_t nread;\n"
3633 "    long p;\n"
3634 "    int j;\n"
3635 "    char buf[1000];\n"
3636
3637 #. type: Plain text
3638 #: build/C/man3/fopencookie.3:389
3639 #, no-wrap
3640 msgid "    /* Set up the cookie before calling fopencookie() */\n"
3641 msgstr "    /* Set up the cookie before calling fopencookie() */\n"
3642
3643 #. type: Plain text
3644 #: build/C/man3/fopencookie.3:395
3645 #, no-wrap
3646 msgid ""
3647 "    mycookie.buf = malloc(INIT_BUF_SIZE);\n"
3648 "    if (mycookie.buf == NULL) {\n"
3649 "        perror(\"malloc\");\n"
3650 "        exit(EXIT_FAILURE);\n"
3651 "    }\n"
3652 msgstr ""
3653 "    mycookie.buf = malloc(INIT_BUF_SIZE);\n"
3654 "    if (mycookie.buf == NULL) {\n"
3655 "        perror(\"malloc\");\n"
3656 "        exit(EXIT_FAILURE);\n"
3657 "    }\n"
3658
3659 #. type: Plain text
3660 #: build/C/man3/fopencookie.3:399
3661 #, no-wrap
3662 msgid ""
3663 "    mycookie.allocated = INIT_BUF_SIZE;\n"
3664 "    mycookie.offset = 0;\n"
3665 "    mycookie.endpos = 0;\n"
3666 msgstr ""
3667 "    mycookie.allocated = INIT_BUF_SIZE;\n"
3668 "    mycookie.offset = 0;\n"
3669 "    mycookie.endpos = 0;\n"
3670
3671 #. type: Plain text
3672 #: build/C/man3/fopencookie.3:405
3673 #, no-wrap
3674 msgid ""
3675 "    fp = fopencookie(&mycookie,\"w+\", memfile_func);\n"
3676 "    if (fp == NULL) {\n"
3677 "        perror(\"fopencookie\");\n"
3678 "        exit(EXIT_FAILURE);\n"
3679 "    }\n"
3680 msgstr ""
3681 "    fp = fopencookie(&mycookie,\"w+\", memfile_func);\n"
3682 "    if (fp == NULL) {\n"
3683 "        perror(\"fopencookie\");\n"
3684 "        exit(EXIT_FAILURE);\n"
3685 "    }\n"
3686
3687 #. type: Plain text
3688 #: build/C/man3/fopencookie.3:407
3689 #, no-wrap
3690 msgid "    /* Write command-line arguments to our file */\n"
3691 msgstr "    /* Write command-line arguments to our file */\n"
3692
3693 #. type: Plain text
3694 #: build/C/man3/fopencookie.3:413
3695 #, no-wrap
3696 msgid ""
3697 "    for (j = 1; j E<lt> argc; j++)\n"
3698 "        if (fputs(argv[j], fp) == EOF) {\n"
3699 "            perror(\"fputs\");\n"
3700 "            exit(EXIT_FAILURE);\n"
3701 "        }\n"
3702 msgstr ""
3703 "    for (j = 1; j E<lt> argc; j++)\n"
3704 "        if (fputs(argv[j], fp) == EOF) {\n"
3705 "            perror(\"fputs\");\n"
3706 "            exit(EXIT_FAILURE);\n"
3707 "        }\n"
3708
3709 #. type: Plain text
3710 #: build/C/man3/fopencookie.3:415
3711 #, no-wrap
3712 msgid "    /* Read two bytes out of every five, until EOF */\n"
3713 msgstr "    /* Read two bytes out of every five, until EOF */\n"
3714
3715 #. type: Plain text
3716 #: build/C/man3/fopencookie.3:430
3717 #, no-wrap
3718 msgid ""
3719 "    for (p = 0; ; p += 5) {\n"
3720 "        if (fseek(fp, p, SEEK_SET) == -1) {\n"
3721 "            perror(\"fseek\");\n"
3722 "            exit(EXIT_FAILURE);\n"
3723 "        }\n"
3724 "        nread = fread(buf, 1, 2, fp);\n"
3725 "        if (nread == -1) {\n"
3726 "            perror(\"fread\");\n"
3727 "            exit(EXIT_FAILURE);\n"
3728 "        }\n"
3729 "        if (nread == 0) {\n"
3730 "            printf(\"Reached end of file\\en\");\n"
3731 "            break;\n"
3732 "        }\n"
3733 msgstr ""
3734 "    for (p = 0; ; p += 5) {\n"
3735 "        if (fseek(fp, p, SEEK_SET) == -1) {\n"
3736 "            perror(\"fseek\");\n"
3737 "            exit(EXIT_FAILURE);\n"
3738 "        }\n"
3739 "        nread = fread(buf, 1, 2, fp);\n"
3740 "        if (nread == -1) {\n"
3741 "            perror(\"fread\");\n"
3742 "            exit(EXIT_FAILURE);\n"
3743 "        }\n"
3744 "        if (nread == 0) {\n"
3745 "            printf(\"Reached end of file\\en\");\n"
3746 "            break;\n"
3747 "        }\n"
3748
3749 #. type: Plain text
3750 #: build/C/man3/fopencookie.3:433
3751 #, no-wrap
3752 msgid ""
3753 "        printf(\"/%.*s/\\en\", nread, buf);\n"
3754 "    }\n"
3755 msgstr ""
3756 "        printf(\"/%.*s/\\en\", nread, buf);\n"
3757 "    }\n"
3758
3759 #. type: Plain text
3760 #: build/C/man3/fopencookie.3:436 build/C/man2/readlink.2:213
3761 #, no-wrap
3762 msgid ""
3763 "    exit(EXIT_SUCCESS);\n"
3764 "}\n"
3765 msgstr ""
3766 "    exit(EXIT_SUCCESS);\n"
3767 "}\n"
3768
3769 #. type: Plain text
3770 #: build/C/man3/fopencookie.3:442
3771 msgid "B<fclose>(3), B<fmemopen>(3), B<fopen>(3), B<fseek>(3)"
3772 msgstr "B<fclose>(3), B<fmemopen>(3), B<fopen>(3), B<fseek>(3)"
3773
3774 #. type: TH
3775 #: build/C/man3/fpurge.3:25
3776 #, no-wrap
3777 msgid "FPURGE"
3778 msgstr "FPURGE"
3779
3780 #. type: TH
3781 #: build/C/man3/fpurge.3:25
3782 #, no-wrap
3783 msgid "2001-12-15"
3784 msgstr "2001-12-15"
3785
3786 #. type: Plain text
3787 #: build/C/man3/fpurge.3:28
3788 msgid "fpurge, __fpurge - purge a stream"
3789 msgstr "fpurge, __fpurge - ストリームを一掃 (purge) する"
3790
3791 #. type: Plain text
3792 #: build/C/man3/fpurge.3:32
3793 #, no-wrap
3794 msgid ""
3795 "/* unsupported */\n"
3796 "B<#include E<lt>stdio.hE<gt>>\n"
3797 msgstr ""
3798 "/* unsupported */\n"
3799 "B<#include E<lt>stdio.hE<gt>>\n"
3800
3801 #. type: Plain text
3802 #: build/C/man3/fpurge.3:34
3803 #, no-wrap
3804 msgid "B<int fpurge(FILE *>I<stream>B<);>\n"
3805 msgstr "B<int fpurge(FILE *>I<stream>B<);>\n"
3806
3807 #. type: Plain text
3808 #: build/C/man3/fpurge.3:37
3809 #, no-wrap
3810 msgid ""
3811 "/* supported */\n"
3812 "B<#include E<lt>stdio.hE<gt>>\n"
3813 msgstr ""
3814 "/* supported */\n"
3815 "B<#include E<lt>stdio.hE<gt>>\n"
3816
3817 #. type: Plain text
3818 #: build/C/man3/fpurge.3:39
3819 #, no-wrap
3820 msgid "B<#include E<lt>stdio_ext.hE<gt>>\n"
3821 msgstr "B<#include E<lt>stdio_ext.hE<gt>>\n"
3822
3823 #. type: Plain text
3824 #: build/C/man3/fpurge.3:41
3825 #, no-wrap
3826 msgid "B<void  __fpurge(FILE *>I<stream>B<);>\n"
3827 msgstr "B<void  __fpurge(FILE *>I<stream>B<);>\n"
3828
3829 #. type: Plain text
3830 #: build/C/man3/fpurge.3:54
3831 msgid ""
3832 "The function B<fpurge>()  clears the buffers of the given stream.  For "
3833 "output streams this discards any unwritten output.  For input streams this "
3834 "discards any input read from the underlying object but not yet obtained via "
3835 "B<getc>(3); this includes any text pushed back via B<ungetc>(3).  See also "
3836 "B<fflush>(3)."
3837 msgstr ""
3838 "B<fpurge>()  関数は、与えられたストリームのバッファをクリアする。 出力スト"
3839 "リームでこれを行うと、書き出されていない出力は捨てられる。 入力ストリームでこ"
3840 "れを行うと、 下層にあるオブジェクトから読み込まれ B<getc>(3)  による取得を"
3841 "待っている入力が、すべて捨てられる。 これには B<ungetc>(3)  によって戻された"
3842 "テキストも含まれる。 B<fflush>(3)  も参照のこと。"
3843
3844 #. type: Plain text
3845 #: build/C/man3/fpurge.3:58
3846 msgid ""
3847 "The function B<__fpurge>()  does precisely the same, but without returning a "
3848 "value."
3849 msgstr "B<__fpurge>()  関数も全く同じことを行うが、ただし返り値を返さない。"
3850
3851 #. type: Plain text
3852 #: build/C/man3/fpurge.3:65
3853 msgid ""
3854 "Upon successful completion B<fpurge>()  returns 0.  On error, it returns -1 "
3855 "and sets I<errno> appropriately."
3856 msgstr ""
3857 "成功すると B<fpurge>()  は 0 を返す。 エラーが起こると -1 を返し、 I<errno> "
3858 "を適切な値に設定する。"
3859
3860 #. type: Plain text
3861 #: build/C/man3/fpurge.3:70
3862 msgid "I<stream> is not an open stream."
3863 msgstr "I<stream> がオープンされていない。"
3864
3865 #. type: Plain text
3866 #: build/C/man3/fpurge.3:78
3867 msgid ""
3868 "These functions are nonstandard and not portable.  The function B<fpurge>()  "
3869 "was introduced in 4.4BSD and is not available under Linux.  The function "
3870 "B<__fpurge>()  was introduced in Solaris, and is present in glibc 2.1.95 and "
3871 "later."
3872 msgstr ""
3873 "これらの関数は標準ではなく、よって移植性もない。 B<fpurge>()  関数は 4.4BSD "
3874 "で導入されたが、Linux では利用できない。 B<__fpurge>()  関数は Solaris で導入"
3875 "され、glibc 2.1.95 以降には存在している。"
3876
3877 #. type: Plain text
3878 #: build/C/man3/fpurge.3:80
3879 msgid "Usually it is a mistake to want to discard input buffers."
3880 msgstr "通常は入力バッファを捨てようとするのは間違っている。"
3881
3882 #.  .BR fclean (3),
3883 #. type: Plain text
3884 #: build/C/man3/fpurge.3:85
3885 msgid "B<fflush>(3), B<setbuf>(3), B<stdio_ext>(3)"
3886 msgstr "B<fflush>(3), B<setbuf>(3), B<stdio_ext>(3)"
3887
3888 #. type: TH
3889 #: build/C/man3/fputwc.3:16
3890 #, no-wrap
3891 msgid "FPUTWC"
3892 msgstr "FPUTWC"
3893
3894 #. type: Plain text
3895 #: build/C/man3/fputwc.3:19
3896 msgid "fputwc, putwc - write a wide character to a FILE stream"
3897 msgstr "fputwc, putwc - ワイド文字を FILE ストリームに書き込む"
3898
3899 #. type: Plain text
3900 #: build/C/man3/fputwc.3:27
3901 #, no-wrap
3902 msgid ""
3903 "B<wint_t fputwc(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
3904 "B<wint_t putwc(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
3905 msgstr ""
3906 "B<wint_t fputwc(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
3907 "B<wint_t putwc(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
3908
3909 #. type: Plain text
3910 #: build/C/man3/fputwc.3:43
3911 msgid ""
3912 "The B<fputwc>()  function is the wide-character equivalent of the B<fputc>"
3913 "(3)  function.  It writes the wide character I<wc> to I<stream>.  If I<ferror"
3914 "(stream)> becomes true, it returns B<WEOF>.  If a wide-character conversion "
3915 "error occurs, it sets I<errno> to B<EILSEQ> and returns B<WEOF>.  Otherwise "
3916 "it returns I<wc>."
3917 msgstr ""
3918 "B<fputwc>()  関数は、 B<fputc>(3)  に対応するワイド文字関数である。この 関数"
3919 "は、ワイド文字 I<wc> を I<stream> に書き込む。 I<ferror(stream)> が真になる"
3920 "と、この関数は B<WEOF> を返す。 ワイド文字変換でエラーが発生した場合は、 "
3921 "I<errno> に B<EILSEQ> をセットし、 B<WEOF> を返す。 それ以外の場合では、この"
3922 "関数は I<wc> を返す。"
3923
3924 #. type: Plain text
3925 #: build/C/man3/fputwc.3:51
3926 msgid ""
3927 "The B<putwc>()  function or macro functions identically to B<fputwc>().  It "
3928 "may be implemented as a macro, and may evaluate its argument more than "
3929 "once.  There is no reason ever to use it."
3930 msgstr ""
3931 "B<putwc>()  関数あるいはマクロは、 B<fputwc>()  と全く同じ動作をする。 この関"
3932 "数はマクロとして実装されるかもしれないので、引き数が複数回評価さ れるかもしれ"
3933 "ない。この関数を使う理由はもはや存在しない。"
3934
3935 #. type: Plain text
3936 #: build/C/man3/fputwc.3:60
3937 msgid ""
3938 "The B<fputwc>()  function returns I<wc> if no error occurred, or B<WEOF> to "
3939 "indicate an error."
3940 msgstr ""
3941 "B<fputwc>()  関数は、エラーが起きなければ I<wc> を返す。エラーの場合には "
3942 "B<WEOF> を返す。"
3943
3944 #. type: Plain text
3945 #: build/C/man3/fputwc.3:65
3946 msgid "Conversion of I<wc> to the stream's encoding fails."
3947 msgstr "I<wc> からストリームの符号への変換に失敗した。"
3948
3949 #. type: Plain text
3950 #: build/C/man3/fputwc.3:74
3951 msgid ""
3952 "The behavior of B<fputwc>()  depends on the B<LC_CTYPE> category of the "
3953 "current locale."
3954 msgstr "B<fputwc>()  の動作は現在のロケールの B<LC_CTYPE> カテゴリに依存する。"
3955
3956 #. type: Plain text
3957 #: build/C/man3/fputwc.3:82
3958 msgid ""
3959 "In the absence of additional information passed to the B<fopen>(3)  call, it "
3960 "is reasonable to expect that B<fputwc>()  will actually write the multibyte "
3961 "sequence corresponding to the wide character I<wc>."
3962 msgstr ""
3963 "B<fopen>(3)  システムコールに渡す追加情報がない場合には、 B<fputwc>()  は 実"
3964 "際にはワイド文字 I<wc> に対応するマルチバイトシーケンスを書き込むと 期待して"
3965 "よい。"
3966
3967 #. type: Plain text
3968 #: build/C/man3/fputwc.3:86
3969 msgid "B<fgetwc>(3), B<fputws>(3), B<unlocked_stdio>(3)"
3970 msgstr "B<fgetwc>(3), B<fputws>(3), B<unlocked_stdio>(3)"
3971
3972 #. type: TH
3973 #: build/C/man3/fread.3:45
3974 #, no-wrap
3975 msgid "FREAD"
3976 msgstr "FREAD"
3977
3978 #. type: TH
3979 #: build/C/man3/fread.3:45
3980 #, no-wrap
3981 msgid "2012-03-30"
3982 msgstr "2012-03-30"
3983
3984 #. type: Plain text
3985 #: build/C/man3/fread.3:48
3986 msgid "fread, fwrite - binary stream input/output"
3987 msgstr "fread, fwrite - バイナリストリームの入出力"
3988
3989 #. type: Plain text
3990 #: build/C/man3/fread.3:54
3991 #, no-wrap
3992 msgid "B<size_t fread(void *>I<ptr>B<, size_t >I<size>B<, size_t >I<nmemb>B<, FILE *>I<stream>B<);>\n"
3993 msgstr "B<size_t fread(void *>I<ptr>B<, size_t >I<size>B<, size_t >I<nmemb>B<, FILE *>I<stream>B<);>\n"
3994
3995 #. type: Plain text
3996 #: build/C/man3/fread.3:57
3997 #, no-wrap
3998 msgid ""
3999 "B<size_t fwrite(const void *>I<ptr>B<, size_t >I<size>B<, size_t >I<nmemb>B<,>\n"
4000 "B<              FILE *>I<stream>B<);>\n"
4001 msgstr ""
4002 "B<size_t fwrite(const void *>I<ptr>B<, size_t >I<size>B<, size_t >I<nmemb>B<,>\n"
4003 "B<              FILE *>I<stream>B<);>\n"
4004
4005 #. type: Plain text
4006 #: build/C/man3/fread.3:69
4007 msgid ""
4008 "The function B<fread>()  reads I<nmemb> elements of data, each I<size> bytes "
4009 "long, from the stream pointed to by I<stream>, storing them at the location "
4010 "given by I<ptr>."
4011 msgstr ""
4012 "B<fread>()  関数は I<stream> ポインタで指定されたストリームから I<nmemb> 個の"
4013 "データを読み込み、 I<ptr> で与えられた場所に格納する。 個々のデータは "
4014 "I<size> バイトの長さを持つ。"
4015
4016 #. type: Plain text
4017 #: build/C/man3/fread.3:80
4018 msgid ""
4019 "The function B<fwrite>()  writes I<nmemb> elements of data, each I<size> "
4020 "bytes long, to the stream pointed to by I<stream>, obtaining them from the "
4021 "location given by I<ptr>."
4022 msgstr ""
4023 "B<fwrite>()  関数は I<ptr> で指定された場所から得た I<nmemb> 個のデータを、 "
4024 "I<stream> ポインタで指定されたストリームに書き込む。 個々のデータは I<size> "
4025 "バイトの長さを持つ。"
4026
4027 #. type: Plain text
4028 #: build/C/man3/fread.3:96
4029 msgid ""
4030 "On success, B<fread>()  and B<fwrite>()  return the number of I<items> read "
4031 "or written.  This number equals the number of bytes transferred only when "
4032 "I<size> is 1.  If an error occurs, or the end of the file is reached, the "
4033 "return value is a short item count (or zero)."
4034 msgstr ""
4035 "成功すると、 B<fread>() と B<fwrite>() は読み書きを行った要素の個数を返す。\n"
4036 "I<size> が 1 の場合は、この数字は転送されたバイト数と等しい。\n"
4037 "エラーが生じた場合や、ファイルの末尾 (end-of-file) に達した場合、\n"
4038 "返り値は指定した個数よりも小さい値 (または 0) となる。"
4039
4040 #. type: Plain text
4041 #: build/C/man3/fread.3:103
4042 msgid ""
4043 "B<fread>()  does not distinguish between end-of-file and error, and callers "
4044 "must use B<feof>(3)  and B<ferror>(3)  to determine which occurred."
4045 msgstr ""
4046 "B<fread>()  は end-of-file とエラーを区別しないので、 どちらが生じたかを判断"
4047 "するためには、 呼び出し側で B<feof>(3)  と B<ferror>(3)  とを使用しなければな"
4048 "らない。"
4049
4050 #. type: Plain text
4051 #: build/C/man3/fread.3:105
4052 msgid "C89, POSIX.1-2001."
4053 msgstr "C89, POSIX.1-2001."
4054
4055 #. type: Plain text
4056 #: build/C/man3/fread.3:111
4057 msgid "B<read>(2), B<write>(2), B<feof>(3), B<ferror>(3), B<unlocked_stdio>(3)"
4058 msgstr ""
4059 "B<read>(2), B<write>(2), B<feof>(3), B<ferror>(3), B<unlocked_stdio>(3)"
4060
4061 #. type: TH
4062 #: build/C/man3/fseek.3:42
4063 #, no-wrap
4064 msgid "FSEEK"
4065 msgstr "FSEEK"
4066
4067 #. type: TH
4068 #: build/C/man3/fseek.3:42
4069 #, no-wrap
4070 msgid "1993-11-29"
4071 msgstr "1993-11-29"
4072
4073 #. type: Plain text
4074 #: build/C/man3/fseek.3:45
4075 msgid "fgetpos, fseek, fsetpos, ftell, rewind - reposition a stream"
4076 msgstr "fgetpos, fseek, fsetpos, ftell, rewind - ストリームの位置を変更する"
4077
4078 #. type: Plain text
4079 #: build/C/man3/fseek.3:49
4080 msgid "B<int fseek(FILE *>I<stream>B<, long >I<offset>B<, int >I<whence>B<);>"
4081 msgstr "B<int fseek(FILE *>I<stream>B<, long >I<offset>B<, int >I<whence>B<);>"
4082
4083 #. type: Plain text
4084 #: build/C/man3/fseek.3:51
4085 msgid "B<long ftell(FILE *>I<stream>B<);>"
4086 msgstr "B<long ftell(FILE *>I<stream>B<);>"
4087
4088 #. type: Plain text
4089 #: build/C/man3/fseek.3:53
4090 msgid "B<void rewind(FILE *>I<stream>B<);>"
4091 msgstr "B<void rewind(FILE *>I<stream>B<);>"
4092
4093 #. type: Plain text
4094 #: build/C/man3/fseek.3:55
4095 msgid "B<int fgetpos(FILE *>I<stream>B<, fpos_t *>I<pos>B<);>"
4096 msgstr "B<int fgetpos(FILE *>I<stream>B<, fpos_t *>I<pos>B<);>"
4097
4098 #. type: Plain text
4099 #: build/C/man3/fseek.3:57
4100 msgid "B<int fsetpos(FILE *>I<stream>B<, fpos_t *>I<pos>B<);>"
4101 msgstr "B<int fsetpos(FILE *>I<stream>B<, fpos_t *>I<pos>B<);>"
4102
4103 #. type: Plain text
4104 #: build/C/man3/fseek.3:81
4105 msgid ""
4106 "The B<fseek>()  function sets the file position indicator for the stream "
4107 "pointed to by I<stream>.  The new position, measured in bytes, is obtained "
4108 "by adding I<offset> bytes to the position specified by I<whence>.  If "
4109 "I<whence> is set to B<SEEK_SET>, B<SEEK_CUR>, or B<SEEK_END>, the offset is "
4110 "relative to the start of the file, the current position indicator, or end-of-"
4111 "file, respectively.  A successful call to the B<fseek>()  function clears "
4112 "the end-of-file indicator for the stream and undoes any effects of the "
4113 "B<ungetc>(3)  function on the same stream."
4114 msgstr ""
4115 "B<fseek>()  関数は I<stream> によって指定されたストリームにおいて、ファイル位"
4116 "置表示子 (file position indicator) をセットする。新たな位置 (バイト単位)  は "
4117 "I<whence> で指定された位置に I<offset> バイトを加えることによって与えられ"
4118 "る。 I<whence> が B<SEEK_SET>, B<SEEK_CUR>, B<SEEK_END> のどれかになっている"
4119 "場合は、それぞれファイルの先頭、現在の位置表示子、 ファイルの末尾からのオフ"
4120 "セットが取られる。 B<fseek>()  関数の呼び出しが成功すると、ストリームの end-"
4121 "of-file 表示子は クリアされ、それまでに B<ungetc>(3)  関数で戻したデータはな"
4122 "かったことになる。"
4123
4124 #. type: Plain text
4125 #: build/C/man3/fseek.3:87
4126 msgid ""
4127 "The B<ftell>()  function obtains the current value of the file position "
4128 "indicator for the stream pointed to by I<stream>."
4129 msgstr ""
4130 "B<ftell>()  関数は I<stream> によって指定されたストリームにおける、ファイル位"
4131 "置表示子 の現時点での値を与える。"
4132
4133 #. type: Plain text
4134 #: build/C/man3/fseek.3:94
4135 msgid ""
4136 "The B<rewind>()  function sets the file position indicator for the stream "
4137 "pointed to by I<stream> to the beginning of the file.  It is equivalent to:"
4138 msgstr ""
4139 "B<rewind>()  関数は I<stream> によって指定されたストリームにおいて、ファイル"
4140 "位置表示子 をファイルの先頭にセットする。この関数は以下と等価である。"
4141
4142 #. type: Plain text
4143 #: build/C/man3/fseek.3:97
4144 msgid "(void) fseek(stream, 0L, SEEK_SET)"
4145 msgstr "(void) fseek(stream, 0L, SEEK_SET)"
4146
4147 #. type: Plain text
4148 #: build/C/man3/fseek.3:101
4149 msgid ""
4150 "except that the error indicator for the stream is also cleared (see "
4151 "B<clearerr>(3))."
4152 msgstr ""
4153 "ただし B<rewind>()  ではストリームに対するエラー表示子 (error indicator) も同"
4154 "時に クリアされる ( B<clearerr>(3)  を見よ)。"
4155
4156 #. type: Plain text
4157 #: build/C/man3/fseek.3:121
4158 msgid ""
4159 "The B<fgetpos>()  and B<fsetpos>()  functions are alternate interfaces "
4160 "equivalent to B<ftell>()  and B<fseek>()  (with I<whence> set to "
4161 "B<SEEK_SET>), setting and storing the current value of the file offset into "
4162 "or from the object referenced by I<pos>.  On some non-UNIX systems, an "
4163 "I<fpos_t> object may be a complex object and these routines may be the only "
4164 "way to portably reposition a text stream."
4165 msgstr ""
4166 "B<fgetpos>()  関数と B<fsetpos>()  関数は、それぞれ B<ftell>()  と B<fseek>"
4167 "()  で I<whence> に B<SEEK_SET> を指定した場合と同様の機能を、異なるインター"
4168 "フェースで提供する。 B<fgetpos>()  はファイルオフセットの現在の値を I<pos> が"
4169 "参照するオブジェクトに保存し、 B<fsetpos>()  はファイルオフセットを I<pos> に"
4170 "設定する。 UNIX 以外のシステムにおいては、 I<fpos_t> が構造体などの複雑なオブ"
4171 "ジェクトになっていて、これらのルーチンがテキス トストリームでファイル位置を変"
4172 "更する方法のうち、移植性のある唯一のもの になっている場合もある。"
4173
4174 #. type: Plain text
4175 #: build/C/man3/fseek.3:136
4176 msgid ""
4177 "The B<rewind>()  function returns no value.  Upon successful completion, "
4178 "B<fgetpos>(), B<fseek>(), B<fsetpos>()  return 0, and B<ftell>()  returns "
4179 "the current offset.  Otherwise, -1 is returned and I<errno> is set to "
4180 "indicate the error."
4181 msgstr ""
4182 "B<rewind>()  は返り値を持たない。 B<fgetpos>(), B<fseek>(), B<fsetpos>()  は"
4183 "成功すると 0 を返す。 B<ftell>()  は現在のオフセットを返す。失敗した場合は返"
4184 "り値は -1 となり、 I<errno> にエラーを示す値がセットされる。"
4185
4186 #. type: Plain text
4187 #: build/C/man3/fseek.3:142
4188 msgid "The I<stream> specified is not a seekable stream."
4189 msgstr "指定した I<stream> がシークできない。"
4190
4191 #. type: Plain text
4192 #: build/C/man3/fseek.3:153
4193 msgid ""
4194 "The I<whence> argument to B<fseek>()  was not B<SEEK_SET>, B<SEEK_END>, or "
4195 "B<SEEK_CUR>."
4196 msgstr ""
4197 "B<fseek>()  関数に対して与えた I<whence> 引数が B<SEEK_SET>, B<SEEK_END>, "
4198 "B<SEEK_CUR> 以外の値であった。"
4199
4200 #. type: Plain text
4201 #: build/C/man3/fseek.3:168
4202 msgid ""
4203 "The functions B<fgetpos>(), B<fseek>(), B<fsetpos>(), and B<ftell>()  may "
4204 "also fail and set I<errno> for any of the errors specified for the routines "
4205 "B<fflush>(3), B<fstat>(2), B<lseek>(2), and B<malloc>(3)."
4206 msgstr ""
4207 "B<fgetpos>(), B<fseek>(), B<fsetpos>(), B<ftell>()  は、それぞれ B<fflush>"
4208 "(3), B<fstat>(2), B<lseek>(2), B<malloc>(3)  などのルーチンを呼び出す際に失敗"
4209 "する可能性がある。この場合は それぞれ対応した I<errno> が設定される。"
4210
4211 #. type: Plain text
4212 #: build/C/man3/fseek.3:173
4213 msgid "B<lseek>(2), B<fseeko>(3)"
4214 msgstr "B<lseek>(2), B<fseeko>(3)"
4215
4216 #. type: TH
4217 #: build/C/man3/fseeko.3:25
4218 #, no-wrap
4219 msgid "FSEEKO"
4220 msgstr "FSEEKO"
4221
4222 #. type: TH
4223 #: build/C/man3/fseeko.3:25
4224 #, no-wrap
4225 msgid "2001-11-05"
4226 msgstr "2001-11-05"
4227
4228 #. type: Plain text
4229 #: build/C/man3/fseeko.3:28
4230 msgid "fseeko, ftello - seek to or report file position"
4231 msgstr "fseeko, ftello - ファイル位置を探す/報告する"
4232
4233 #. type: Plain text
4234 #: build/C/man3/fseeko.3:33
4235 #, no-wrap
4236 msgid "B<int fseeko(FILE *>I<stream>B<, off_t >I<offset>B<, int >I<whence>B<);>\n"
4237 msgstr "B<int fseeko(FILE *>I<stream>B<, off_t >I<offset>B<, int >I<whence>B<);>\n"
4238
4239 #. type: Plain text
4240 #: build/C/man3/fseeko.3:36
4241 #, no-wrap
4242 msgid ""
4243 "B<off_t ftello(FILE *>I<stream>B<);>\n"
4244 "\n"
4245 msgstr ""
4246 "B<off_t ftello(FILE *>I<stream>B<);>\n"
4247 "\n"
4248
4249 #. type: Plain text
4250 #: build/C/man3/fseeko.3:54
4251 msgid ""
4252 "The B<fseeko>()  and B<ftello>()  functions are identical to B<fseek>(3)  "
4253 "and B<ftell>(3)  (see B<fseek>(3)), respectively, except that the I<offset> "
4254 "argument of B<fseeko>()  and the return value of B<ftello>()  is of type "
4255 "I<off_t> instead of I<long>."
4256 msgstr ""
4257 "B<fseeko>()  関数および B<ftello>()  関数は、 それぞれ B<fseek>(3)  および "
4258 "B<ftell>(3)  と同一の機能を持つ (B<fseek>(3)  を見よ) が、ただし B<fseeko>"
4259 "()  関数の I<offset> 引数と B<ftello>()  の返り値が、 I<long> ではなく "
4260 "I<off_t> になっている。"
4261
4262 #. type: Plain text
4263 #: build/C/man3/fseeko.3:57
4264 msgid ""
4265 "On many architectures both I<off_t> and I<long> are 32-bit types, but "
4266 "compilation with"
4267 msgstr ""
4268 "多くのアーキテクチャでは I<off_t> も I<long> も共に 32 ビットの型であるが、"
4269
4270 #. type: Plain text
4271 #: build/C/man3/fseeko.3:61 build/C/man3/lseek64.3:81
4272 #, no-wrap
4273 msgid "#define _FILE_OFFSET_BITS 64\n"
4274 msgstr "#define _FILE_OFFSET_BITS 64\n"
4275
4276 #. type: Plain text
4277 #: build/C/man3/fseeko.3:65
4278 msgid "will turn I<off_t> into a 64-bit type."
4279 msgstr "でコンパイルすると I<off_t> は 64 ビット型となる。"
4280
4281 #. type: Plain text
4282 #: build/C/man3/fseeko.3:74
4283 msgid ""
4284 "On successful completion, B<fseeko>()  returns 0, while B<ftello>()  returns "
4285 "the current offset.  Otherwise, -1 is returned and I<errno> is set to "
4286 "indicate the error."
4287 msgstr ""
4288 "成功した場合、 B<fseeko>()  は 0 を、 B<ftello>()  は現在のオフセットを返"
4289 "す。 失敗した場合、-1 を返し、 I<errno> にエラーを示す値をセットする。"
4290
4291 #. type: Plain text
4292 #: build/C/man3/fseeko.3:77
4293 msgid "See the ERRORS in B<fseek>(3)."
4294 msgstr "B<fseek>(3)  の「エラー」の節を参照。"
4295
4296 #. type: Plain text
4297 #: build/C/man3/fseeko.3:79
4298 msgid "SUSv2, POSIX.1-2001."
4299 msgstr "SUSv2, POSIX.1-2001."
4300
4301 #. type: Plain text
4302 #: build/C/man3/fseeko.3:83
4303 msgid ""
4304 "These functions are found on System V-like systems.  They are not present in "
4305 "libc4, libc5, glibc 2.0 but are available since glibc 2.1."
4306 msgstr ""
4307 "これらの関数は System V 的なシステムにある。 libc4, libc5, glibc 2.0 にはな"
4308 "かったが、 glibc 2.1 から使えるようになった。"
4309
4310 #. type: Plain text
4311 #: build/C/man3/fseeko.3:85
4312 msgid "B<fseek>(3)"
4313 msgstr "B<fseek>(3)"
4314
4315 #. type: TH
4316 #: build/C/man3/getline.3:26
4317 #, no-wrap
4318 msgid "GETLINE"
4319 msgstr "GETLINE"
4320
4321 #. type: TH
4322 #: build/C/man3/getline.3:26
4323 #, no-wrap
4324 msgid "2010-06-12"
4325 msgstr "2010-06-12"
4326
4327 #. type: Plain text
4328 #: build/C/man3/getline.3:29
4329 msgid "getline, getdelim - delimited string input"
4330 msgstr "getline, getdelim - 区切り文字までの文字列入力を読み込む"
4331
4332 #. type: Plain text
4333 #: build/C/man3/getline.3:34
4334 #, no-wrap
4335 msgid "B<ssize_t getline(char **>I<lineptr>B<, size_t *>I<n>B<, FILE *>I<stream>B<);>\n"
4336 msgstr "B<ssize_t getline(char **>I<lineptr>B<, size_t *>I<n>B<, FILE *>I<stream>B<);>\n"
4337
4338 #. type: Plain text
4339 #: build/C/man3/getline.3:37
4340 #, no-wrap
4341 msgid "B<ssize_t getdelim(char **>I<lineptr>B<, size_t *>I<n>B<, int >I<delim>B<, FILE *>I<stream>B<);>\n"
4342 msgstr "B<ssize_t getdelim(char **>I<lineptr>B<, size_t *>I<n>B<, int >I<delim>B<, FILE *>I<stream>B<);>\n"
4343
4344 #. type: Plain text
4345 #: build/C/man3/getline.3:47
4346 msgid "B<getline>(), B<getdelim>():"
4347 msgstr "B<getline>(), B<getdelim>():"
4348
4349 #. type: Plain text
4350 #: build/C/man3/getline.3:52
4351 msgid "_POSIX_C_SOURCE\\ E<gt>=\\ 200809L || _XOPEN_SOURCE\\ E<gt>=\\ 700"
4352 msgstr "_POSIX_C_SOURCE\\ E<gt>=\\ 200809L || _XOPEN_SOURCE\\ E<gt>=\\ 700"
4353
4354 #. type: Plain text
4355 #: build/C/man3/getline.3:65
4356 msgid ""
4357 "B<getline>()  reads an entire line from I<stream>, storing the address of "
4358 "the buffer containing the text into I<*lineptr>.  The buffer is null-"
4359 "terminated and includes the newline character, if one was found."
4360 msgstr ""
4361 "B<getline>()  は I<stream> から 1 行全てを読み込み、テキストが含まれている"
4362 "バッファのアドレスを I<*lineptr> に格納する。 バッファはヌル文字 (\\e0) で終"
4363 "端される。 改行文字が見つかった場合は、改行文字もバッファに格納される。"
4364
4365 #. type: Plain text
4366 #: build/C/man3/getline.3:75
4367 msgid ""
4368 "If I<*lineptr> is NULL, then B<getline>()  will allocate a buffer for "
4369 "storing the line, which should be freed by the user program.  (In this case, "
4370 "the value in I<*n> is ignored.)"
4371 msgstr ""
4372 "I<*lineptr> が NULL の場合、 B<getline>()  は行の内容を格納するためのバッファ"
4373 "を確保する。 このバッファはユーザーのプログラムで解放すべきである (この場"
4374 "合、 I<*n> の値は無視される)。"
4375
4376 #. type: Plain text
4377 #: build/C/man3/getline.3:93
4378 msgid ""
4379 "Alternatively, before calling B<getline>(), I<*lineptr> can contain a "
4380 "pointer to a B<malloc>(3)-allocated buffer I<*n> bytes in size.  If the "
4381 "buffer is not large enough to hold the line, B<getline>()  resizes it with "
4382 "B<realloc>(3), updating I<*lineptr> and I<*n> as necessary."
4383 msgstr ""
4384 "別の方法として、 B<getline>()  を呼び出す際に、 I<*lineptr> に B<malloc>(3)  "
4385 "で確保した大きさ I<*n> バイトのバッファへのポインタを入れて渡すこともでき"
4386 "る。 読み込んだ行を保持するのに十分なバッファがない場合、 B<getline>()  は "
4387 "B<realloc>(3)  を使ってバッファのサイズを変更し、必要に応じて I<*lineptr> と "
4388 "I<*n> を更新する。"
4389
4390 #. type: Plain text
4391 #: build/C/man3/getline.3:99
4392 msgid ""
4393 "In either case, on a successful call, I<*lineptr> and I<*n> will be updated "
4394 "to reflect the buffer address and allocated size respectively."
4395 msgstr ""
4396 "どちらの場合でも、呼び出しに成功したときには、 I<*lineptr> と I<*n> がバッ"
4397 "ファのアドレスと割り当てたサイズを反映した値に更新される。"
4398
4399 #. type: Plain text
4400 #: build/C/man3/getline.3:110
4401 msgid ""
4402 "B<getdelim>()  works like B<getline>(), except that a line delimiter other "
4403 "than newline can be specified as the I<delimiter> argument.  As with "
4404 "B<getline>(), a delimiter character is not added if one was not present in "
4405 "the input before end of file was reached."
4406 msgstr ""
4407 "B<getdelim>()  は B<getline>()  と同じように動作するが、改行文字以外の区切り"
4408 "文字を引き数 I<delim> に指定することができる。 B<getline>()  と同様に、ファイ"
4409 "ル終端に達するまでに入力行に区切り文字が見付からない場合は、 区切り文字をバッ"
4410 "ファに追加しない。"
4411
4412 #. type: Plain text
4413 #: build/C/man3/getline.3:119
4414 msgid ""
4415 "On success, B<getline>()  and B<getdelim>()  return the number of characters "
4416 "read, including the delimiter character, but not including the terminating "
4417 "null byte.  This value can be used to handle embedded null bytes in the line "
4418 "read."
4419 msgstr ""
4420 "成功した場合、 B<getline>()  と B<getdelim>()  は読み込んだ文字数を返す。 文"
4421 "字数には区切り文字は含まれるが、終端に使う NULL バイトは含まれない。 この値に"
4422 "よって、読み込んだ行に含まれる NULL バイトを操作することができる。"
4423
4424 #. type: Plain text
4425 #: build/C/man3/getline.3:122
4426 msgid ""
4427 "Both functions return -1 on failure to read a line (including end-of-file "
4428 "condition)."
4429 msgstr ""
4430 "どちらの関数も、行の読み込みに失敗した場合には -1 を返す (ファイルの終端に達"
4431 "した場合にも -1 を返す)。"
4432
4433 #. type: Plain text
4434 #: build/C/man3/getline.3:132
4435 msgid "Bad arguments (I<n> or I<lineptr> is NULL, or I<stream> is not valid)."
4436 msgstr ""
4437 "引き数が不正である (I<n> または I<lineptr> が NULL である。 もしくは "
4438 "I<stream> が有効でない)。"
4439
4440 #. type: Plain text
4441 #: build/C/man3/getline.3:134
4442 msgid "These functions are available since libc 4.6.27."
4443 msgstr "これらの関数は libc 4.6.27 以降で利用可能である。"
4444
4445 #. type: Plain text
4446 #: build/C/man3/getline.3:141
4447 msgid ""
4448 "Both B<getline>()  and B<getdelim>()  were originally GNU extensions.  They "
4449 "were standardized in POSIX.1-2008."
4450 msgstr ""
4451 "B<getline>()  と B<getdelim>()  は、どちらも元は GNU による拡張であったが、 "
4452 "POSIX.1-2008 で標準化された。"
4453
4454 #. type: Plain text
4455 #: build/C/man3/getline.3:146
4456 #, no-wrap
4457 msgid ""
4458 "#define _GNU_SOURCE\n"
4459 "#include E<lt>stdio.hE<gt>\n"
4460 "#include E<lt>stdlib.hE<gt>\n"
4461 msgstr ""
4462 "#define _GNU_SOURCE\n"
4463 "#include E<lt>stdio.hE<gt>\n"
4464 "#include E<lt>stdlib.hE<gt>\n"
4465
4466 #. type: Plain text
4467 #: build/C/man3/getline.3:154
4468 #, no-wrap
4469 msgid ""
4470 "int\n"
4471 "main(void)\n"
4472 "{\n"
4473 "    FILE *fp;\n"
4474 "    char *line = NULL;\n"
4475 "    size_t len = 0;\n"
4476 "    ssize_t read;\n"
4477 msgstr ""
4478 "int\n"
4479 "main(void)\n"
4480 "{\n"
4481 "    FILE *fp;\n"
4482 "    char *line = NULL;\n"
4483 "    size_t len = 0;\n"
4484 "    ssize_t read;\n"
4485
4486 #. type: Plain text
4487 #: build/C/man3/getline.3:158
4488 #, no-wrap
4489 msgid ""
4490 "    fp = fopen(\"/etc/motd\", \"r\");\n"
4491 "    if (fp == NULL)\n"
4492 "        exit(EXIT_FAILURE);\n"
4493 msgstr ""
4494 "    fp = fopen(\"/etc/motd\", \"r\");\n"
4495 "    if (fp == NULL)\n"
4496 "        exit(EXIT_FAILURE);\n"
4497
4498 #. type: Plain text
4499 #: build/C/man3/getline.3:163
4500 #, no-wrap
4501 msgid ""
4502 "    while ((read = getline(&line, &len, fp)) != -1) {\n"
4503 "        printf(\"Retrieved line of length %zu :\\en\", read);\n"
4504 "        printf(\"%s\", line);\n"
4505 "    }\n"
4506 msgstr ""
4507 "    while ((read = getline(&line, &len, fp)) != -1) {\n"
4508 "        printf(\"Retrieved line of length %zu :\\en\", read);\n"
4509 "        printf(\"%s\", line);\n"
4510 "    }\n"
4511
4512 #. type: Plain text
4513 #: build/C/man3/getline.3:167
4514 #, no-wrap
4515 msgid ""
4516 "    free(line);\n"
4517 "    exit(EXIT_SUCCESS);\n"
4518 "}\n"
4519 msgstr ""
4520 "    free(line);\n"
4521 "    exit(EXIT_SUCCESS);\n"
4522 "}\n"
4523
4524 #. type: Plain text
4525 #: build/C/man3/getline.3:175
4526 msgid ""
4527 "B<read>(2), B<fgets>(3), B<fopen>(3), B<fread>(3), B<gets>(3), B<scanf>(3)"
4528 msgstr ""
4529 "B<read>(2), B<fgets>(3), B<fopen>(3), B<fread>(3), B<gets>(3), B<scanf>(3)"
4530
4531 #. type: TH
4532 #: build/C/man3/gets.3:27
4533 #, no-wrap
4534 msgid "GETS"
4535 msgstr "GETS"
4536
4537 #. type: TH
4538 #: build/C/man3/gets.3:27
4539 #, no-wrap
4540 msgid "2012-01-18"
4541 msgstr "2012-01-18"
4542
4543 #. type: Plain text
4544 #: build/C/man3/gets.3:30
4545 msgid ""
4546 "fgetc, fgets, getc, getchar, gets, ungetc - input of characters and strings"
4547 msgstr "fgetc, fgets, getc, getchar, gets, ungetc - 文字と文字列の入力"
4548
4549 #. type: Plain text
4550 #: build/C/man3/gets.3:35
4551 #, no-wrap
4552 msgid "B<int fgetc(FILE *>I<stream>B<);>\n"
4553 msgstr "B<int fgetc(FILE *>I<stream>B<);>\n"
4554
4555 #. type: Plain text
4556 #: build/C/man3/gets.3:37
4557 #, no-wrap
4558 msgid "B<char *fgets(char *>I<s>B<, int >I<size>B<, FILE *>I<stream>B<);>\n"
4559 msgstr "B<char *fgets(char *>I<s>B<, int >I<size>B<, FILE *>I<stream>B<);>\n"
4560
4561 #. type: Plain text
4562 #: build/C/man3/gets.3:39
4563 #, no-wrap
4564 msgid "B<int getc(FILE *>I<stream>B<);>\n"
4565 msgstr "B<int getc(FILE *>I<stream>B<);>\n"
4566
4567 #. type: Plain text
4568 #: build/C/man3/gets.3:41
4569 #, no-wrap
4570 msgid "B<int getchar(void);>\n"
4571 msgstr "B<int getchar(void);>\n"
4572
4573 #. type: Plain text
4574 #: build/C/man3/gets.3:43
4575 #, no-wrap
4576 msgid "B<char *gets(char *>I<s>B<);>\n"
4577 msgstr "B<char *gets(char *>I<s>B<);>\n"
4578
4579 #. type: Plain text
4580 #: build/C/man3/gets.3:45
4581 #, no-wrap
4582 msgid "B<int ungetc(int >I<c>B<, FILE *>I<stream>B<);>\n"
4583 msgstr "B<int ungetc(int >I<c>B<, FILE *>I<stream>B<);>\n"
4584
4585 #. type: Plain text
4586 #: build/C/man3/gets.3:57
4587 msgid ""
4588 "B<fgetc>()  reads the next character from I<stream> and returns it as an "
4589 "I<unsigned char> cast to an I<int>, or B<EOF> on end of file or error."
4590 msgstr ""
4591 "B<fgetc>()  は、 I<stream> から次の文字を I<unsigned char> として読み、 "
4592 "I<int> にキャストして返す。ファイルの終わりやエラーとなった場合は B<EOF> を返"
4593 "す。"
4594
4595 #. type: Plain text
4596 #: build/C/man3/gets.3:64
4597 msgid ""
4598 "B<getc>()  is equivalent to B<fgetc>()  except that it may be implemented as "
4599 "a macro which evaluates I<stream> more than once."
4600 msgstr ""
4601 "B<getc>()  は B<fgetc>()  と同様だが、 I<stream> を複数回評価するマクロとして"
4602 "実装されているかもしれない。"
4603
4604 #. type: Plain text
4605 #: build/C/man3/gets.3:68
4606 msgid "B<getchar>()  is equivalent to B<getc(>I<stdin>B<)>."
4607 msgstr "B<getchar>()  は B<getc(>I<stdin>B<)> と同じである。"
4608
4609 #. type: Plain text
4610 #: build/C/man3/gets.3:78
4611 msgid ""
4612 "B<gets>()  reads a line from I<stdin> into the buffer pointed to by I<s> "
4613 "until either a terminating newline or B<EOF>, which it replaces with a null "
4614 "byte (\\(aq\\e0\\(aq).  No check for buffer overrun is performed (see BUGS "
4615 "below)."
4616 msgstr ""
4617 "B<gets>()  は、改行文字か B<EOF> までの 1行を I<stdin> から読み込み I<s> が指"
4618 "すバッファに格納する (末尾の改行文字や B<EOF> は NULL バイト (\\(aq"
4619 "\\e0\\(aq) に置き換えられる)。 バッファオーバーランのチェックは行われない (下"
4620 "記の「バグ」を参照)。"
4621
4622 #. type: Plain text
4623 #: build/C/man3/gets.3:92
4624 msgid ""
4625 "B<fgets>()  reads in at most one less than I<size> characters from I<stream> "
4626 "and stores them into the buffer pointed to by I<s>.  Reading stops after an "
4627 "B<EOF> or a newline.  If a newline is read, it is stored into the buffer.  A "
4628 "terminating null byte (\\(aq\\e0\\(aq)  is stored after the last character "
4629 "in the buffer."
4630 msgstr ""
4631 "B<fgets>()  は I<stream> から最大で I<size> - 1 個の文字を読み込み、 I<s> が"
4632 "指すバッファに格納する。読み込みは B<EOF> または改行文字を読み込んだ後で停止"
4633 "する。 読み込まれた改行文字はバッファに格納される。 終端の NULL バイト (\\(aq"
4634 "\\e0\\(aq)  が一つバッファの中の最後の文字の後に書き込まれる。"
4635
4636 #. type: Plain text
4637 #: build/C/man3/gets.3:103
4638 msgid ""
4639 "B<ungetc>()  pushes I<c> back to I<stream>, cast to I<unsigned char>, where "
4640 "it is available for subsequent read operations.  Pushed-back characters will "
4641 "be returned in reverse order; only one pushback is guaranteed."
4642 msgstr ""
4643 "B<ungetc>()  は、後の read 操作で読めるように、 I<c> を I<unsigned char> に"
4644 "キャストして I<stream> に書き戻す。 書き戻された文字は逆順に戻される; 書き戻"
4645 "しとして保証されているのは、一文字だけである。"
4646
4647 #. type: Plain text
4648 #: build/C/man3/gets.3:108
4649 msgid ""
4650 "Calls to the functions described here can be mixed with each other and with "
4651 "calls to other input functions from the I<stdio> library for the same input "
4652 "stream."
4653 msgstr ""
4654 "ここで述べた関数や I<stdio> ライブラリの入力関数を同じ入力ストリームに対して"
4655 "互いに混ぜて使うことができる。"
4656
4657 #. type: Plain text
4658 #: build/C/man3/gets.3:123
4659 msgid ""
4660 "B<fgetc>(), B<getc>()  and B<getchar>()  return the character read as an "
4661 "I<unsigned char> cast to an I<int> or B<EOF> on end of file or error."
4662 msgstr ""
4663 "B<fgetc>(), B<getc>(), B<getchar>()  は、文字を I<unsigned char> として読ん"
4664 "で I<int> にキャストして返す。ファイルの終わりやエラーの場合は B<EOF> を返"
4665 "す。"
4666
4667 #. type: Plain text
4668 #: build/C/man3/gets.3:131
4669 msgid ""
4670 "B<gets>()  and B<fgets>()  return I<s> on success, and NULL on error or when "
4671 "end of file occurs while no characters have been read."
4672 msgstr ""
4673 "B<gets>()  と B<fgets>()  は、成功すると I<s> を返し、エラーや 1 文字も読み込"
4674 "んでいないのにファイルの終わりになった 場合に NULL を返す。"
4675
4676 #. type: Plain text
4677 #: build/C/man3/gets.3:138
4678 msgid "B<ungetc>()  returns I<c> on success, or B<EOF> on error."
4679 msgstr "B<ungetc>()  は成功すると I<c> を返し、エラーの場合は B<EOF> を返す。"
4680
4681 #. type: Plain text
4682 #: build/C/man3/gets.3:140
4683 msgid "C89, C99, POSIX.1-2001."
4684 msgstr "C89, C99, POSIX.1-2001."
4685
4686 #. type: Plain text
4687 #: build/C/man3/gets.3:152
4688 msgid ""
4689 "LSB deprecates B<gets>().  POSIX.1-2008 marks B<gets>()  obsolescent.  ISO "
4690 "C11 removes the specification of B<gets>()  from the C language, and since "
4691 "version 2.16, glibc header files don't expose the function declaration if "
4692 "the B<_ISOC11_SOURCE> feature test macro is defined."
4693 msgstr ""
4694 "LSB は B<gets>() を非推奨としている。\n"
4695 "POSIX.1-2008 では B<gets>() に廃止予定の印が付けられている。\n"
4696 "ISO C11 では B<gets>)() の規定が C 言語から削除されている。\n"
4697 "glibc バージョン 2.16 以降では、機能検査マシン B<_ISOC11_SOURCE> が定義され"
4698 "た\n"
4699 "場合、glibc ヘッダファイルでは B<gets>)() の宣言が公開されない。"
4700
4701 #. type: Plain text
4702 #: build/C/man3/gets.3:166
4703 msgid ""
4704 "Never use B<gets>().  Because it is impossible to tell without knowing the "
4705 "data in advance how many characters B<gets>()  will read, and because B<gets>"
4706 "()  will continue to store characters past the end of the buffer, it is "
4707 "extremely dangerous to use.  It has been used to break computer security.  "
4708 "Use B<fgets>()  instead."
4709 msgstr ""
4710 "B<gets>()  は絶対に使用してはならない。 前もってデータを知ることなしに "
4711 "B<gets>()  が何文字読むかを知ることはできず、 B<gets>()  がバッファの終わりを"
4712 "越えて書き込み続けるため、 B<gets>()  を使うのは極めて危険である。 これを利用"
4713 "してコンピュータのセキュリティが破られてきた。 代わりに B<fgets>()  を使うこ"
4714 "と。"
4715
4716 #. type: Plain text
4717 #: build/C/man3/gets.3:173
4718 msgid ""
4719 "It is not advisable to mix calls to input functions from the I<stdio> "
4720 "library with low-level calls to B<read>(2)  for the file descriptor "
4721 "associated with the input stream; the results will be undefined and very "
4722 "probably not what you want."
4723 msgstr ""
4724 "入力ストリームのファイルディスクリプタに対して、 I<stdio> ライブラリの入力関"
4725 "数と、低レベル呼び出しの B<read>(2)  を混ぜて呼び出す事は勧められない。 結果"
4726 "がどうなるかは分からず、おそらくあなたの 望んでいる結果にはならないだろう。"
4727
4728 #. type: Plain text
4729 #: build/C/man3/gets.3:189
4730 msgid ""
4731 "B<read>(2), B<write>(2), B<ferror>(3), B<fgetwc>(3), B<fgetws>(3), B<fopen>"
4732 "(3), B<fread>(3), B<fseek>(3), B<getline>(3), B<getwchar>(3), B<puts>(3), "
4733 "B<scanf>(3), B<ungetwc>(3), B<unlocked_stdio>(3), B<feature_test_macros>(7)"
4734 msgstr ""
4735 "B<read>(2), B<write>(2), B<ferror>(3), B<fgetwc>(3), B<fgetws>(3),\n"
4736 "B<fopen>(3), B<fread>(3), B<fseek>(3), B<getline>(3), B<getwchar>(3),\n"
4737 "B<puts>(3), B<scanf>(3), B<ungetwc>(3), B<unlocked_stdio>(3),\n"
4738 "B<feature_test_macros>(7)"
4739
4740 #. type: TH
4741 #: build/C/man3/getw.3:25
4742 #, no-wrap
4743 msgid "GETW"
4744 msgstr "GETW"
4745
4746 #. type: TH
4747 #: build/C/man3/getw.3:25
4748 #, no-wrap
4749 msgid "2010-09-26"
4750 msgstr "2010-09-26"
4751
4752 #. type: Plain text
4753 #: build/C/man3/getw.3:28
4754 msgid "getw, putw - input and output of words (ints)"
4755 msgstr "getw, putw - ワード(int)の入出力"
4756
4757 #. type: Plain text
4758 #: build/C/man3/getw.3:33
4759 #, no-wrap
4760 msgid "B<int getw(FILE *>I<stream>B<);>\n"
4761 msgstr "B<int getw(FILE *>I<stream>B<);>\n"
4762
4763 #. type: Plain text
4764 #: build/C/man3/getw.3:35
4765 #, no-wrap
4766 msgid "B<int putw(int >I<w>B<, FILE *>I<stream>B<);>\n"
4767 msgstr "B<int putw(int >I<w>B<, FILE *>I<stream>B<);>\n"
4768
4769 #. type: Plain text
4770 #: build/C/man3/getw.3:44
4771 msgid "B<getw>(), B<putw>():"
4772 msgstr "B<getw>(), B<putw>():"
4773
4774 #. type: TP
4775 #: build/C/man3/getw.3:47
4776 #, no-wrap
4777 msgid "Since glibc 2.3.3:"
4778 msgstr "glibc 2.3.3 以降:"
4779
4780 #. type: Plain text
4781 #: build/C/man3/getw.3:50
4782 msgid "_SVID_SOURCE || _BSD_SOURCE ||"
4783 msgstr "_SVID_SOURCE || _BSD_SOURCE ||"
4784
4785 #. type: Plain text
4786 #: build/C/man3/getw.3:53
4787 #, no-wrap
4788 msgid ""
4789 "(_XOPEN_SOURCE &&\n"
4790 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600))\n"
4791 msgstr ""
4792 "(_XOPEN_SOURCE &&\n"
4793 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600))\n"
4794
4795 #. type: TP
4796 #: build/C/man3/getw.3:53
4797 #, no-wrap
4798 msgid "Before glibc 2.3.3:"
4799 msgstr "glibc 2.3.3 より前:"
4800
4801 #. type: Plain text
4802 #: build/C/man3/getw.3:56
4803 msgid "_SVID_SOURCE || _BSD_SOURCE || _XOPEN_SOURCE"
4804 msgstr "_SVID_SOURCE || _BSD_SOURCE || _XOPEN_SOURCE"
4805
4806 #. type: Plain text
4807 #: build/C/man3/getw.3:66
4808 msgid ""
4809 "B<getw>()  reads a word (that is, an I<int>) from I<stream>.  It's provided "
4810 "for compatibility with SVr4.  We recommend you use B<fread>(3)  instead."
4811 msgstr ""
4812 "B<getw>()  は I<stream> からワード (I<int>型) を読み込む。 この関数は、SVr4 "
4813 "との互換性のために提供されている。 この関数の代わりに B<fread>(3)  を使用する"
4814 "ことを勧める。"
4815
4816 #. type: Plain text
4817 #: build/C/man3/getw.3:73
4818 msgid ""
4819 "B<putw>()  writes the word I<w> (that is, an I<int>) to I<stream>.  It is "
4820 "provided for compatibility with SVr4, but we recommend you use B<fwrite>(3)  "
4821 "instead."
4822 msgstr ""
4823 "B<putw>()  は I<stream> にワード I<w> (I<int>型) を書き込む。 この関数は "
4824 "SVr4 との互換性のために提供されているが、この関数の代わりに B<fwrite>(3)  を"
4825 "使用することを勧める。"
4826
4827 #. type: Plain text
4828 #: build/C/man3/getw.3:80
4829 msgid ""
4830 "Normally, B<getw>()  returns the word read, and B<putw>()  returns 0.  On "
4831 "error, they return B<EOF>."
4832 msgstr ""
4833 "通常、 B<getw>()  は読み込んだワードを返し、 B<putw>()  は 0 を返す。 エラー"
4834 "が発生した場合、これらの関数は B<EOF> を返す。"
4835
4836 #. type: Plain text
4837 #: build/C/man3/getw.3:82
4838 msgid "SVr4, SUSv2.  Not present in POSIX.1-2001."
4839 msgstr "SVr4, SUSv2.  POSIX.1-2001 には存在しない。"
4840
4841 #. type: Plain text
4842 #: build/C/man3/getw.3:86
4843 msgid ""
4844 "The value returned on error is also a legitimate data value.  B<ferror>(3)  "
4845 "can be used to distinguish between the two cases."
4846 msgstr ""
4847 "エラーの時に返される値は、正しいデータとして返されることもある。 B<ferror>"
4848 "(3)  を用いると、この二つの場合を区別することが出来る。"
4849
4850 #. type: Plain text
4851 #: build/C/man3/getw.3:92
4852 msgid "B<ferror>(3), B<fread>(3), B<fwrite>(3), B<getc>(3), B<putc>(3)"
4853 msgstr "B<ferror>(3), B<fread>(3), B<fwrite>(3), B<getc>(3), B<putc>(3)"
4854
4855 #. type: TH
4856 #: build/C/man2/link.2:31
4857 #, no-wrap
4858 msgid "LINK"
4859 msgstr "LINK"
4860
4861 #. type: TH
4862 #: build/C/man2/link.2:31 build/C/man2/rename.2:32 build/C/man2/symlink.2:32
4863 #: build/C/man2/write.2:39
4864 #, no-wrap
4865 msgid "2013-01-27"
4866 msgstr "2013-01-27"
4867
4868 #. type: Plain text
4869 #: build/C/man2/link.2:34
4870 msgid "link - make a new name for a file"
4871 msgstr "link - ファイルの新しい名前を作成する"
4872
4873 #. type: Plain text
4874 #: build/C/man2/link.2:36 build/C/man2/lseek.2:54 build/C/man3/lseek64.3:34
4875 #: build/C/man2/readlink.2:48 build/C/man2/rmdir.2:35
4876 #: build/C/man2/symlink.2:37 build/C/man2/unlink.2:37 build/C/man2/write.2:44
4877 msgid "B<#include E<lt>unistd.hE<gt>>"
4878 msgstr "B<#include E<lt>unistd.hE<gt>>"
4879
4880 #. type: Plain text
4881 #: build/C/man2/link.2:38
4882 msgid "B<int link(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
4883 msgstr "B<int link(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
4884
4885 #. type: Plain text
4886 #: build/C/man2/link.2:41
4887 msgid ""
4888 "B<link>()  creates a new link (also known as a hard link) to an existing "
4889 "file."
4890 msgstr ""
4891 "B<link>()  は存在するファイルへの新しいリンク (link)  (ハードリンク (hard "
4892 "link) ともいう) を作成する。"
4893
4894 #. type: Plain text
4895 #: build/C/man2/link.2:47 build/C/man2/symlink.2:84
4896 msgid "If I<newpath> exists it will I<not> be overwritten."
4897 msgstr "I<newpath> が存在する場合には上書きはI<されない>。"
4898
4899 #. type: Plain text
4900 #: build/C/man2/link.2:52
4901 msgid ""
4902 "This new name may be used exactly as the old one for any operation; both "
4903 "names refer to the same file (and so have the same permissions and "
4904 "ownership) and it is impossible to tell which name was the \"original\"."
4905 msgstr ""
4906 "この新しい名前は全ての操作において古い名前と完全に同じように使用される; 両方"
4907 "の名前は同じファイルを参照しており (それで同じ許可 (permission) や所有者 "
4908 "(ownership) となるので)、 どちらの名前が本来のものであるか判別できない。"
4909
4910 #. type: Plain text
4911 #: build/C/man2/link.2:57 build/C/man2/pipe.2:97 build/C/man3/remove.3:65
4912 #: build/C/man2/rename.2:96 build/C/man2/rmdir.2:45 build/C/man2/symlink.2:89
4913 #: build/C/man2/unlink.2:60
4914 msgid ""
4915 "On success, zero is returned.  On error, -1 is returned, and I<errno> is set "
4916 "appropriately."
4917 msgstr ""
4918 "成功した場合は 0 が返される。エラーの場合は -1 が返され、 I<errno> が適切に設"
4919 "定される。"
4920
4921 #. type: TP
4922 #: build/C/man2/link.2:58 build/C/man2/open.2:486 build/C/man2/readlink.2:86
4923 #: build/C/man2/rename.2:97 build/C/man2/rmdir.2:46 build/C/man2/symlink.2:90
4924 #: build/C/man3/tmpfile.3:55 build/C/man2/unlink.2:61
4925 #, no-wrap
4926 msgid "B<EACCES>"
4927 msgstr "B<EACCES>"
4928
4929 #. type: Plain text
4930 #: build/C/man2/link.2:69
4931 msgid ""
4932 "Write access to the directory containing I<newpath> is denied, or search "
4933 "permission is denied for one of the directories in the path prefix of "
4934 "I<oldpath> or I<newpath>.  (See also B<path_resolution>(7).)"
4935 msgstr ""
4936 "I<newpath> を含んでいるディレクトリへの書き込みが許されていないか、 "
4937 "I<oldpath> または I<newpath> へのディレクトリのどれかに検索許可がない "
4938 "(B<path_resolution>(7)  を参照)。"
4939
4940 #. type: TP
4941 #: build/C/man2/link.2:69 build/C/man2/open.2:495 build/C/man2/rename.2:133
4942 #: build/C/man2/symlink.2:99 build/C/man2/write.2:135
4943 #, no-wrap
4944 msgid "B<EDQUOT>"
4945 msgstr ""
4946
4947 #. type: Plain text
4948 #: build/C/man2/link.2:72 build/C/man2/rename.2:136
4949 msgid "The user's quota of disk blocks on the file system has been exhausted."
4950 msgstr ""
4951
4952 #. type: TP
4953 #: build/C/man2/link.2:72 build/C/man2/open.2:501 build/C/man2/symlink.2:104
4954 #: build/C/man3/tmpfile.3:58
4955 #, no-wrap
4956 msgid "B<EEXIST>"
4957 msgstr "B<EEXIST>"
4958
4959 #. type: Plain text
4960 #: build/C/man2/link.2:76 build/C/man2/symlink.2:108
4961 msgid "I<newpath> already exists."
4962 msgstr "I<newpath> が既に存在する。"
4963
4964 #. type: TP
4965 #: build/C/man2/link.2:76 build/C/man2/llseek.2:74 build/C/man2/open.2:507
4966 #: build/C/man2/pipe.2:98 build/C/man2/read.2:118 build/C/man2/readlink.2:91
4967 #: build/C/man2/rename.2:136 build/C/man2/rmdir.2:64
4968 #: build/C/man2/symlink.2:108 build/C/man2/unlink.2:80
4969 #: build/C/man2/write.2:141
4970 #, no-wrap
4971 msgid "B<EFAULT>"
4972 msgstr "B<EFAULT>"
4973
4974 #. type: Plain text
4975 #: build/C/man2/link.2:79 build/C/man2/rename.2:139 build/C/man2/symlink.2:111
4976 msgid "I<oldpath> or I<newpath> points outside your accessible address space."
4977 msgstr ""
4978 "I<oldpath> や I<newpath> がアクセス可能なアドレス空間の外を指している。"
4979
4980 #. type: TP
4981 #: build/C/man2/link.2:79 build/C/man2/read.2:147 build/C/man2/readlink.2:107
4982 #: build/C/man2/symlink.2:111 build/C/man2/unlink.2:84
4983 #: build/C/man2/write.2:165
4984 #, no-wrap
4985 msgid "B<EIO>"
4986 msgstr "B<EIO>"
4987
4988 #. type: Plain text
4989 #: build/C/man2/link.2:82 build/C/man2/symlink.2:114 build/C/man2/unlink.2:87
4990 msgid "An I/O error occurred."
4991 msgstr "I/O エラーが発生した。"
4992
4993 #. type: TP
4994 #: build/C/man2/link.2:82 build/C/man2/open.2:531 build/C/man2/readlink.2:110
4995 #: build/C/man2/rename.2:149 build/C/man2/rmdir.2:73
4996 #: build/C/man2/symlink.2:114 build/C/man2/unlink.2:92
4997 #, no-wrap
4998 msgid "B<ELOOP>"
4999 msgstr "B<ELOOP>"
5000
5001 #. type: Plain text
5002 #: build/C/man2/link.2:86 build/C/man2/rename.2:153
5003 msgid ""
5004 "Too many symbolic links were encountered in resolving I<oldpath> or "
5005 "I<newpath>."
5006 msgstr ""
5007 "I<oldpath> または I<newpath> を解決する際に遭遇したシンボリックリンクが多過ぎ"
5008 "る。"
5009
5010 #. type: TP
5011 #: build/C/man2/link.2:86 build/C/man2/rename.2:153
5012 #, no-wrap
5013 msgid "B<EMLINK>"
5014 msgstr "B<EMLINK>"
5015
5016 #. type: Plain text
5017 #: build/C/man2/link.2:91
5018 msgid ""
5019 "The file referred to by I<oldpath> already has the maximum number of links "
5020 "to it."
5021 msgstr ""
5022 "I<oldpath> によって参照されるファイルは 既に最大数までのリンクを持っている。"
5023
5024 #. type: TP
5025 #: build/C/man2/link.2:91 build/C/man2/open.2:541 build/C/man2/readlink.2:113
5026 #: build/C/man2/rename.2:160 build/C/man2/rmdir.2:77
5027 #: build/C/man2/symlink.2:118 build/C/man2/unlink.2:96
5028 #, no-wrap
5029 msgid "B<ENAMETOOLONG>"
5030 msgstr "B<ENAMETOOLONG>"
5031
5032 #. type: Plain text
5033 #: build/C/man2/link.2:94 build/C/man2/rename.2:163 build/C/man2/symlink.2:121
5034 msgid "I<oldpath> or I<newpath> was too long."
5035 msgstr "I<oldpath> または I<newpath> が長過ぎる。"
5036
5037 #. type: TP
5038 #: build/C/man2/link.2:94 build/C/man2/open.2:555 build/C/man2/readlink.2:116
5039 #: build/C/man2/rename.2:163 build/C/man2/rmdir.2:80
5040 #: build/C/man2/symlink.2:121 build/C/man2/unlink.2:99
5041 #, no-wrap
5042 msgid "B<ENOENT>"
5043 msgstr "B<ENOENT>"
5044
5045 #. type: Plain text
5046 #: build/C/man2/link.2:99
5047 msgid ""
5048 "A directory component in I<oldpath> or I<newpath> does not exist or is a "
5049 "dangling symbolic link."
5050 msgstr ""
5051 "I<oldpath> または I<newpath> のディレクトリ部分が存在しないか、 壊れた"
5052 "(dangling)シンボリックリンクである。"
5053
5054 #. type: TP
5055 #: build/C/man2/link.2:99 build/C/man2/open.2:562 build/C/man2/readlink.2:119
5056 #: build/C/man2/rename.2:176 build/C/man2/rmdir.2:85 build/C/man3/scanf.3:571
5057 #: build/C/man2/symlink.2:128 build/C/man3/tempnam.3:93
5058 #: build/C/man2/unlink.2:106
5059 #, no-wrap
5060 msgid "B<ENOMEM>"
5061 msgstr "B<ENOMEM>"
5062
5063 #. type: Plain text
5064 #: build/C/man2/link.2:102 build/C/man2/open.2:565 build/C/man2/readlink.2:122
5065 #: build/C/man2/rename.2:179 build/C/man2/rmdir.2:88
5066 #: build/C/man2/symlink.2:131 build/C/man2/unlink.2:109
5067 msgid "Insufficient kernel memory was available."
5068 msgstr "十分なカーネルメモリーがない。"
5069
5070 #. type: TP
5071 #: build/C/man2/link.2:102 build/C/man2/open.2:565 build/C/man2/rename.2:179
5072 #: build/C/man2/symlink.2:131 build/C/man3/tmpfile.3:70
5073 #: build/C/man2/write.2:168
5074 #, no-wrap
5075 msgid "B<ENOSPC>"
5076 msgstr "B<ENOSPC>"
5077
5078 #. type: Plain text
5079 #: build/C/man2/link.2:106 build/C/man2/rename.2:183
5080 #: build/C/man2/symlink.2:135
5081 msgid "The device containing the file has no room for the new directory entry."
5082 msgstr ""
5083 "そのファイルを含んでいるデバイスに新しいディレクトリエントリを 作成するための"
5084 "空きがない。"
5085
5086 #. type: TP
5087 #: build/C/man2/link.2:106 build/C/man2/open.2:571 build/C/man2/readlink.2:122
5088 #: build/C/man2/rename.2:183 build/C/man2/rmdir.2:88
5089 #: build/C/man2/symlink.2:135 build/C/man2/unlink.2:109
5090 #, no-wrap
5091 msgid "B<ENOTDIR>"
5092 msgstr "B<ENOTDIR>"
5093
5094 #. type: Plain text
5095 #: build/C/man2/link.2:111
5096 msgid ""
5097 "A component used as a directory in I<oldpath> or I<newpath> is not, in fact, "
5098 "a directory."
5099 msgstr ""
5100 "I<oldpath> または I<newpath> のディレクトリ部分が、実際には、ディレクトリでな"
5101 "い。"
5102
5103 #. type: TP
5104 #: build/C/man2/link.2:111 build/C/man2/link.2:115 build/C/man2/open.2:604
5105 #: build/C/man2/rmdir.2:107 build/C/man2/rmdir.2:118
5106 #: build/C/man2/symlink.2:140 build/C/man2/unlink.2:114
5107 #, no-wrap
5108 msgid "B<EPERM>"
5109 msgstr "B<EPERM>"
5110
5111 #. type: Plain text
5112 #: build/C/man2/link.2:115
5113 msgid "I<oldpath> is a directory."
5114 msgstr "I<oldpath> がディレクトリである。"
5115
5116 #. type: Plain text
5117 #: build/C/man2/link.2:120
5118 msgid ""
5119 "The file system containing I<oldpath> and I<newpath> does not support the "
5120 "creation of hard links."
5121 msgstr ""
5122 "I<oldpath> と I<newpath> を含んでいるファイルシステムがハードリンクをサポート"
5123 "していない。"
5124
5125 #. type: TP
5126 #: build/C/man2/link.2:120
5127 #, no-wrap
5128 msgid "B<EPERM> (since Linux 3.6)"
5129 msgstr "B<EPERM> (Linux 3.6 以降)"
5130
5131 #. type: Plain text
5132 #: build/C/man2/link.2:127
5133 msgid ""
5134 "The caller does not have permission to create a hard link to this file (see "
5135 "the description of I</proc/sys/fs/protected_hardlink> in B<proc>(5))."
5136 msgstr ""
5137
5138 #. type: TP
5139 #: build/C/man2/link.2:127 build/C/man2/open.2:612 build/C/man2/rename.2:221
5140 #: build/C/man2/rmdir.2:123 build/C/man2/symlink.2:145
5141 #: build/C/man3/tmpfile.3:73 build/C/man2/unlink.2:137
5142 #, no-wrap
5143 msgid "B<EROFS>"
5144 msgstr "B<EROFS>"
5145
5146 #. type: Plain text
5147 #: build/C/man2/link.2:130 build/C/man2/rename.2:224
5148 msgid "The file is on a read-only file system."
5149 msgstr "ファイルが読み込み専用のファイルシステムに存在する。"
5150
5151 #. type: TP
5152 #: build/C/man2/link.2:130 build/C/man2/rename.2:224
5153 #, no-wrap
5154 msgid "B<EXDEV>"
5155 msgstr "B<EXDEV>"
5156
5157 #. type: Plain text
5158 #: build/C/man2/link.2:138
5159 msgid ""
5160 "I<oldpath> and I<newpath> are not on the same mounted file system.  (Linux "
5161 "permits a file system to be mounted at multiple points, but B<link>()  does "
5162 "not work across different mount points, even if the same file system is "
5163 "mounted on both.)"
5164 msgstr ""
5165 "I<oldpath> と I<newpath> が同じマウントされたファイルシステムに存在しない。 "
5166 "(Linux は 1 つのファイルシステムを複数のマウント位置に マウントすることを許可"
5167 "している。 しかし B<link>()  は、たとえ同じファイルシステムであっても、 別々"
5168 "のマウント位置を跨いでは動作しない。)"
5169
5170 #.  SVr4 documents additional ENOLINK and
5171 #.  EMULTIHOP error conditions; POSIX.1 does not document ELOOP.
5172 #.  X/OPEN does not document EFAULT, ENOMEM or EIO.
5173 #. type: Plain text
5174 #: build/C/man2/link.2:143
5175 msgid "SVr4, 4.3BSD, POSIX.1-2001 (but see NOTES)."
5176 msgstr "SVr4, 4.3BSD, POSIX.1-2001 (但し「注意」を参照)。"
5177
5178 #. type: Plain text
5179 #: build/C/man2/link.2:150
5180 msgid ""
5181 "Hard links, as created by B<link>(), cannot span file systems.  Use "
5182 "B<symlink>(2)  if this is required."
5183 msgstr ""
5184 "B<link>()  でファイルシステムを超えてハードリンクを作成することはできない。 "
5185 "このような場合は B<symlink>(2)  を使用すること。"
5186
5187 #.  more precisely: since kernel 1.3.56
5188 #.  For example, the default Solaris compilation environment
5189 #.  behaves like Linux, and contributors to a March 2005
5190 #.  thread in the Austin mailing list reported that some
5191 #.  other (System V) implementations did/do the same -- MTK, Apr 05
5192 #. type: Plain text
5193 #: build/C/man2/link.2:181
5194 msgid ""
5195 "POSIX.1-2001 says that B<link>()  should dereference I<oldpath> if it is a "
5196 "symbolic link.  However, since kernel 2.0, Linux does not do so: if "
5197 "I<oldpath> is a symbolic link, then I<newpath> is created as a (hard) link "
5198 "to the same symbolic link file (i.e., I<newpath> becomes a symbolic link to "
5199 "the same file that I<oldpath> refers to).  Some other implementations behave "
5200 "in the same manner as Linux.  POSIX.1-2008 changes the specification of "
5201 "B<link>(), making it implementation-dependent whether or not I<oldpath> is "
5202 "dereferenced if it is a symbolic link.  For precise control over the "
5203 "treatment of symbolic links when creating a link, see B<linkat>(2)."
5204 msgstr ""
5205 "POSIX.1-2001 では、 I<oldpath> がシンボリックリンクである場合、 B<link>()  "
5206 "は I<oldpath> の参照を解決すべきであると記述されている。 しかし、カーネル "
5207 "2.0 以降の Linux ではそのようになっていない。 I<oldpath> がシンボリックリンク"
5208 "である場合、 I<newpath> は同じシンボリックリンクファイルへの (ハード) リンク"
5209 "として作成される (つまり I<newpath> は I<oldpath> が参照していた同じファイル"
5210 "へのシンボリックリンクになる)。 他のいくつかの実装でも Linux と同じように動作"
5211 "する。 POSIX.1-2008 では B<link>()  の仕様が変更され、 I<oldpath> がシンボ"
5212 "リックリンクの場合にシンボリックリンクの参照を 解決するかどうかは実装依存と"
5213 "なった。 リンク作成時のシンボリックリンクの扱いについての詳細な制御に 関して"
5214 "は B<linkat>(2)  を参照のこと。"
5215
5216 #. type: Plain text
5217 #: build/C/man2/link.2:187
5218 msgid ""
5219 "On NFS file systems, the return code may be wrong in case the NFS server "
5220 "performs the link creation and dies before it can say so.  Use B<stat>(2)  "
5221 "to find out if the link got created."
5222 msgstr ""
5223 "NFS ファイルシステムでは、NFS サーバーがリンクを作成した後に、 それを伝える前"
5224 "に死んだ場合には返り値が不正な場合がある。 リンクが作成できたかどうか見つける"
5225 "ためには B<stat>(2)  を使用すること。"
5226
5227 #. type: Plain text
5228 #: build/C/man2/link.2:197
5229 msgid ""
5230 "B<ln>(1), B<linkat>(2), B<open>(2), B<rename>(2), B<stat>(2), B<symlink>(2), "
5231 "B<unlink>(2), B<path_resolution>(7), B<symlink>(7)"
5232 msgstr ""
5233 "B<ln>(1), B<linkat>(2), B<open>(2), B<rename>(2), B<stat>(2), B<symlink>(2), "
5234 "B<unlink>(2), B<path_resolution>(7), B<symlink>(7)"
5235
5236 #. type: TH
5237 #: build/C/man2/llseek.2:28
5238 #, no-wrap
5239 msgid "LLSEEK"
5240 msgstr "LLSEEK"
5241
5242 #. type: TH
5243 #: build/C/man2/llseek.2:28
5244 #, no-wrap
5245 msgid "2012-07-13"
5246 msgstr "2012-07-13"
5247
5248 #. type: Plain text
5249 #: build/C/man2/llseek.2:31
5250 msgid "_llseek - reposition read/write file offset"
5251 msgstr "_llseek - ファイルの読み書きオフセットの位置を変える"
5252
5253 #. type: Plain text
5254 #: build/C/man2/llseek.2:35
5255 #, no-wrap
5256 msgid ""
5257 "B<#include E<lt>sys/types.hE<gt>>\n"
5258 "B<#include E<lt>unistd.hE<gt>>\n"
5259 msgstr ""
5260 "B<#include E<lt>sys/types.hE<gt>>\n"
5261 "B<#include E<lt>unistd.hE<gt>>\n"
5262
5263 #. type: Plain text
5264 #: build/C/man2/llseek.2:39
5265 #, no-wrap
5266 msgid ""
5267 "B<int _llseek(unsigned int >I<fd>B<, unsigned long >I<offset_high>B<,>\n"
5268 "B<            unsigned long >I<offset_low>B<, loff_t *>I<result>B<,>\n"
5269 "B<            unsigned int >I<whence>B<);>\n"
5270 msgstr ""
5271 "B<int _llseek(unsigned int >I<fd>B<, unsigned long >I<offset_high>B<,>\n"
5272 "B<            unsigned long >I<offset_low>B<, loff_t *>I<result>B<,>\n"
5273 "B<            unsigned int >I<whence>B<);>\n"
5274
5275 #. type: Plain text
5276 #: build/C/man2/llseek.2:43
5277 msgid "I<Note>: There is no glibc wrapper for this system call; see NOTES."
5278 msgstr ""
5279 "I<注>: このシステムコールには glibc のラッパー関数は存在しない。「注意」の節"
5280 "を参照。"
5281
5282 #. type: Plain text
5283 #: build/C/man2/llseek.2:62
5284 msgid ""
5285 "The B<_llseek>()  function repositions the offset of the open file "
5286 "associated with the file descriptor I<fd> to I<(offset_highE<lt>E<lt>32) | "
5287 "offset_low> bytes relative to the beginning of the file, the current "
5288 "position in the file, or the end of the file, depending on whether I<whence> "
5289 "is B<SEEK_SET>, B<SEEK_CUR>, or B<SEEK_END>, respectively.  It returns the "
5290 "resulting file position in the argument I<result>."
5291 msgstr ""
5292 "B<_llseek>()  関数は、ファイルディスクリプタ (descriptor)  I<fd> に関連づけら"
5293 "れたオープンされたファイルのオフセットの位置を、相対的に I<"
5294 "(offset_highE<lt>E<lt>32) | offset_low> バイトだけ変更する。 基準となる位置を"
5295 "表す I<whence> には B<SEEK_SET>, B<SEEK_CUR>, B<SEEK_END> のいずれかを指定"
5296 "し、それぞれ ファイルの先頭、ファイルの現在位置、 ファイルの最後を表す。 結果"
5297 "のファイル位置を I<result> 引き数に返す。"
5298
5299 #. type: Plain text
5300 #: build/C/man2/llseek.2:69
5301 msgid ""
5302 "Upon successful completion, B<_llseek>()  returns 0.  Otherwise, a value of "
5303 "-1 is returned and I<errno> is set to indicate the error."
5304 msgstr ""
5305 "成功した場合は、 B<_llseek>()  は 0 を返す。 そうでなれば -1 という値が返り、"
5306 "エラーを示す I<errno> が設定される。"
5307
5308 #. type: Plain text
5309 #: build/C/man2/llseek.2:74 build/C/man2/lseek.2:175
5310 msgid "I<fd> is not an open file descriptor."
5311 msgstr "I<fd> がオープンされたファイルディスクリプタでない。"
5312
5313 #. type: Plain text
5314 #: build/C/man2/llseek.2:77
5315 msgid "Problem with copying results to user space."
5316 msgstr "結果をユーザ空間にコピーするときに問題があった。"
5317
5318 #. type: Plain text
5319 #: build/C/man2/llseek.2:81
5320 msgid "I<whence> is invalid."
5321 msgstr "I<whence> が不正である。"
5322
5323 #. type: Plain text
5324 #: build/C/man2/llseek.2:84
5325 msgid ""
5326 "This function is Linux-specific, and should not be used in programs intended "
5327 "to be portable."
5328 msgstr ""
5329 "この関数は Linux 特有であり、移植性の必要なプログラムでは使用してはいけない。"
5330
5331 #. type: Plain text
5332 #: build/C/man2/llseek.2:87
5333 msgid ""
5334 "Glibc does not provide a wrapper for this system call; call it using "
5335 "B<syscall>(2)."
5336 msgstr ""
5337 "glibc はこのシステムコールに対するラッパー関数を提供していない。 B<syscall>"
5338 "(2)  を使って呼び出すこと。"
5339
5340 #. type: Plain text
5341 #: build/C/man2/llseek.2:90
5342 msgid "B<lseek>(2), B<lseek64>(3)"
5343 msgstr "B<lseek>(2), B<lseek64>(3)"
5344
5345 #. type: TH
5346 #: build/C/man2/lseek.2:47
5347 #, no-wrap
5348 msgid "LSEEK"
5349 msgstr "LSEEK"
5350
5351 #. type: TH
5352 #: build/C/man2/lseek.2:47
5353 #, fuzzy, no-wrap
5354 #| msgid "2013-01-27"
5355 msgid "2013-03-27"
5356 msgstr "2013-01-27"
5357
5358 #. type: Plain text
5359 #: build/C/man2/lseek.2:50
5360 msgid "lseek - reposition read/write file offset"
5361 msgstr "lseek - ファイルの読み書きオフセットの位置を変える"
5362
5363 #. type: Plain text
5364 #: build/C/man2/lseek.2:52 build/C/man3/lseek64.3:32
5365 msgid "B<#include E<lt>sys/types.hE<gt>>"
5366 msgstr "B<#include E<lt>sys/types.hE<gt>>"
5367
5368 #. type: Plain text
5369 #: build/C/man2/lseek.2:56
5370 msgid "B<off_t lseek(int >I<fd>B<, off_t >I<offset>B<, int >I<whence>B<);>"
5371 msgstr "B<off_t lseek(int >I<fd>B<, off_t >I<offset>B<, int >I<whence>B<);>"
5372
5373 #. type: Plain text
5374 #: build/C/man2/lseek.2:67
5375 msgid ""
5376 "The B<lseek>()  function repositions the offset of the open file associated "
5377 "with the file descriptor I<fd> to the argument I<offset> according to the "
5378 "directive I<whence> as follows:"
5379 msgstr ""
5380 "B<lseek>()  関数は、ファイルディスクリプタ (descriptor)  I<fd> に対応するオー"
5381 "プンされたファイルのオフセットを、 I<whence> に基づき I<offset> 引き数の位置"
5382 "へ以下のように変更する:"
5383
5384 #. type: Plain text
5385 #: build/C/man2/lseek.2:72
5386 msgid "The offset is set to I<offset> bytes."
5387 msgstr "オフセットは I<offset> バイトに設定される。"
5388
5389 #. type: Plain text
5390 #: build/C/man2/lseek.2:77
5391 msgid "The offset is set to its current location plus I<offset> bytes."
5392 msgstr "オフセットは現在位置に I<offset> バイトを足した位置になる。"
5393
5394 #. type: Plain text
5395 #: build/C/man2/lseek.2:82
5396 msgid "The offset is set to the size of the file plus I<offset> bytes."
5397 msgstr "オフセットはファイルのサイズに I<offset> バイトを足した位置になる。"
5398
5399 #. type: Plain text
5400 #: build/C/man2/lseek.2:90
5401 msgid ""
5402 "The B<lseek>()  function allows the file offset to be set beyond the end of "
5403 "the file (but this does not change the size of the file).  If data is later "
5404 "written at this point, subsequent reads of the data in the gap (a \"hole\") "
5405 "return null bytes (\\(aq\\e0\\(aq) until data is actually written into the "
5406 "gap."
5407 msgstr ""
5408 "B<lseek>()  関数は、オフセットをファイルの末尾を越えた位置に設定できる (但"
5409 "し、これによりファイルのサイズが変わらない)。 もしデータがこのオフセット位置"
5410 "以降に書き込まれた場合、 間の空隙の部分 (\"穴 (hole)\") の読み出しがあると、 "
5411 "実際にそこにデータを書き込まれるまでは NULL バイト (\\(aq\\e0\\(aq) の列が返"
5412 "される。"
5413
5414 #. type: SS
5415 #: build/C/man2/lseek.2:90
5416 #, no-wrap
5417 msgid "Seeking file data and holes"
5418 msgstr ""
5419
5420 #. type: Plain text
5421 #: build/C/man2/lseek.2:93
5422 msgid ""
5423 "Since version 3.1, Linux supports the following additional values for "
5424 "I<whence>:"
5425 msgstr ""
5426 "Linux バージョン 3.1 以降では、\n"
5427 "I<whence> に以下の値も指定することができる。"
5428
5429 #. type: TP
5430 #: build/C/man2/lseek.2:93
5431 #, no-wrap
5432 msgid "B<SEEK_DATA>"
5433 msgstr "B<SEEK_DATA>"
5434
5435 #. type: Plain text
5436 #: build/C/man2/lseek.2:104
5437 msgid ""
5438 "Adjust the file offset to the next location in the file greater than or "
5439 "equal to I<offset> containing data.  If I<offset> points to data, then the "
5440 "file offset is set to I<offset>."
5441 msgstr ""
5442
5443 #. type: TP
5444 #: build/C/man2/lseek.2:104
5445 #, no-wrap
5446 msgid "B<SEEK_HOLE>"
5447 msgstr "B<SEEK_HOLE>"
5448
5449 #. type: Plain text
5450 #: build/C/man2/lseek.2:118
5451 msgid ""
5452 "Adjust the file offset to the next hole in the file greater than or equal to "
5453 "I<offset>.  If I<offset> points into the middle of a hole, then the file "
5454 "offset is set to I<offset>.  If there is no hole past I<offset>, then the "
5455 "file offset is adjusted to the end of the file (i.e., there is an implicit "
5456 "hole at the end of any file)."
5457 msgstr ""
5458
5459 #. type: Plain text
5460 #: build/C/man2/lseek.2:124
5461 msgid ""
5462 "In both of the above cases, B<lseek>()  fails if I<offset> points past the "
5463 "end of the file."
5464 msgstr ""
5465
5466 #. type: Plain text
5467 #: build/C/man2/lseek.2:130
5468 msgid ""
5469 "These operations allow applications to map holes in a sparsely allocated "
5470 "file.  This can be useful for applications such as file backup tools, which "
5471 "can save space when creating backups and preserve holes, if they have a "
5472 "mechanism for discovering holes."
5473 msgstr ""
5474
5475 #.  https://lkml.org/lkml/2011/4/22/79
5476 #.  http://lwn.net/Articles/440255/
5477 #.  http://blogs.oracle.com/bonwick/entry/seek_hole_and_seek_data
5478 #. type: Plain text
5479 #: build/C/man2/lseek.2:153
5480 msgid ""
5481 "For the purposes of these operations, a hole is a sequence of zeros that "
5482 "(normally) has not been allocated in the underlying file storage.  However, "
5483 "a file system is not obliged to report holes, so these operations are not a "
5484 "guaranteed mechanism for mapping the storage space actually allocated to a "
5485 "file.  (Furthermore, a sequence of zeros that actually has been written to "
5486 "the underlying storage may not be reported as a hole.)  In the simplest "
5487 "implementation, a file system can support the operations by making "
5488 "B<SEEK_HOLE> always return the offset of the end of the file, and making "
5489 "B<SEEK_DATA> always return I<offset> (i.e., even if the location referred to "
5490 "by I<offset> is a hole, it can be considered to consist of data that is a "
5491 "sequence of zeros)."
5492 msgstr ""
5493
5494 #. type: Plain text
5495 #: build/C/man2/lseek.2:162
5496 msgid ""
5497 "The B<_GNU_SOURCE> feature test macro must be defined in order to obtain the "
5498 "definitions of B<SEEK_DATA> and B<SEEK_HOLE> from I<E<lt>unistd.hE<gt>>."
5499 msgstr ""
5500
5501 #. type: Plain text
5502 #: build/C/man2/lseek.2:170
5503 msgid ""
5504 "Upon successful completion, B<lseek>()  returns the resulting offset "
5505 "location as measured in bytes from the beginning of the file.  On error, the "
5506 "value I<(off_t)\\ -1> is returned and I<errno> is set to indicate the error."
5507 msgstr ""
5508 "成功した場合、 B<lseek>()  は結果のファイル位置をファイルの先頭からのバイト数"
5509 "で返す。 エラーの場合、値 I<(off_t)\\ -1> が返され、 I<errno> にエラーが指示"
5510 "される。"
5511
5512 #.  Some systems may allow negative offsets for character devices
5513 #.  and/or for remote file systems.
5514 #. type: Plain text
5515 #: build/C/man2/lseek.2:183
5516 msgid ""
5517 "I<whence> is not valid.  Or: the resulting file offset would be negative, or "
5518 "beyond the end of a seekable device."
5519 msgstr ""
5520 "I<whence> が有効な値ではない。または、seek の結果、ファイルオフセットが負に\n"
5521 "なってしまうか、 seek 可能なデバイスの末尾を越えてしまう。"
5522
5523 #. type: TP
5524 #: build/C/man2/lseek.2:183 build/C/man2/open.2:584
5525 #, no-wrap
5526 msgid "B<EOVERFLOW>"
5527 msgstr "B<EOVERFLOW>"
5528
5529 #.  HP-UX 11 says EINVAL for this case (but POSIX.1 says EOVERFLOW)
5530 #. type: Plain text
5531 #: build/C/man2/lseek.2:188
5532 msgid "The resulting file offset cannot be represented in an I<off_t>."
5533 msgstr "結果のファイルオフセットを I<off_t> 型で表現することができない。"
5534
5535 #. type: TP
5536 #: build/C/man2/lseek.2:188
5537 #, no-wrap
5538 msgid "B<ESPIPE>"
5539 msgstr "B<ESPIPE>"
5540
5541 #. type: Plain text
5542 #: build/C/man2/lseek.2:192
5543 msgid "I<fd> is associated with a pipe, socket, or FIFO."
5544 msgstr "I<fd> がパイプ、ソケット、FIFO を参照している。"
5545
5546 #. type: TP
5547 #: build/C/man2/lseek.2:192 build/C/man2/open.2:578
5548 #, no-wrap
5549 msgid "B<ENXIO>"
5550 msgstr "B<ENXIO>"
5551
5552 #. type: Plain text
5553 #: build/C/man2/lseek.2:200
5554 msgid ""
5555 "I<whence> is B<SEEK_DATA> or B<SEEK_HOLE>, and the current file offset is "
5556 "beyond the end of the file."
5557 msgstr ""
5558 "I<whence> が B<SEEK_DATA> か B<SEEK_HOLE> で、\n"
5559 "現在のファイルオフセットがファイルの末尾を超えた位置である。"
5560
5561 #.  SVr4 documents additional error
5562 #.  conditions EDEADLK, ENOLCK, ENOLNK, ENOSR, ENXIO, or ERANGE.
5563 #. type: Plain text
5564 #: build/C/man2/lseek.2:202 build/C/man2/read.2:175 build/C/man2/rmdir.2:129
5565 #: build/C/man2/symlink.2:155 build/C/man2/unlink.2:145
5566 #: build/C/man2/write.2:189
5567 msgid "SVr4, 4.3BSD, POSIX.1-2001."
5568 msgstr "SVr4, 4.3BSD, POSIX.1-2001."
5569
5570 #.  FIXME . Review http://austingroupbugs.net/view.php?id=415 in the future
5571 #. type: Plain text
5572 #: build/C/man2/lseek.2:210
5573 msgid ""
5574 "B<SEEK_DATA> and B<SEEK_HOLE> are nonstandard extensions also present in "
5575 "Solaris, FreeBSD, and DragonFly BSD; they are proposed for inclusion in the "
5576 "next POSIX revision (Issue 8)."
5577 msgstr ""
5578
5579 #. type: Plain text
5580 #: build/C/man2/lseek.2:214
5581 msgid ""
5582 "Some devices are incapable of seeking and POSIX does not specify which "
5583 "devices must support B<lseek>()."
5584 msgstr ""
5585 "いくつかのデバイスでは seek ができない。 POSIX はどのデバイスが B<lseek>()  "
5586 "に対応すべきかは規定していない。"
5587
5588 #.  Other systems return the number of written characters,
5589 #.  using SEEK_SET to set the counter. (Of written characters.)
5590 #. type: Plain text
5591 #: build/C/man2/lseek.2:221
5592 msgid "On Linux, using B<lseek>()  on a terminal device returns B<ESPIPE>."
5593 msgstr ""
5594 "Linux では、端末 (terminal) デバイスに B<lseek>() を使用すると B<ESPIPE> が返"
5595 "る。"
5596
5597 #. type: Plain text
5598 #: build/C/man2/lseek.2:224
5599 msgid ""
5600 "When converting old code, substitute values for I<whence> with the following "
5601 "macros:"
5602 msgstr "古いコードを変換する時は I<whence> の値を以下のマクロに置き換えること:"
5603
5604 #. type: tbl table
5605 #: build/C/man2/lseek.2:227
5606 #, no-wrap
5607 msgid "old\tnew\n"
5608 msgstr "old \tnew\n"
5609
5610 #. type: tbl table
5611 #: build/C/man2/lseek.2:228
5612 #, no-wrap
5613 msgid "0\tSEEK_SET\n"
5614 msgstr "0\tSEEK_SET\n"
5615
5616 #. type: tbl table
5617 #: build/C/man2/lseek.2:229
5618 #, no-wrap
5619 msgid "1\tSEEK_CUR\n"
5620 msgstr "1\tSEEK_CUR\n"
5621
5622 #. type: tbl table
5623 #: build/C/man2/lseek.2:230
5624 #, no-wrap
5625 msgid "2\tSEEK_END\n"
5626 msgstr "2\tSEEK_END\n"
5627
5628 #. type: tbl table
5629 #: build/C/man2/lseek.2:231
5630 #, no-wrap
5631 msgid "L_SET\tSEEK_SET\n"
5632 msgstr "L_SET\tSEEK_SET\n"
5633
5634 #. type: tbl table
5635 #: build/C/man2/lseek.2:232
5636 #, no-wrap
5637 msgid "L_INCR\tSEEK_CUR\n"
5638 msgstr "L_INCR\tSEEK_CUR\n"
5639
5640 #. type: tbl table
5641 #: build/C/man2/lseek.2:233
5642 #, no-wrap
5643 msgid "L_XTND\tSEEK_END\n"
5644 msgstr "L_XTND\tSEEK_END\n"
5645
5646 #. type: Plain text
5647 #: build/C/man2/lseek.2:245
5648 msgid ""
5649 "Note that file descriptors created by B<dup>(2)  or B<fork>(2)  share the "
5650 "current file position pointer, so seeking on such files may be subject to "
5651 "race conditions."
5652 msgstr ""
5653 "B<dup>(2)  や B<fork>(2)  で作成されたファイルディスクリプタは、現在のファイ"
5654 "ル位置ポインタ (current file position pointer) を共有しているので、 このよう"
5655 "なファイルで移動を行うと競合状態を引き起こす可能性がある。"
5656
5657 #. type: Plain text
5658 #: build/C/man2/lseek.2:252
5659 msgid ""
5660 "B<dup>(2), B<fork>(2), B<open>(2), B<fseek>(3), B<lseek64>(3), "
5661 "B<posix_fallocate>(3)"
5662 msgstr ""
5663 "B<dup>(2), B<fork>(2), B<open>(2), B<fseek>(3), B<lseek64>(3), "
5664 "B<posix_fallocate>(3)"
5665
5666 #. type: TH
5667 #: build/C/man3/lseek64.3:25
5668 #, no-wrap
5669 msgid "LSEEK64"
5670 msgstr "LSEEK64"
5671
5672 #. type: TH
5673 #: build/C/man3/lseek64.3:25
5674 #, no-wrap
5675 msgid "2004-12-11"
5676 msgstr "2004-12-11"
5677
5678 #. type: Plain text
5679 #: build/C/man3/lseek64.3:28
5680 msgid "lseek64 - reposition 64-bit read/write file offset"
5681 msgstr "lseek64 - ファイルの 64 ビットの読み書きオフセットの位置を変える"
5682
5683 #. type: Plain text
5684 #: build/C/man3/lseek64.3:30
5685 msgid "B<#define _LARGEFILE64_SOURCE> /* See feature_test_macros(7) */"
5686 msgstr "B<#define _LARGEFILE64_SOURCE> /* feature_test_macros(7) 参照 */"
5687
5688 #. type: Plain text
5689 #: build/C/man3/lseek64.3:36
5690 msgid ""
5691 "B<off64_t lseek64(int >I<fd>B<, off64_t >I<offset>B<, int >I<whence>B<);>"
5692 msgstr ""
5693 "B<off64_t lseek64(int >I<fd>B<, off64_t >I<offset>B<, int >I<whence>B<);>"
5694
5695 #. type: Plain text
5696 #: build/C/man3/lseek64.3:53
5697 msgid ""
5698 "The B<lseek>(2)  family of functions reposition the offset of the open file "
5699 "associated with the file descriptor I<fd> to I<offset> bytes relative to the "
5700 "start, current position, or end of the file, when I<whence> has the value "
5701 "B<SEEK_SET>, B<SEEK_CUR>, or B<SEEK_END>, respectively."
5702 msgstr ""
5703 "B<lseek>(2)  関数ファミリーは、ファイルディスクリプタ I<fd> に関連するオープ"
5704 "ンされたファイルのオフセットを、 ファイルの開始位置・現在位置・終端から "
5705 "I<offset> の位置へ変更する。 これは I<whence> がそれぞれ B<SEEK_SET>, "
5706 "B<SEEK_CUR>, B<SEEK_END> の場合に対応する。"
5707
5708 #. type: Plain text
5709 #: build/C/man3/lseek64.3:56
5710 msgid "For more details, return value, and errors, see B<lseek>(2)."
5711 msgstr "更に詳しい説明・返り値・エラーは、 B<lseek>(2)  を参照すること。"
5712
5713 #. type: Plain text
5714 #: build/C/man3/lseek64.3:63
5715 msgid ""
5716 "Four interfaces are available: B<lseek>(2), B<lseek64>(), B<llseek>(2), and "
5717 "the raw system call B<_llseek>(2)."
5718 msgstr ""
5719 "4 つのインタフェースが使用可能である: B<lseek>(2), B<lseek64>(), B<llseek>"
5720 "(2)  と元となるシステムコール B<_llseek>(2)  である。"
5721
5722 #. type: SS
5723 #: build/C/man3/lseek64.3:63
5724 #, no-wrap
5725 msgid "lseek"
5726 msgstr "lseek"
5727
5728 #. type: Plain text
5729 #: build/C/man3/lseek64.3:65 build/C/man3/lseek64.3:87
5730 #: build/C/man3/lseek64.3:116
5731 msgid "Prototype:"
5732 msgstr "プロトタイプ:"
5733
5734 #. type: Plain text
5735 #: build/C/man3/lseek64.3:69
5736 #, no-wrap
5737 msgid "B<off_t lseek(int >I<fd>B<, off_t >I<offset>B<, int >I<whence>B<);>\n"
5738 msgstr "B<off_t lseek(int >I<fd>B<, off_t >I<offset>B<, int >I<whence>B<);>\n"
5739
5740 #. type: Plain text
5741 #: build/C/man3/lseek64.3:77
5742 msgid ""
5743 "B<lseek>(2)  uses the type I<off_t>.  This is a 32-bit signed type on 32-bit "
5744 "architectures, unless one compiles with"
5745 msgstr ""
5746 "B<lseek>(2)  は型 I<off_t> を使う。 これは 32 ビットアーキテクチャ上では 32 "
5747 "ビット符号付き型である。 ただし、"
5748
5749 #. type: Plain text
5750 #: build/C/man3/lseek64.3:85
5751 msgid "in which case it is a 64-bit signed type."
5752 msgstr "を定義してコンパイルした場合は 64 ビット符号付き型である。"
5753
5754 #. type: SS
5755 #: build/C/man3/lseek64.3:85
5756 #, no-wrap
5757 msgid "lseek64"
5758 msgstr "lseek64"
5759
5760 #. type: Plain text
5761 #: build/C/man3/lseek64.3:91
5762 #, no-wrap
5763 msgid "B<off64_t lseek64(int >I<fd>B<, off64_t >I<offset>B<, int >I<whence>B<);>\n"
5764 msgstr "B<off64_t lseek64(int >I<fd>B<, off64_t >I<offset>B<, int >I<whence>B<);>\n"
5765
5766 #. type: Plain text
5767 #: build/C/man3/lseek64.3:102
5768 msgid ""
5769 "The library routine B<lseek64>()  uses a 64-bit type even when I<off_t> is a "
5770 "32-bit type.  Its prototype (and the type I<off64_t>)  is available only "
5771 "when one compiles with"
5772 msgstr ""
5773 "ライブラリルーチン B<lseek64>()  は I<off_t> が 32 ビット型であっても 64 ビッ"
5774 "ト型を使う。 このプロトタイプ (と型 I<off64_t>)  は、以下の定義をしてコンパイ"
5775 "ルした場合にのみ使用可能である。"
5776
5777 #. type: Plain text
5778 #: build/C/man3/lseek64.3:106
5779 #, no-wrap
5780 msgid "#define _LARGEFILE64_SOURCE\n"
5781 msgstr "#define _LARGEFILE64_SOURCE\n"
5782
5783 #.  in glibc 2.0.94, not in 2.0.6
5784 #. type: Plain text
5785 #: build/C/man3/lseek64.3:114
5786 msgid ""
5787 "The function B<lseek64>()  is available since glibc 2.1, and is defined to "
5788 "be an alias for B<llseek>()."
5789 msgstr ""
5790 "関数 B<lseek64>()  は glibc 2.1 以降で使用可能であり、 B<llseek>()  のエイリ"
5791 "アスとして定義されている。"
5792
5793 #. type: SS
5794 #: build/C/man3/lseek64.3:114
5795 #, no-wrap
5796 msgid "llseek"
5797 msgstr "llseek"
5798
5799 #. type: Plain text
5800 #: build/C/man3/lseek64.3:120
5801 #, no-wrap
5802 msgid "B<loff_t llseek(int >I<fd>B<, loff_t >I<offset>B<, int >I<whence>B<);>\n"
5803 msgstr "B<loff_t llseek(int >I<fd>B<, loff_t >I<offset>B<, int >I<whence>B<);>\n"
5804
5805 #.  in libc 5.0.9, not in 4.7.6
5806 #. type: Plain text
5807 #: build/C/man3/lseek64.3:139
5808 msgid ""
5809 "The type I<loff_t> is a 64-bit signed type.  The library routine B<llseek>"
5810 "()  is available in libc5 and glibc and works without special defines.  Its "
5811 "prototype was given in I<E<lt>unistd.hE<gt>> with libc5, but glibc does not "
5812 "provide a prototype.  This is bad, since a prototype is needed.  Users "
5813 "should add the above prototype, or something equivalent, to their own "
5814 "source.  When users complained about data loss caused by a miscompilation of "
5815 "B<e2fsck>(8), glibc 2.1.3 added the link-time warning"
5816 msgstr ""
5817 "型 I<loff_t> は 64 ビット符号付き型である。 ライブラリルーチン B<llseek>()  "
5818 "は libc5 と glibc で使用可能であり、特別な定義なしに動作する。 このプロトタイ"
5819 "プは、libc5 では I<E<lt>unistd.hE<gt>> で与えられるが、glibc はプロトタイプを"
5820 "提供しない。 これはプロトタイプが必要になるので良くない。 ユーザは上記のプロ"
5821 "トタイプまたはそれと同等のものを、 自身のソースに追加しなければならない。 こ"
5822 "のデータがないことによって B<e2fsck>(8)  のコンパイルが失敗するという苦情が"
5823 "ユーザから出たので、 glibc 2.1.3 では以下のようなリンク時の警告が追加された。"
5824
5825 #. type: Plain text
5826 #: build/C/man3/lseek64.3:142
5827 msgid "the \\`llseek\\' function may be dangerous; use \\`lseek64\\' instead."
5828 msgstr "the \\`llseek\\' function may be dangerous; use \\`lseek64\\' instead."
5829
5830 #. type: Plain text
5831 #: build/C/man3/lseek64.3:146
5832 msgid ""
5833 "This makes this function unusable if one desires a warning-free compilation."
5834 msgstr ""
5835 "これにより、警告なしでコンパイルしたい場合には、この関数を使用不可にできる。"
5836
5837 #. type: SS
5838 #: build/C/man3/lseek64.3:146
5839 #, no-wrap
5840 msgid "_llseek"
5841 msgstr "_llseek"
5842
5843 #. type: Plain text
5844 #: build/C/man3/lseek64.3:149
5845 msgid ""
5846 "All the above functions are implemented in terms of this system call.  The "
5847 "prototype is:"
5848 msgstr ""
5849 "上記の全ての関数は、このシステムコールに基づいて実装される。 プロトタイプは以"
5850 "下の通り:"
5851
5852 #. type: Plain text
5853 #: build/C/man3/lseek64.3:154
5854 #, no-wrap
5855 msgid ""
5856 "B<int _llseek(int >I<fd>B<, off_t >I<offset_hi>B<, off_t >I<offset_lo>B<,>\n"
5857 "B<            loff_t *>I<result>B<, int >I<whence>B<);>\n"
5858 msgstr ""
5859 "B<int _llseek(int >I<fd>B<, off_t >I<offset_hi>B<, off_t >I<offset_lo>B<,>\n"
5860 "B<            loff_t *>I<result>B<, int >I<whence>B<);>\n"
5861
5862 #. type: Plain text
5863 #: build/C/man3/lseek64.3:159
5864 msgid "For more details, see B<llseek>(2)."
5865 msgstr "更に詳しい情報は、 B<llseek>(2)  を参照すること。"
5866
5867 #. type: Plain text
5868 #: build/C/man3/lseek64.3:162
5869 msgid "B<llseek>(2), B<lseek>(2)"
5870 msgstr "B<llseek>(2), B<lseek>(2)"
5871
5872 #. type: TH
5873 #: build/C/man2/open.2:52
5874 #, no-wrap
5875 msgid "OPEN"
5876 msgstr "OPEN"
5877
5878 #. type: TH
5879 #: build/C/man2/open.2:52
5880 #, no-wrap
5881 msgid "2013-02-18"
5882 msgstr "2013-02-18"
5883
5884 #. type: Plain text
5885 #: build/C/man2/open.2:55
5886 msgid "open, creat - open and possibly create a file or device"
5887 msgstr "open, creat - ファイルやデバイスのオープン、作成を行う"
5888
5889 #. type: Plain text
5890 #: build/C/man2/open.2:60
5891 #, no-wrap
5892 msgid ""
5893 "B<#include E<lt>sys/types.hE<gt>>\n"
5894 "B<#include E<lt>sys/stat.hE<gt>>\n"
5895 "B<#include E<lt>fcntl.hE<gt>>\n"
5896 msgstr ""
5897 "B<#include E<lt>sys/types.hE<gt>>\n"
5898 "B<#include E<lt>sys/stat.hE<gt>>\n"
5899 "B<#include E<lt>fcntl.hE<gt>>\n"
5900
5901 #. type: Plain text
5902 #: build/C/man2/open.2:63
5903 #, no-wrap
5904 msgid ""
5905 "B<int open(const char *>I<pathname>B<, int >I<flags>B<);>\n"
5906 "B<int open(const char *>I<pathname>B<, int >I<flags>B<, mode_t >I<mode>B<);>\n"
5907 msgstr ""
5908 "B<int open(const char *>I<pathname>B<, int >I<flags>B<);>\n"
5909 "B<int open(const char *>I<pathname>B<, int >I<flags>B<, mode_t >I<mode>B<);>\n"
5910
5911 #. type: Plain text
5912 #: build/C/man2/open.2:65
5913 #, no-wrap
5914 msgid "B<int creat(const char *>I<pathname>B<, mode_t >I<mode>B<);>\n"
5915 msgstr "B<int creat(const char *>I<pathname>B<, mode_t >I<mode>B<);>\n"
5916
5917 #. type: Plain text
5918 #: build/C/man2/open.2:76
5919 msgid ""
5920 "Given a I<pathname> for a file, B<open>()  returns a file descriptor, a "
5921 "small, nonnegative integer for use in subsequent system calls (B<read>(2), "
5922 "B<write>(2), B<lseek>(2), B<fcntl>(2), etc.).  The file descriptor returned "
5923 "by a successful call will be the lowest-numbered file descriptor not "
5924 "currently open for the process."
5925 msgstr ""
5926 "ファイルの I<pathname> を与えると、 B<open>()  はファイルディスクリプタを返"
5927 "す。 ファイルディスクリプタは、この後に続くシステムコール (B<read>(2), "
5928 "B<write>(2), B<lseek>(2), B<fcntl>(2) など)  で使用される小さな非負の整数であ"
5929 "る。 このシステムコールが成功した場合に返されるファイルディスクリプタは その"
5930 "プロセスがその時点でオープンしていないファイルディスクリプタの うち最小の数字"
5931 "のものとなる。"
5932
5933 #. type: Plain text
5934 #: build/C/man2/open.2:88
5935 msgid ""
5936 "By default, the new file descriptor is set to remain open across an B<execve>"
5937 "(2)  (i.e., the B<FD_CLOEXEC> file descriptor flag described in B<fcntl>(2)  "
5938 "is initially disabled; the B<O_CLOEXEC> flag, described below, can be used "
5939 "to change this default).  The file offset is set to the beginning of the "
5940 "file (see B<lseek>(2))."
5941 msgstr ""
5942 "デフォルトでは、新しいファイルディスクリプタは B<execve>(2) を実行した後も\n"
5943 "オープンされたままとなる (つまり、 B<fcntl>(2) に説明がある B<FD_CLOEXEC> \n"
5944 "ファイルディスクリプタフラグは最初は無効である; 後述の B<O_CLOEXEC> フラグ\n"
5945 "を使うとこのデフォルトを変更することができる)。 ファイルオフセット \n"
5946 "(file offset) はファイルの先頭に設定される (B<lseek>(2) 参照)。"
5947
5948 #. type: Plain text
5949 #: build/C/man2/open.2:107
5950 msgid ""
5951 "A call to B<open>()  creates a new I<open file description>, an entry in the "
5952 "system-wide table of open files.  This entry records the file offset and the "
5953 "file status flags (modifiable via the B<fcntl>(2)  B<F_SETFL> operation).  A "
5954 "file descriptor is a reference to one of these entries; this reference is "
5955 "unaffected if I<pathname> is subsequently removed or modified to refer to a "
5956 "different file.  The new open file description is initially not shared with "
5957 "any other process, but sharing may arise via B<fork>(2)."
5958 msgstr ""
5959 "B<open>()  を呼び出すと、「オープンファイル記述」 I<(open file description)> "
5960 "が作成される。ファイル記述とは、システム全体の オープン中のファイルのテーブル"
5961 "のエントリである。 このエントリは、ファイルオフセットとファイル状態フラグ "
5962 "(B<fcntl>(2)  B<F_SETFL> 操作により変更可能) が保持する。 ファイルディスクリ"
5963 "プタはこれらのエントリの一つへの参照である。 この後で I<pathname> が削除され"
5964 "たり、他のファイルを参照するように変更されたりしても、 この参照は影響を受けな"
5965 "い。 新しいオープンファイル記述は最初は他のどのプロセスとも 共有されていない"
5966 "が、 B<fork>(2)  で共有が起こる場合がある。"
5967
5968 #. type: Plain text
5969 #: build/C/man2/open.2:115
5970 msgid ""
5971 "The argument I<flags> must include one of the following I<access modes>: "
5972 "B<O_RDONLY>, B<O_WRONLY>, or B<O_RDWR>.  These request opening the file read-"
5973 "only, write-only, or read/write, respectively."
5974 msgstr ""
5975 "引き数 I<flags> には、アクセスモード B<O_RDONLY>, B<O_WRONLY>, B<O_RDWR> のど"
5976 "れかひとつが入っていなければならない。 これらはそれぞれ読み込み専用、書き込み"
5977 "専用、読み書き用に ファイルをオープンすることを要求するものである。"
5978
5979 #.  SUSv4 divides the flags into:
5980 #.  * Access mode
5981 #.  * File creation
5982 #.  * File status
5983 #.  * Other (O_CLOEXEC, O_DIRECTORY, O_NOFOLLOW)
5984 #.  though it's not clear what the difference between "other" and
5985 #.  "File creation" flags is.  I raised an Aardvark to see if this
5986 #.  can be clarified in SUSv4; 10 Oct 2008.
5987 #.  http://thread.gmane.org/gmane.comp.standards.posix.austin.general/64/focus=67
5988 #.  TC1 (balloted in 2013), resolved this, so that those three constants
5989 #.  are also categorized" as file status flags.
5990 #. type: Plain text
5991 #: build/C/man2/open.2:153
5992 msgid ""
5993 "In addition, zero or more file creation flags and file status flags can be "
5994 "bitwise-I<or>'d in I<flags>.  The I<file creation flags> are B<O_CLOEXEC>, "
5995 "B<O_CREAT>, B<O_DIRECTORY>, B<O_EXCL>, B<O_NOCTTY>, B<O_NOFOLLOW>, "
5996 "B<O_TRUNC>, and B<O_TTY_INIT>.  The I<file status flags> are all of the "
5997 "remaining flags listed below.  The distinction between these two groups of "
5998 "flags is that the file status flags can be retrieved and (in some cases)  "
5999 "modified using B<fcntl>(2).  The full list of file creation flags and file "
6000 "status flags is as follows:"
6001 msgstr ""
6002 "さらに、 I<flags> には、ファイル作成フラグ (file creation flag) とファイル状"
6003 "態フラグ (file status flag) を 0 個以上「ビット単位の OR (bitwise-or)」で 指"
6004 "定することができる。 I<ファイル作成フラグ> は B<O_CLOEXEC>, B<O_CREAT>, "
6005 "B<O_DIRECTORY>, B<O_EXCL>, B<O_NOCTTY>, B<O_NOFOLLOW>, B<O_TRUNC>, "
6006 "B<O_TTY_INIT> である。 I<ファイル状態フラグ> は以下のリストのうち上記以外の残"
6007 "りのものである。 二種類のフラグの違いは、ファイル状態フラグの方は B<fcntl>"
6008 "(2)  を使ってその内容を取得したり (場合によっては) 変更したりできる点にあ"
6009 "る。 ファイル作成フラグとファイル状態フラグの全リストを以下に示す:"
6010
6011 #. type: TP
6012 #: build/C/man2/open.2:153
6013 #, no-wrap
6014 msgid "B<O_APPEND>"
6015 msgstr "B<O_APPEND>"
6016
6017 #.  For more background, see
6018 #.  http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=453946
6019 #.  http://nfs.sourceforge.net/
6020 #. type: Plain text
6021 #: build/C/man2/open.2:170
6022 msgid ""
6023 "The file is opened in append mode.  Before each B<write>(2), the file offset "
6024 "is positioned at the end of the file, as if with B<lseek>(2).  B<O_APPEND> "
6025 "may lead to corrupted files on NFS file systems if more than one process "
6026 "appends data to a file at once.  This is because NFS does not support "
6027 "appending to a file, so the client kernel has to simulate it, which can't be "
6028 "done without a race condition."
6029 msgstr ""
6030 "ファイルを追加 (append) モードでオープンする。 毎回の B<write>(2)  の前に "
6031 "B<lseek>(2)  を行ったかのように、ファイルポインタをファイルの最後に移動す"
6032 "る。 NFS ファイルシステムで、 B<O_APPEND> を使用すると、複数のプロセスがひと"
6033 "つのファイルに同時にデータを追加した場合、 ファイルが壊れてしまうことがあ"
6034 "る。 これは NFS が追加モードをサポートしていないため、 クライアントのカーネ"
6035 "ル (kernel) がそれをシミュレートしなければならないのだが、 競合状態を避けるこ"
6036 "とはできないからである。"
6037
6038 #. type: TP
6039 #: build/C/man2/open.2:170
6040 #, no-wrap
6041 msgid "B<O_ASYNC>"
6042 msgstr "B<O_ASYNC>"
6043
6044 #. type: Plain text
6045 #: build/C/man2/open.2:183
6046 #, fuzzy
6047 #| msgid ""
6048 #| "Enable signal-driven I/O: generate a signal (B<SIGIO> by default, but "
6049 #| "this can be changed via B<fcntl>(2))  when input or output becomes "
6050 #| "possible on this file descriptor.  This feature is only available for "
6051 #| "terminals, pseudoterminals, sockets, and (since Linux 2.6) pipes and "
6052 #| "FIFOs.  See B<fcntl>(2)  for further details."
6053 msgid ""
6054 "Enable signal-driven I/O: generate a signal (B<SIGIO> by default, but this "
6055 "can be changed via B<fcntl>(2))  when input or output becomes possible on "
6056 "this file descriptor.  This feature is available only for terminals, "
6057 "pseudoterminals, sockets, and (since Linux 2.6) pipes and FIFOs.  See "
6058 "B<fcntl>(2)  for further details."
6059 msgstr ""
6060 "シグナル駆動 I/O (signal-driven I/O) を有効にする: このファイルディスクリプタ"
6061 "への 入力または出力が可能になった場合に、シグナルを生成する (デフォルトは "
6062 "B<SIGIO> であるが、 B<fcntl>(2)  によって変更可能である)。 この機能が使用可能"
6063 "なのは端末、疑似端末、ソケットのみであり、 (Linux 2.6 以降では) パイプと "
6064 "FIFO に対しても使用できる。 さらに詳しい説明は B<fcntl>(2)  を参照すること。"
6065
6066 #. type: TP
6067 #: build/C/man2/open.2:183
6068 #, no-wrap
6069 msgid "B<O_CLOEXEC> (Since Linux 2.6.23)"
6070 msgstr "B<O_CLOEXEC> (Linux 2.6.23 以降)"
6071
6072 #.  This flag fixes only one form of the race condition;
6073 #.  The race can also occur with, for example, descriptors
6074 #.  returned by accept(), pipe(), etc.
6075 #. type: Plain text
6076 #: build/C/man2/open.2:208
6077 msgid ""
6078 "Enable the close-on-exec flag for the new file descriptor.  Specifying this "
6079 "flag permits a program to avoid additional B<fcntl>(2)  B<F_SETFD> "
6080 "operations to set the B<FD_CLOEXEC> flag.  Additionally, use of this flag is "
6081 "essential in some multithreaded programs since using a separate B<fcntl>(2)  "
6082 "B<F_SETFD> operation to set the B<FD_CLOEXEC> flag does not suffice to avoid "
6083 "race conditions where one thread opens a file descriptor at the same time as "
6084 "another thread does a B<fork>(2)  plus B<execve>(2)."
6085 msgstr ""
6086 "新しいファイルディスクリプタに対して close-on-exec フラグを有効にする。 この"
6087 "フラグを指定することで、プログラムは B<FD_CLOEXEC> フラグをセットするための "
6088 "B<fcntl>(2)  B<F_SETFD> 操作を別途呼び出す必要がなくなる。 また、ある種のマル"
6089 "チスレッドのプログラムはこのフラグの使用は 不可欠である。なぜなら、個別に "
6090 "B<FD_CLOEXEC> フラグを設定する B<fcntl>(2)  B<F_SETFD> 操作を呼び出したとして"
6091 "も、あるスレッドがファイルディスクリプタを オープンするのと同時に別のスレッド"
6092 "が B<fork>(2)  と B<execve>(2)  を実行するという競合条件を避けるのには十分で"
6093 "はないからである。"
6094
6095 #. type: TP
6096 #: build/C/man2/open.2:208
6097 #, no-wrap
6098 msgid "B<O_CREAT>"
6099 msgstr "B<O_CREAT>"
6100
6101 #.  As at 2.6.25, bsdgroups is supported by ext2, ext3, ext4, and
6102 #.  XFS (since 2.6.14).
6103 #. type: Plain text
6104 #: build/C/man2/open.2:224
6105 msgid ""
6106 "If the file does not exist it will be created.  The owner (user ID) of the "
6107 "file is set to the effective user ID of the process.  The group ownership "
6108 "(group ID) is set either to the effective group ID of the process or to the "
6109 "group ID of the parent directory (depending on file system type and mount "
6110 "options, and the mode of the parent directory, see the mount options "
6111 "I<bsdgroups> and I<sysvgroups> described in B<mount>(8))."
6112 msgstr ""
6113 "ファイルが存在しなかった場合は作成 (create) する。 ファイルの所有者 (ユー"
6114 "ザー ID) は、プロセスの実効ユーザー ID に設定される。 グループ所有権 (グルー"
6115 "プ ID) は、プロセスの実効グループ ID または親ディレクトリのグループ ID に設定"
6116 "される (これは、ファイルシステムタイプ、マウントオプション、 親ディレクトリの"
6117 "モードに依存する。 B<mount>(8)  で説明されているマウントオプション "
6118 "I<bsdgroups> と I<sysvgroups> を参照)。"
6119
6120 #. type: Plain text
6121 #: build/C/man2/open.2:247
6122 #, fuzzy
6123 #| msgid ""
6124 #| "I<mode> specifies the permissions to use in case a new file is created.  "
6125 #| "This argument must be supplied when B<O_CREAT> is specified in I<flags>; "
6126 #| "if B<O_CREAT> is not specified, then I<mode> is ignored.  The effective "
6127 #| "permissions are modified by the process's I<umask> in the usual way: The "
6128 #| "permissions of the created file are I<(mode\\ &\\ ~umask)>.  Note that "
6129 #| "this mode only applies to future accesses of the newly created file; the "
6130 #| "B<open>()  call that creates a read-only file may well return a read/"
6131 #| "write file descriptor."
6132 msgid ""
6133 "I<mode> specifies the permissions to use in case a new file is created.  "
6134 "This argument must be supplied when B<O_CREAT> is specified in I<flags>; if "
6135 "B<O_CREAT> is not specified, then I<mode> is ignored.  The effective "
6136 "permissions are modified by the process's I<umask> in the usual way: The "
6137 "permissions of the created file are I<(mode\\ &\\ ~umask)>.  Note that this "
6138 "mode applies only to future accesses of the newly created file; the B<open>"
6139 "()  call that creates a read-only file may well return a read/write file "
6140 "descriptor."
6141 msgstr ""
6142 "I<mode> は新しいファイルを作成する場合に使用するアクセス許可 (permission) を"
6143 "指定する。 I<flags> に B<O_CREAT> が指定されている場合、 I<mode> を指定しなけ"
6144 "ればならない。 B<O_CREAT> が指定されていない場合、 I<mode> は無視される。 有"
6145 "効なアクセス許可は、普段と同じようにプロセスの I<umask> によって修正され、作"
6146 "成されたファイルの許可は I<(mode\\ &\\ ~umask)> となる。 このモードは、新しく"
6147 "作成されたファイルに対するそれ以降のアクセス にのみ適用される点に注意するこ"
6148 "と。 読み取り専用のファイルを作成する B<open>()  コールであっても、 読み書き"
6149 "可能なファイルディスクリプタを返すことがありうる。"
6150
6151 #. type: Plain text
6152 #: build/C/man2/open.2:250
6153 msgid "The following symbolic constants are provided for I<mode>:"
6154 msgstr "I<mode> のために以下のシンボル定数が提供されている :"
6155
6156 #. type: TP
6157 #: build/C/man2/open.2:250
6158 #, no-wrap
6159 msgid "B<S_IRWXU>"
6160 msgstr "B<S_IRWXU>"
6161
6162 #. type: Plain text
6163 #: build/C/man2/open.2:253
6164 msgid "00700 user (file owner) has read, write and execute permission"
6165 msgstr ""
6166 "00700 ユーザー (ファイルの所有者) に読み込み、書き込み、 実行の許可がある。"
6167
6168 #. type: TP
6169 #: build/C/man2/open.2:253
6170 #, no-wrap
6171 msgid "B<S_IRUSR>"
6172 msgstr "B<S_IRUSR>"
6173
6174 #. type: Plain text
6175 #: build/C/man2/open.2:256
6176 msgid "00400 user has read permission"
6177 msgstr "00400 ユーザーに読み込みの許可がある。"
6178
6179 #. type: TP
6180 #: build/C/man2/open.2:256
6181 #, no-wrap
6182 msgid "B<S_IWUSR>"
6183 msgstr "B<S_IWUSR>"
6184
6185 #. type: Plain text
6186 #: build/C/man2/open.2:259
6187 msgid "00200 user has write permission"
6188 msgstr "00200 ユーザーに書き込みの許可がある。"
6189
6190 #. type: TP
6191 #: build/C/man2/open.2:259
6192 #, no-wrap
6193 msgid "B<S_IXUSR>"
6194 msgstr "B<S_IXUSR>"
6195
6196 #. type: Plain text
6197 #: build/C/man2/open.2:262
6198 msgid "00100 user has execute permission"
6199 msgstr "00100 ユーザーに実行の許可がある。"
6200
6201 #. type: TP
6202 #: build/C/man2/open.2:262
6203 #, no-wrap
6204 msgid "B<S_IRWXG>"
6205 msgstr "B<S_IRWXG>"
6206
6207 #. type: Plain text
6208 #: build/C/man2/open.2:265
6209 msgid "00070 group has read, write and execute permission"
6210 msgstr "00070 グループに読み込み、書き込み、実行の許可がある。"
6211
6212 #. type: TP
6213 #: build/C/man2/open.2:265
6214 #, no-wrap
6215 msgid "B<S_IRGRP>"
6216 msgstr "B<S_IRGRP>"
6217
6218 #. type: Plain text
6219 #: build/C/man2/open.2:268
6220 msgid "00040 group has read permission"
6221 msgstr "00040 グループに読み込みの許可がある。"
6222
6223 #. type: TP
6224 #: build/C/man2/open.2:268
6225 #, no-wrap
6226 msgid "B<S_IWGRP>"
6227 msgstr "B<S_IWGRP>"
6228
6229 #. type: Plain text
6230 #: build/C/man2/open.2:271
6231 msgid "00020 group has write permission"
6232 msgstr "00020 グループに書き込みの許可がある。"
6233
6234 #. type: TP
6235 #: build/C/man2/open.2:271
6236 #, no-wrap
6237 msgid "B<S_IXGRP>"
6238 msgstr "B<S_IXGRP>"
6239
6240 #. type: Plain text
6241 #: build/C/man2/open.2:274
6242 msgid "00010 group has execute permission"
6243 msgstr "00010 グループに実行の許可がある。"
6244
6245 #. type: TP
6246 #: build/C/man2/open.2:274
6247 #, no-wrap
6248 msgid "B<S_IRWXO>"
6249 msgstr "B<S_IRWXO>"
6250
6251 #. type: Plain text
6252 #: build/C/man2/open.2:277
6253 msgid "00007 others have read, write and execute permission"
6254 msgstr "00007 他人 (others) に読み込み、書き込み、実行の許可がある。"
6255
6256 #. type: TP
6257 #: build/C/man2/open.2:277
6258 #, no-wrap
6259 msgid "B<S_IROTH>"
6260 msgstr "B<S_IROTH>"
6261
6262 #. type: Plain text
6263 #: build/C/man2/open.2:280
6264 msgid "00004 others have read permission"
6265 msgstr "00004 他人に読み込みの許可がある。"
6266
6267 #. type: TP
6268 #: build/C/man2/open.2:280
6269 #, no-wrap
6270 msgid "B<S_IWOTH>"
6271 msgstr "B<S_IWOTH>"
6272
6273 #. type: Plain text
6274 #: build/C/man2/open.2:283
6275 msgid "00002 others have write permission"
6276 msgstr "00002 他人に書き込みの許可がある。"
6277
6278 #. type: TP
6279 #: build/C/man2/open.2:283
6280 #, no-wrap
6281 msgid "B<S_IXOTH>"
6282 msgstr "B<S_IXOTH>"
6283
6284 #. type: Plain text
6285 #: build/C/man2/open.2:286
6286 msgid "00001 others have execute permission"
6287 msgstr "00001 他人に実行の許可がある。"
6288
6289 #. type: TP
6290 #: build/C/man2/open.2:287
6291 #, no-wrap
6292 msgid "B<O_DIRECT> (Since Linux 2.4.10)"
6293 msgstr "B<O_DIRECT> (Linux 2.4.10 以降)"
6294
6295 #. type: Plain text
6296 #: build/C/man2/open.2:304
6297 msgid ""
6298 "Try to minimize cache effects of the I/O to and from this file.  In general "
6299 "this will degrade performance, but it is useful in special situations, such "
6300 "as when applications do their own caching.  File I/O is done directly to/"
6301 "from user-space buffers.  The B<O_DIRECT> flag on its own makes an effort to "
6302 "transfer data synchronously, but does not give the guarantees of the "
6303 "B<O_SYNC> flag that data and necessary metadata are transferred.  To "
6304 "guarantee synchronous I/O, B<O_SYNC> must be used in addition to "
6305 "B<O_DIRECT>.  See NOTES below for further discussion."
6306 msgstr ""
6307 "このファイルに対する I/O のキャッシュの効果を最小化しようとする。このフラグを"
6308 "使うと、一般的に性能が低下する。 しかしアプリケーションが独自にキャッシングを"
6309 "行っているような 特別な場合には役に立つ。 ファイルの I/O はユーザー空間バッ"
6310 "ファに対して直接行われる。 B<O_DIRECT> フラグ自身はデータを同期で転送しようと"
6311 "はするが、 B<O_SYNC> フラグのようにデータと必要なメタデータの転送が保証される"
6312 "わけではない。同期 I/O を保証するためには、 B<O_DIRECT> に加えて B<O_SYNC> を"
6313 "使用しなければならない。下記の「注意」の節の議論も参照。"
6314
6315 #. type: Plain text
6316 #: build/C/man2/open.2:308
6317 msgid ""
6318 "A semantically similar (but deprecated) interface for block devices is "
6319 "described in B<raw>(8)."
6320 msgstr ""
6321 "ブロックデバイスに対する似通った意味のインターフェースが B<raw>(8)  で説明さ"
6322 "れている (但し、このインタフェースは非推奨である)。"
6323
6324 #. type: TP
6325 #: build/C/man2/open.2:308
6326 #, no-wrap
6327 msgid "B<O_DIRECTORY>"
6328 msgstr "B<O_DIRECTORY>"
6329
6330 #.  But see the following and its replies:
6331 #.  http://marc.theaimsgroup.com/?t=112748702800001&r=1&w=2
6332 #.  [PATCH] open: O_DIRECTORY and O_CREAT together should fail
6333 #.  O_DIRECTORY | O_CREAT causes O_DIRECTORY to be ignored.
6334 #. type: Plain text
6335 #: build/C/man2/open.2:322
6336 msgid ""
6337 "If I<pathname> is not a directory, cause the open to fail.  This flag is "
6338 "Linux-specific, and was added in kernel version 2.1.126, to avoid denial-of-"
6339 "service problems if B<opendir>(3)  is called on a FIFO or tape device, but "
6340 "should not be used outside of the implementation of B<opendir>(3)."
6341 msgstr ""
6342 "I<pathname> がディレクトリでなければオープンは失敗する。 このフラグは Linux "
6343 "特有であり、 B<opendir>(3)  が FIFO やテープデバイスに対してコールされた場合"
6344 "の サービス不能 (denial-of-service) 攻撃を避けるために カーネル 2.1.126 で追"
6345 "加された。 しかしこれは B<opendir>(3)  の実装以外では使用するべきではない。"
6346
6347 #. type: TP
6348 #: build/C/man2/open.2:322
6349 #, no-wrap
6350 msgid "B<O_EXCL>"
6351 msgstr "B<O_EXCL>"
6352
6353 #. type: Plain text
6354 #: build/C/man2/open.2:332
6355 msgid ""
6356 "Ensure that this call creates the file: if this flag is specified in "
6357 "conjunction with B<O_CREAT>, and I<pathname> already exists, then B<open>()  "
6358 "will fail."
6359 msgstr ""
6360 "この呼び出しでファイルが作成されることを保証する。このフラグが B<O_CREAT> "
6361 "と\n"
6362 "一緒に指定され、 I<pathname> のファイルが既に存在した場合、 B<open>() は失"
6363 "敗\n"
6364 "する。"
6365
6366 #.  POSIX.1-2001 explicitly requires this behavior.
6367 #. type: Plain text
6368 #: build/C/man2/open.2:340
6369 msgid ""
6370 "When these two flags are specified, symbolic links are not followed: if "
6371 "I<pathname> is a symbolic link, then B<open>()  fails regardless of where "
6372 "the symbolic link points to."
6373 msgstr ""
6374 "これら二つのフラグが指定された際、シンボリックリンクは辿られない。 "
6375 "I<pathname> がシンボリックリンクの場合、 シンボリックリンクがどこを指している"
6376 "かに関わらず B<open>()  は失敗する。"
6377
6378 #. type: Plain text
6379 #: build/C/man2/open.2:356
6380 msgid ""
6381 "In general, the behavior of B<O_EXCL> is undefined if it is used without "
6382 "B<O_CREAT>.  There is one exception: on Linux 2.6 and later, B<O_EXCL> can "
6383 "be used without B<O_CREAT> if I<pathname> refers to a block device.  If the "
6384 "block device is in use by the system (e.g., mounted), B<open>()  fails with "
6385 "the error B<EBUSY>."
6386 msgstr ""
6387 "一般的には、 B<O_CREAT> を指定せずに B<O_EXCL> を使用した場合の\n"
6388 "B<O_EXCL> の動作は規定されていない。\n"
6389 "これには一つ例外があり、Linux 2.6 以降では、\n"
6390 "I<pathname> がブロックデバイスを参照している場合、\n"
6391 "B<O_CREAT> なしで B<O_EXCL> を使用することができる。\n"
6392 "システムがそのブロックデバイスを使用中の場合 (例えば、\n"
6393 "マウントされているなど)、 B<open>() はエラー B<EBUSY> で失敗する。"
6394
6395 #. type: Plain text
6396 #: build/C/man2/open.2:378
6397 #, fuzzy
6398 #| msgid ""
6399 #| "On NFS, B<O_EXCL> is only supported when using NFSv3 or later on kernel "
6400 #| "2.6 or later.  In NFS environments where B<O_EXCL> support is not "
6401 #| "provided, programs that rely on it for performing locking tasks will "
6402 #| "contain a race condition.  Portable programs that want to perform atomic "
6403 #| "file locking using a lockfile, and need to avoid reliance on NFS support "
6404 #| "for B<O_EXCL>, can create a unique file on the same file system (e.g., "
6405 #| "incorporating hostname and PID), and use B<link>(2)  to make a link to "
6406 #| "the lockfile.  If B<link>(2)  returns 0, the lock is successful.  "
6407 #| "Otherwise, use B<stat>(2)  on the unique file to check if its link count "
6408 #| "has increased to 2, in which case the lock is also successful."
6409 msgid ""
6410 "On NFS, B<O_EXCL> is supported only when using NFSv3 or later on kernel 2.6 "
6411 "or later.  In NFS environments where B<O_EXCL> support is not provided, "
6412 "programs that rely on it for performing locking tasks will contain a race "
6413 "condition.  Portable programs that want to perform atomic file locking using "
6414 "a lockfile, and need to avoid reliance on NFS support for B<O_EXCL>, can "
6415 "create a unique file on the same file system (e.g., incorporating hostname "
6416 "and PID), and use B<link>(2)  to make a link to the lockfile.  If B<link>"
6417 "(2)  returns 0, the lock is successful.  Otherwise, use B<stat>(2)  on the "
6418 "unique file to check if its link count has increased to 2, in which case the "
6419 "lock is also successful."
6420 msgstr ""
6421 "NFS では、 B<O_EXCL> は、Linux 2.6 以降で NFSv3 以降を使っている場合でのみサ"
6422 "ポートされる。 B<O_EXCL> サポートが提供されていない NFS 環境では、このフラグ"
6423 "に頼って ロック処理を実行するプログラムは競合状態 (race condition) に出会う "
6424 "可能性がある。 ロックファイルを使用して不可分 (atomic) なファイルロックを実現"
6425 "し、 NFS が B<O_EXCL> をサポートしているかに依存しないようにしたい場合、 移植"
6426 "性のある方法は、同じファイルシステム上に他と名前の重ならない ファイル (例えば"
6427 "ホスト名と PID を組み合わせた名前) を作成し、 B<link>(2)  を使用してそのロッ"
6428 "クファイルへのリンクを作成することである。 B<link>(2)  コールの返り値が 0 な"
6429 "らばロックに成功している。 あるいは、そのファイルに B<stat>(2)  を使用してリ"
6430 "ンク数 (link count) が 2 になっているかをチェックする。 そうなっていれば、同"
6431 "じくロックに成功しているということである。"
6432
6433 #. type: TP
6434 #: build/C/man2/open.2:378
6435 #, no-wrap
6436 msgid "B<O_LARGEFILE>"
6437 msgstr "B<O_LARGEFILE>"
6438
6439 #. type: Plain text
6440 #: build/C/man2/open.2:400
6441 msgid ""
6442 "(LFS)  Allow files whose sizes cannot be represented in an I<off_t> (but can "
6443 "be represented in an I<off64_t>)  to be opened.  The B<_LARGEFILE64_SOURCE> "
6444 "macro must be defined (before including I<any> header files)  in order to "
6445 "obtain this definition.  Setting the B<_FILE_OFFSET_BITS> feature test macro "
6446 "to 64 (rather than using B<O_LARGEFILE>)  is the preferred method of "
6447 "accessing large files on 32-bit systems (see B<feature_test_macros>(7))."
6448 msgstr ""
6449 "(LFS) I<off_t> ではサイズを表せない (だだし I<off64_t> ではサイズを表せる)"
6450 "ファ\n"
6451 "イルをオープン可能にする。この定義を有効にするためには、(I<どの>ヘッダファ"
6452 "イ\n"
6453 "ルをインクルードするよりも前に) B<_LARGEFILE64_SOURCE> マクロを定義しなけれ"
6454 "ば\n"
6455 "ならない。\n"
6456 "32 ビットシステムにおいて大きなファイルにアクセスしたい場合、\n"
6457 "(B<O_LARGEFILE> を使うよりも) B<_FILE_OFFSET_BITS> 機能検査マクロを 64 に\n"
6458 "セットする方が望ましい方法である (B<feature_test_macros>(7) を参照)。"
6459
6460 #. type: TP
6461 #: build/C/man2/open.2:400
6462 #, no-wrap
6463 msgid "B<O_NOATIME> (Since Linux 2.6.8)"
6464 msgstr "B<O_NOATIME> (Linux 2.6.8 以降)"
6465
6466 #.  The O_NOATIME flag also affects the treatment of st_atime
6467 #.  by mmap() and readdir(2), MTK, Dec 04.
6468 #. type: Plain text
6469 #: build/C/man2/open.2:413
6470 msgid ""
6471 "Do not update the file last access time (I<st_atime> in the inode)  when the "
6472 "file is B<read>(2).  This flag is intended for use by indexing or backup "
6473 "programs, where its use can significantly reduce the amount of disk "
6474 "activity.  This flag may not be effective on all file systems.  One example "
6475 "is NFS, where the server maintains the access time."
6476 msgstr ""
6477 "ファイルに対して B<read>(2)  が実行されたときに、最終アクセス時刻 (inode の "
6478 "I<st_atime>) を更新しない。 このフラグはインデックス作成やバックアッププログ"
6479 "ラムで使うことを意図している。 これを使うとディスクに対する操作を大幅に減らす"
6480 "ことができる。 このフラグは全てのファイルシステムに対して有効であるわけではな"
6481 "い。 その一例が NFS であり、サーバがアクセス時刻を管理している。"
6482
6483 #. type: TP
6484 #: build/C/man2/open.2:413
6485 #, no-wrap
6486 msgid "B<O_NOCTTY>"
6487 msgstr "B<O_NOCTTY>"
6488
6489 #. type: Plain text
6490 #: build/C/man2/open.2:421
6491 msgid ""
6492 "If I<pathname> refers to a terminal device\\(emsee B<tty>(4)\\(emit will not "
6493 "become the process's controlling terminal even if the process does not have "
6494 "one."
6495 msgstr ""
6496 "I<pathname> が端末 (terminal) デバイス \\(em B<tty>(4) 参照 \\(em を指してい"
6497 "る\n"
6498 "場合に、たとえそのプロセスが制御端末を持っていなくても、オープンしたファイ"
6499 "ル\n"
6500 "は制御端末にはならない。"
6501
6502 #. type: TP
6503 #: build/C/man2/open.2:421
6504 #, no-wrap
6505 msgid "B<O_NOFOLLOW>"
6506 msgstr "B<O_NOFOLLOW>"
6507
6508 #.  The headers from glibc 2.0.100 and later include a
6509 #.  definition of this flag; \fIkernels before 2.1.126 will ignore it if
6510 #.  used\fP.
6511 #. type: Plain text
6512 #: build/C/man2/open.2:430
6513 msgid ""
6514 "If I<pathname> is a symbolic link, then the open fails.  This is a FreeBSD "
6515 "extension, which was added to Linux in version 2.1.126.  Symbolic links in "
6516 "earlier components of the pathname will still be followed."
6517 msgstr ""
6518 "I<pathname> がシンボリックリンクだった場合、オープンは失敗する。 これは "
6519 "FreeBSD の拡張で、Linux には 2.1.126 より追加された。 pathname の前のコンポー"
6520 "ネント (earlier component; 訳註: 最後のディレクトリセパレータより前の部分) "
6521 "が シンボリックリンクである場合には、それが指す先が参照される。"
6522
6523 #. type: TP
6524 #: build/C/man2/open.2:430
6525 #, no-wrap
6526 msgid "B<O_NONBLOCK> or B<O_NDELAY>"
6527 msgstr "B<O_NONBLOCK> または B<O_NDELAY>"
6528
6529 #. type: Plain text
6530 #: build/C/man2/open.2:443
6531 msgid ""
6532 "When possible, the file is opened in nonblocking mode.  Neither the B<open>"
6533 "()  nor any subsequent operations on the file descriptor which is returned "
6534 "will cause the calling process to wait.  For the handling of FIFOs (named "
6535 "pipes), see also B<fifo>(7).  For a discussion of the effect of "
6536 "B<O_NONBLOCK> in conjunction with mandatory file locks and with file leases, "
6537 "see B<fcntl>(2)."
6538 msgstr ""
6539 "可能ならば、ファイルは非停止 (nonblocking) モードでオープンされる。\n"
6540 "B<open>() も、返したファイルディスクリプタに対する以後のすべての操作も呼び"
6541 "出\n"
6542 "したプロセスを待たせることはない。 FIFO (名前付きパイプ) を扱う場合には\n"
6543 "B<fifo>(7) も参照すること。 強制ファイルロック (mandatory file lock) やファ"
6544 "イ\n"
6545 "ルリース (file lease) と組み合わせた場合の、 B<O_NONBLOCK> の効果についての\n"
6546 "議論は、 B<fcntl>(2) を参照すること。"
6547
6548 #. type: TP
6549 #: build/C/man2/open.2:443
6550 #, no-wrap
6551 msgid "B<O_SYNC>"
6552 msgstr "B<O_SYNC>"
6553
6554 #. type: Plain text
6555 #: build/C/man2/open.2:451
6556 msgid ""
6557 "The file is opened for synchronous I/O.  Any B<write>(2)s on the resulting "
6558 "file descriptor will block the calling process until the data has been "
6559 "physically written to the underlying hardware.  I<But see NOTES below>."
6560 msgstr ""
6561 "ファイルは同期 (synchronous) I/O モードでオープンされる。 B<open>()  が返した"
6562 "ファイルディスクリプタに対して B<write>(2)  を行うと、必ず呼び出したプロセス"
6563 "をブロックし、 該当ハードウェアに物理的に書き込まれるまで返らない。 I<以下の"
6564 "「注意」の章も参照。>"
6565
6566 #. type: TP
6567 #: build/C/man2/open.2:451
6568 #, no-wrap
6569 msgid "B<O_TRUNC>"
6570 msgstr "B<O_TRUNC>"
6571
6572 #. type: Plain text
6573 #: build/C/man2/open.2:465
6574 msgid ""
6575 "If the file already exists and is a regular file and the open mode allows "
6576 "writing (i.e., is B<O_RDWR> or B<O_WRONLY>)  it will be truncated to length "
6577 "0.  If the file is a FIFO or terminal device file, the B<O_TRUNC> flag is "
6578 "ignored.  Otherwise the effect of B<O_TRUNC> is unspecified."
6579 msgstr ""
6580 "ファイルが既に存在し、通常ファイルであり、 書き込み可モードでオープンされてい"
6581 "る (つまり、 B<O_RDWR>またはB<O_WRONLY> の) 場合、長さ 0 に切り詰め "
6582 "(truncate) られる。 ファイルが FIFO または端末デバイスファイルの場合、 "
6583 "B<O_TRUNC> フラグは無視される。 それ以外の場合、 B<O_TRUNC> の効果は未定義で"
6584 "ある。"
6585
6586 #. type: Plain text
6587 #: build/C/man2/open.2:469
6588 msgid ""
6589 "Some of these optional flags can be altered using B<fcntl>(2)  after the "
6590 "file has been opened."
6591 msgstr ""
6592 "これらの選択フラグのいくつかはファイルをオープンした後でも B<fcntl>(2)  を使"
6593 "用して変更することができる。"
6594
6595 #. type: Plain text
6596 #: build/C/man2/open.2:477
6597 msgid ""
6598 "B<creat>()  is equivalent to B<open>()  with I<flags> equal to B<O_CREAT|"
6599 "O_WRONLY|O_TRUNC>."
6600 msgstr ""
6601 "B<creat>()  は I<flags> に B<O_CREAT|O_WRONLY|O_TRUNC> を指定して B<open>()  "
6602 "を行うのと等価である。"
6603
6604 #. type: Plain text
6605 #: build/C/man2/open.2:485
6606 msgid ""
6607 "B<open>()  and B<creat>()  return the new file descriptor, or -1 if an error "
6608 "occurred (in which case, I<errno> is set appropriately)."
6609 msgstr ""
6610 "B<open>()  と B<creat>()  は新しいファイルディスクリプタを返す。 エラーが発生"
6611 "した場合は -1 を返す (その場合は I<errno> が適切に設定される)。"
6612
6613 #. type: Plain text
6614 #: build/C/man2/open.2:495
6615 msgid ""
6616 "The requested access to the file is not allowed, or search permission is "
6617 "denied for one of the directories in the path prefix of I<pathname>, or the "
6618 "file did not exist yet and write access to the parent directory is not "
6619 "allowed.  (See also B<path_resolution>(7).)"
6620 msgstr ""
6621 "ファイルに対する要求されたアクセスが許されていないか、 I<pathname> のディレク"
6622 "トリ部分の何れかのディレクトリに検索許可がなかった。 またはファイルが存在せ"
6623 "ず、親ディレクトリへの書き込み許可がなかった。 (B<path_resolution>(7)  も参照"
6624 "すること。)"
6625
6626 #. type: Plain text
6627 #: build/C/man2/open.2:501
6628 msgid ""
6629 "Where B<O_CREAT> is specified, the file does not exist, and the user's quota "
6630 "of disk blocks or inodes on the file system has been exhausted."
6631 msgstr ""
6632
6633 #. type: Plain text
6634 #: build/C/man2/open.2:507
6635 msgid "I<pathname> already exists and B<O_CREAT> and B<O_EXCL> were used."
6636 msgstr "I<pathname> は既に存在し、 B<O_CREAT> と B<O_EXCL> が使用された。"
6637
6638 #. type: Plain text
6639 #: build/C/man2/open.2:511 build/C/man2/rmdir.2:67 build/C/man2/unlink.2:84
6640 msgid "I<pathname> points outside your accessible address space."
6641 msgstr "I<pathname> がアクセス可能なアドレス空間の外を指している。"
6642
6643 #. type: TP
6644 #: build/C/man2/open.2:511 build/C/man2/write.2:145
6645 #, no-wrap
6646 msgid "B<EFBIG>"
6647 msgstr "B<EFBIG>"
6648
6649 #. type: Plain text
6650 #: build/C/man2/open.2:515
6651 msgid "See B<EOVERFLOW>."
6652 msgstr "B<EOVERFLOW> 参照。"
6653
6654 #. type: TP
6655 #: build/C/man2/open.2:515 build/C/man2/read.2:122 build/C/man3/scanf.3:562
6656 #: build/C/man3/tmpfile.3:61 build/C/man2/write.2:150
6657 #, no-wrap
6658 msgid "B<EINTR>"
6659 msgstr "B<EINTR>"
6660
6661 #. type: Plain text
6662 #: build/C/man2/open.2:522
6663 msgid ""
6664 "While blocked waiting to complete an open of a slow device (e.g., a FIFO; "
6665 "see B<fifo>(7)), the call was interrupted by a signal handler; see B<signal>"
6666 "(7)."
6667 msgstr ""
6668 "遅いデバイス (例えば FIFO、 B<fifo>(7)  参照) のオープンが完了するのを待って"
6669 "停止している間に システムコールがシグナルハンドラにより割り込まれた。 "
6670 "B<signal>(7)  参照。"
6671
6672 #. type: TP
6673 #: build/C/man2/open.2:522 build/C/man2/read.2:158 build/C/man2/rename.2:143
6674 #: build/C/man2/unlink.2:87
6675 #, no-wrap
6676 msgid "B<EISDIR>"
6677 msgstr "B<EISDIR>"
6678
6679 #. type: Plain text
6680 #: build/C/man2/open.2:531
6681 msgid ""
6682 "I<pathname> refers to a directory and the access requested involved writing "
6683 "(that is, B<O_WRONLY> or B<O_RDWR> is set)."
6684 msgstr ""
6685 "I<pathname> はディレクトリを参照しており、書き込み要求が含まれていた (つまり "
6686 "B<O_WRONLY> または B<O_RDWR> が設定されている)。"
6687
6688 #. type: Plain text
6689 #: build/C/man2/open.2:538
6690 msgid ""
6691 "Too many symbolic links were encountered in resolving I<pathname>, or "
6692 "B<O_NOFOLLOW> was specified but I<pathname> was a symbolic link."
6693 msgstr ""
6694 "I<pathname> を解決する際に遭遇したシンボリックリンクが多過ぎる。 または "
6695 "B<O_NOFOLLOW> が指定されており、 I<pathname> がシンボリックリンクだった。"
6696
6697 #. type: TP
6698 #: build/C/man2/open.2:538 build/C/man2/pipe.2:107 build/C/man3/tmpfile.3:64
6699 #, no-wrap
6700 msgid "B<EMFILE>"
6701 msgstr "B<EMFILE>"
6702
6703 #. type: Plain text
6704 #: build/C/man2/open.2:541
6705 msgid "The process already has the maximum number of files open."
6706 msgstr "プロセスがオープンしているファイル数がすでに最大数に達している。"
6707
6708 #. type: Plain text
6709 #: build/C/man2/open.2:545 build/C/man2/rmdir.2:80 build/C/man2/unlink.2:99
6710 msgid "I<pathname> was too long."
6711 msgstr "I<pathname> が長過ぎる。"
6712
6713 #. type: TP
6714 #: build/C/man2/open.2:545 build/C/man2/pipe.2:110 build/C/man3/tmpfile.3:67
6715 #, no-wrap
6716 msgid "B<ENFILE>"
6717 msgstr "B<ENFILE>"
6718
6719 #. type: Plain text
6720 #: build/C/man2/open.2:548 build/C/man2/pipe.2:113
6721 msgid "The system limit on the total number of open files has been reached."
6722 msgstr "オープンされているファイルの総数がシステムの制限に達している。"
6723
6724 #. type: TP
6725 #: build/C/man2/open.2:548
6726 #, no-wrap
6727 msgid "B<ENODEV>"
6728 msgstr "B<ENODEV>"
6729
6730 #. type: Plain text
6731 #: build/C/man2/open.2:555
6732 msgid ""
6733 "I<pathname> refers to a device special file and no corresponding device "
6734 "exists.  (This is a Linux kernel bug; in this situation B<ENXIO> must be "
6735 "returned.)"
6736 msgstr ""
6737 "I<pathname> がデバイススペシャルファイルを参照しており、対応するデバイスが存"
6738 "在しない。 (これは Linux カーネルのバグであり、この場合には B<ENXIO> が返され"
6739 "るべきである)"
6740
6741 #. type: Plain text
6742 #: build/C/man2/open.2:562
6743 msgid ""
6744 "B<O_CREAT> is not set and the named file does not exist.  Or, a directory "
6745 "component in I<pathname> does not exist or is a dangling symbolic link."
6746 msgstr ""
6747 "B<O_CREAT> が設定されておらず、かつ指定されたファイルが存在しない。 または、 "
6748 "I<pathname> のディレクトリ部分が存在しないか壊れた (dangling) シンボリックリ"
6749 "ンクである。"
6750
6751 #. type: Plain text
6752 #: build/C/man2/open.2:571
6753 msgid ""
6754 "I<pathname> was to be created but the device containing I<pathname> has no "
6755 "room for the new file."
6756 msgstr ""
6757 "I<pathname> を作成する必要があるが、 I<pathname> を含んでいるデバイスに新しい"
6758 "ファイルのための空き容量がない。"
6759
6760 #. type: Plain text
6761 #: build/C/man2/open.2:578
6762 msgid ""
6763 "A component used as a directory in I<pathname> is not, in fact, a directory, "
6764 "or B<O_DIRECTORY> was specified and I<pathname> was not a directory."
6765 msgstr ""
6766 "I<pathname> に含まれるディレクトリ部分のどれかが実際にはディレクトリでない。 "
6767 "または B<O_DIRECTORY> が指定されており、 I<pathname> がディレクトリでない。"
6768
6769 #. type: Plain text
6770 #: build/C/man2/open.2:584
6771 msgid ""
6772 "B<O_NONBLOCK> | B<O_WRONLY> is set, the named file is a FIFO and no process "
6773 "has the file open for reading.  Or, the file is a device special file and no "
6774 "corresponding device exists."
6775 msgstr ""
6776 "B<O_NONBLOCK> | B<O_WRONLY> が設定されており、指定したファイルが FIFO で その"
6777 "ファイルを読み込みのためにオープンしているプロセスが存在しない。 または、ファ"
6778 "イルがデバイススペシャルファイルで 対応するデバイスが存在しない。"
6779
6780 #.  See http://bugzilla.kernel.org/show_bug.cgi?id=7253
6781 #.  "Open of a large file on 32-bit fails with EFBIG, should be EOVERFLOW"
6782 #.  Reported 2006-10-03
6783 #. type: Plain text
6784 #: build/C/man2/open.2:604
6785 msgid ""
6786 "I<pathname> refers to a regular file that is too large to be opened.  The "
6787 "usual scenario here is that an application compiled on a 32-bit platform "
6788 "without I<-D_FILE_OFFSET_BITS=64> tried to open a file whose size exceeds I<"
6789 "(2E<lt>E<lt>31)-1> bits; see also B<O_LARGEFILE> above.  This is the error "
6790 "specified by POSIX.1-2001; in kernels before 2.6.24, Linux gave the error "
6791 "B<EFBIG> for this case."
6792 msgstr ""
6793 "I<pathname> が参照しているのが、大き過ぎてオープンできない通常のファイルであ"
6794 "る。 通常、このエラーが発生するは、32 ビットプラットフォーム上で I<-"
6795 "D_FILE_OFFSET_BITS=64> を指定せずにコンパイルされたアプリケーションが、ファイ"
6796 "ルサイズが I<(2E<lt>31)-1> ビットを超えるファイルを開こうとした場合である。 "
6797 "上記の B<O_LARGEFILE> も参照。 これは POSIX.1-2001 で規定されているエラーであ"
6798 "る。 2.6.24 より前のカーネルでは、Linux はこの場合にエラー B<EFBIG> を返して"
6799 "いた。"
6800
6801 #.  Strictly speaking, it's the file system UID... (MTK)
6802 #. type: Plain text
6803 #: build/C/man2/open.2:612
6804 msgid ""
6805 "The B<O_NOATIME> flag was specified, but the effective user ID of the caller "
6806 "did not match the owner of the file and the caller was not privileged "
6807 "(B<CAP_FOWNER>)."
6808 msgstr ""
6809 "B<O_NOATIME> フラグが指定されたが、呼び出し元の実効ユーザー ID が ファイルの"
6810 "所有者と一致せず、かつ呼び出し元に特権 (B<CAP_FOWNER>)  がない。"
6811
6812 #. type: Plain text
6813 #: build/C/man2/open.2:617
6814 msgid ""
6815 "I<pathname> refers to a file on a read-only file system and write access was "
6816 "requested."
6817 msgstr ""
6818 "I<pathname> が読み込み専用のファイルシステム上のファイルを参照しており、 書き"
6819 "込みアクセスが要求された。"
6820
6821 #. type: TP
6822 #: build/C/man2/open.2:617
6823 #, no-wrap
6824 msgid "B<ETXTBSY>"
6825 msgstr "B<ETXTBSY>"
6826
6827 #. type: Plain text
6828 #: build/C/man2/open.2:622
6829 msgid ""
6830 "I<pathname> refers to an executable image which is currently being executed "
6831 "and write access was requested."
6832 msgstr ""
6833 "I<pathname> が現在実行中の実行イメージを参照しており、書き込みが要求された。"
6834
6835 #. type: TP
6836 #: build/C/man2/open.2:622
6837 #, no-wrap
6838 msgid "B<EWOULDBLOCK>"
6839 msgstr "B<EWOULDBLOCK>"
6840
6841 #. type: Plain text
6842 #: build/C/man2/open.2:629
6843 msgid ""
6844 "The B<O_NONBLOCK> flag was specified, and an incompatible lease was held on "
6845 "the file (see B<fcntl>(2))."
6846 msgstr ""
6847 "B<O_NONBLOCK> フラグが指定されたが、そのファイルには矛盾するリースが設定され"
6848 "ていた (B<fcntl>(2)  参照)。"
6849
6850 #. type: Plain text
6851 #: build/C/man2/open.2:642
6852 msgid ""
6853 "SVr4, 4.3BSD, POSIX.1-2001.  The B<O_DIRECTORY>, B<O_NOATIME>, and "
6854 "B<O_NOFOLLOW> flags are Linux-specific, and one may need to define "
6855 "B<_GNU_SOURCE> (before including I<any> header files)  to obtain their "
6856 "definitions."
6857 msgstr ""
6858 "SVr4, 4.3BSD, POSIX.1-2001.  フラグ B<O_DIRECTORY>, B<O_NOATIME>, "
6859 "B<O_NOFOLLOW> は Linux 特有のものであり、 これらのフラグの定義を得るために"
6860 "は、 (「どの」ヘッダファイルをインクルードするよりも前に)  B<_GNU_SOURCE> を"
6861 "定義する必要があるかもしれない。"
6862
6863 #. type: Plain text
6864 #: build/C/man2/open.2:647
6865 msgid ""
6866 "The B<O_CLOEXEC> flag is not specified in POSIX.1-2001, but is specified in "
6867 "POSIX.1-2008."
6868 msgstr ""
6869 "B<O_CLOEXEC> フラグは POSIX.1-2001 では規定されていないが、 POSIX.1-2008 で規"
6870 "定されている。"
6871
6872 #. type: Plain text
6873 #: build/C/man2/open.2:655
6874 msgid ""
6875 "B<O_DIRECT> is not specified in POSIX; one has to define B<_GNU_SOURCE> "
6876 "(before including I<any> header files)  to get its definition."
6877 msgstr ""
6878 "B<O_DIRECT> は POSIX では規定されていない。 B<O_DIRECT> の定義を得るには "
6879 "(「どの」ヘッダファイルをインクルードするよりも前に)  B<_GNU_SOURCE> を定義し"
6880 "なければならない。"
6881
6882 #. type: Plain text
6883 #: build/C/man2/open.2:663
6884 msgid ""
6885 "Under Linux, the B<O_NONBLOCK> flag indicates that one wants to open but "
6886 "does not necessarily have the intention to read or write.  This is typically "
6887 "used to open devices in order to get a file descriptor for use with B<ioctl>"
6888 "(2)."
6889 msgstr ""
6890 "Linux では、 B<O_NONBLOCK> フラグは、 open を実行したいが read または write "
6891 "を実行する意図は 必ずしもないことを意味する。 これは B<ioctl>(2)  のための"
6892 "ファイルディスクリプタを取得するために、 デバイスをオープンするときによく用い"
6893 "られる。"
6894
6895 #.  See for example util-linux's disk-utils/setfdprm.c
6896 #.  For some background on access mode 3, see
6897 #.  http://thread.gmane.org/gmane.linux.kernel/653123
6898 #.  "[RFC] correct flags to f_mode conversion in __dentry_open"
6899 #.  LKML, 12 Mar 2008
6900 #. type: Plain text
6901 #: build/C/man2/open.2:692
6902 #, fuzzy
6903 #| msgid ""
6904 #| "Unlike the other values that can be specified in I<flags>, the I<access "
6905 #| "mode> values B<O_RDONLY>, B<O_WRONLY>, and B<O_RDWR>, do not specify "
6906 #| "individual bits.  Rather, they define the low order two bits of I<flags>, "
6907 #| "and are defined respectively as 0, 1, and 2.  In other words, the "
6908 #| "combination B<O_RDONLY | O_WRONLY> is a logical error, and certainly does "
6909 #| "not have the same meaning as B<O_RDWR>.  Linux reserves the special, "
6910 #| "nonstandard access mode 3 (binary 11) in I<flags> to mean: check for read "
6911 #| "and write permission on the file and return a descriptor that can't be "
6912 #| "used for reading or writing.  This nonstandard access mode is used by "
6913 #| "some Linux drivers to return a descriptor that is only to be used for "
6914 #| "device-specific B<ioctl>(2)  operations."
6915 msgid ""
6916 "Unlike the other values that can be specified in I<flags>, the I<access "
6917 "mode> values B<O_RDONLY>, B<O_WRONLY>, and B<O_RDWR>, do not specify "
6918 "individual bits.  Rather, they define the low order two bits of I<flags>, "
6919 "and are defined respectively as 0, 1, and 2.  In other words, the "
6920 "combination B<O_RDONLY | O_WRONLY> is a logical error, and certainly does "
6921 "not have the same meaning as B<O_RDWR>.  Linux reserves the special, "
6922 "nonstandard access mode 3 (binary 11) in I<flags> to mean: check for read "
6923 "and write permission on the file and return a descriptor that can't be used "
6924 "for reading or writing.  This nonstandard access mode is used by some Linux "
6925 "drivers to return a descriptor that is to be used only for device-specific "
6926 "B<ioctl>(2)  operations."
6927 msgstr ""
6928 "「アクセスモード」の値 B<O_RDONLY>, B<O_WRONLY>, B<O_RDWR> は、 I<flags> に指"
6929 "定できる他の値と違い、個々のビットを指定するものではなく、 これらの値は "
6930 "I<flags> の下位 2 ビットを定義する。 B<O_RDONLY>, B<O_WRONLY>, B<O_RDWR> はそ"
6931 "れぞれ 0, 1, 2 に定義されている。 言い換えると、 B<O_RDONLY | O_WRONLY> の組"
6932 "み合わせは論理的に間違いであり、確かに B<O_RDWR> と同じ意味ではない。 Linux "
6933 "では、特別な、非標準なアクセスモードとして 3 (バイナリでは 11) が 予約されて"
6934 "おり I<flags> に指定できる。 このアクセスモードを指定すると、ファイルの読み出"
6935 "し/書き込み許可をチェックし、 読み出しにも書き込みにも使用できないディスクリ"
6936 "プタを返す。 この非標準のアクセスモードはいくつかの Linux ドライバで使用され"
6937 "ており、 デバイス固有の B<ioctl>(2)  操作にのみ使用されるディスクリプタを返す"
6938 "ために使われている。"
6939
6940 #.  Linux 2.0, 2.5: truncate
6941 #.  Solaris 5.7, 5.8: truncate
6942 #.  Irix 6.5: truncate
6943 #.  Tru64 5.1B: truncate
6944 #.  HP-UX 11.22: truncate
6945 #.  FreeBSD 4.7: truncate
6946 #. type: Plain text
6947 #: build/C/man2/open.2:703
6948 msgid ""
6949 "The (undefined) effect of B<O_RDONLY | O_TRUNC> varies among "
6950 "implementations.  On many systems the file is actually truncated."
6951 msgstr ""
6952 "B<O_RDONLY | O_TRUNC> の影響は未定義であり、その動作は実装によって異なる。 多"
6953 "くのシステムではファイルは実際に切り詰められる。"
6954
6955 #. type: Plain text
6956 #: build/C/man2/open.2:707
6957 msgid ""
6958 "There are many infelicities in the protocol underlying NFS, affecting "
6959 "amongst others B<O_SYNC> and B<O_NDELAY>."
6960 msgstr ""
6961 "NFS を実現しているプロトコルには多くの不備があり、特に B<O_SYNC> と "
6962 "B<O_NDELAY> に影響する。"
6963
6964 #. type: Plain text
6965 #: build/C/man2/open.2:729
6966 #, fuzzy
6967 #| msgid ""
6968 #| "POSIX provides for three different variants of synchronized I/O, "
6969 #| "corresponding to the flags B<O_SYNC>, B<O_DSYNC>, and B<O_RSYNC>.  "
6970 #| "Currently (2.6.31), Linux only implements B<O_SYNC>, but glibc maps "
6971 #| "B<O_DSYNC> and B<O_RSYNC> to the same numerical value as B<O_SYNC>.  Most "
6972 #| "Linux file systems don't actually implement the POSIX B<O_SYNC> "
6973 #| "semantics, which require all metadata updates of a write to be on disk on "
6974 #| "returning to user space, but only the B<O_DSYNC> semantics, which require "
6975 #| "only actual file data and metadata necessary to retrieve it to be on disk "
6976 #| "by the time the system call returns."
6977 msgid ""
6978 "POSIX provides for three different variants of synchronized I/O, "
6979 "corresponding to the flags B<O_SYNC>, B<O_DSYNC>, and B<O_RSYNC>.  Currently "
6980 "(2.6.31), Linux implements only B<O_SYNC>, but glibc maps B<O_DSYNC> and "
6981 "B<O_RSYNC> to the same numerical value as B<O_SYNC>.  Most Linux file "
6982 "systems don't actually implement the POSIX B<O_SYNC> semantics, which "
6983 "require all metadata updates of a write to be on disk on returning to user "
6984 "space, but only the B<O_DSYNC> semantics, which require only actual file "
6985 "data and metadata necessary to retrieve it to be on disk by the time the "
6986 "system call returns."
6987 msgstr ""
6988 "POSIX では、3 種類の同期 I/O が提供されており、 B<O_SYNC>, B<O_DSYNC>, "
6989 "B<O_RSYNC> フラグがこれに対応するものである。 今のところ (カーネル 2.6.31)、 "
6990 "Linux では B<O_SYNC> だけが実装されているが、 glibc は B<O_DSYNC> と "
6991 "B<O_RSYNC> に B<O_SYNC> と同じ数値を割り当てている。 ほとんどの Linux のファ"
6992 "イルシステムは、実際には POSIX の B<O_SYNC> の動作ではなく B<O_DSYNC> の動作"
6993 "だけを実装している。 POSIX の B<O_SYNC> では、 B<open>()  がユーザ空間に返る"
6994 "際に、書き込みに関する全てのメタデータの 更新がディスクに書き込まれている必要"
6995 "がある。 一方、 B<O_DSYNC> では、 B<open>()  が返るまでに、実際のファイルの"
6996 "データとそのデータを取得するために 必要なメタデータだけがディスクに書き込まれ"
6997 "ていればよい。"
6998
6999 #. type: Plain text
7000 #: build/C/man2/open.2:737
7001 msgid ""
7002 "Note that B<open>()  can open device special files, but B<creat>()  cannot "
7003 "create them; use B<mknod>(2)  instead."
7004 msgstr ""
7005 "B<open>()  はスペシャルファイルをオープンすることができるが、 B<creat>()  で"
7006 "スペシャルファイルを作成できない点に注意すること。 代わりに B<mknod>(2)  を使"
7007 "用する。"
7008
7009 #. type: Plain text
7010 #: build/C/man2/open.2:750
7011 msgid ""
7012 "On NFS file systems with UID mapping enabled, B<open>()  may return a file "
7013 "descriptor but, for example, B<read>(2)  requests are denied with "
7014 "B<EACCES>.  This is because the client performs B<open>()  by checking the "
7015 "permissions, but UID mapping is performed by the server upon read and write "
7016 "requests."
7017 msgstr ""
7018 "UID マッピングを使用している NFS ファイルシステムでは、 B<open>()  がファイル"
7019 "ディスクリプタを返した場合でも B<read>(2)  が B<EACCES> で拒否される場合があ"
7020 "る。 これはクライアントがアクセス許可のチェックを行って B<open>()  を実行する"
7021 "が、読み込みや書き込みの際には サーバーで UID マッピングが行われるためであ"
7022 "る。"
7023
7024 #. type: Plain text
7025 #: build/C/man2/open.2:769
7026 msgid ""
7027 "If the file is newly created, its I<st_atime>, I<st_ctime>, I<st_mtime> "
7028 "fields (respectively, time of last access, time of last status change, and "
7029 "time of last modification; see B<stat>(2))  are set to the current time, and "
7030 "so are the I<st_ctime> and I<st_mtime> fields of the parent directory.  "
7031 "Otherwise, if the file is modified because of the B<O_TRUNC> flag, its "
7032 "st_ctime and st_mtime fields are set to the current time."
7033 msgstr ""
7034 "ファイルが新しく作成されると、 ファイルの I<st_atime>, I<st_ctime>, "
7035 "I<st_mtime> フィールド (それぞれ最終アクセス時刻、最終状態変更時刻、最終修正"
7036 "時刻である。 B<stat>(2)  参照) が現在時刻に設定される。 さらに親ディレクトリ"
7037 "の I<st_ctime> と I<st_mtime> も現在時刻に設定される。 それ以外の場合で、"
7038 "O_TRUNC フラグでファイルが修正されたときは、 ファイルの I<st_ctime> と "
7039 "I<st_mtime> フィールドが現在時刻に設定される。"
7040
7041 #. type: SS
7042 #: build/C/man2/open.2:769
7043 #, no-wrap
7044 msgid "O_DIRECT"
7045 msgstr "O_DIRECT"
7046
7047 #. type: Plain text
7048 #: build/C/man2/open.2:786
7049 msgid ""
7050 "The B<O_DIRECT> flag may impose alignment restrictions on the length and "
7051 "address of user-space buffers and the file offset of I/Os.  In Linux "
7052 "alignment restrictions vary by file system and kernel version and might be "
7053 "absent entirely.  However there is currently no file system-independent "
7054 "interface for an application to discover these restrictions for a given file "
7055 "or file system.  Some file systems provide their own interfaces for doing "
7056 "so, for example the B<XFS_IOC_DIOINFO> operation in B<xfsctl>(3)."
7057 msgstr ""
7058 "B<O_DIRECT> フラグを使用する場合、ユーザ空間バッファの長さやアドレス、 I/O の"
7059 "ファイルオフセットに関してアラインメントの制限が課されることがある。 Linux で"
7060 "は、アラインメントの制限はファイルシステムやカーネルのバージョンに よって異な"
7061 "り、全く制限が存在しない場合もある。 しかしながら、現在のところ、指定された"
7062 "ファイルやファイルシステムに対して こうした制限があるかを見つけるための、アプ"
7063 "リケーション向けのインタフェースで ファイルシステム非依存のものは存在しな"
7064 "い。 いくつかのファイルシステムでは、制限を確認するための独自のインタフェース"
7065 "が 提供されている。例えば、 B<xfsctl>(3)  の B<XFS_IOC_DIOINFO> 命令である。"
7066
7067 #. type: Plain text
7068 #: build/C/man2/open.2:791
7069 msgid ""
7070 "Under Linux 2.4, transfer sizes, and the alignment of the user buffer and "
7071 "the file offset must all be multiples of the logical block size of the file "
7072 "system.  Under Linux 2.6, alignment to 512-byte boundaries suffices."
7073 msgstr ""
7074 "Linux 2.4 では、転送サイズ、 ユーザーバッファのアラインメント、ファイルオフ"
7075 "セットは、 ファイルシステムの論理ブロックサイズの倍数でなければならない。 "
7076 "Linux 2.6 では、512 バイトごとの境界に配置されていれば充分である。"
7077
7078 #. type: Plain text
7079 #: build/C/man2/open.2:825
7080 msgid ""
7081 "B<O_DIRECT> I/Os should never be run concurrently with the B<fork>(2)  "
7082 "system call, if the memory buffer is a private mapping (i.e., any mapping "
7083 "created with the B<mmap>(2)  B<MAP_PRIVATE> flag; this includes memory "
7084 "allocated on the heap and statically allocated buffers).  Any such I/Os, "
7085 "whether submitted via an asynchronous I/O interface or from another thread "
7086 "in the process, should be completed before B<fork>(2)  is called.  Failure "
7087 "to do so can result in data corruption and undefined behavior in parent and "
7088 "child processes.  This restriction does not apply when the memory buffer for "
7089 "the B<O_DIRECT> I/Os was created using B<shmat>(2)  or B<mmap>(2)  with the "
7090 "B<MAP_SHARED> flag.  Nor does this restriction apply when the memory buffer "
7091 "has been advised as B<MADV_DONTFORK> with B<madvise>(2), ensuring that it "
7092 "will not be available to the child after B<fork>(2)."
7093 msgstr ""
7094 "メモリバッファがプライベートマッピング (B<mmap>(2) の B<MAP_PRIVATE>\n"
7095 "フラグで作成されたマッピング) の場合には、B<O_DIRECT> I/O は\n"
7096 "B<fork>(2) システムコールと同時に決して実行すべきではない \n"
7097 "(プライベートマッピングには、ヒープ領域に割り当てられたメモリや静的に\n"
7098 "割り当てたバッファも含まれる)。非同期 I/O インターフェース (AIO) 経由\n"
7099 "やプロセス内の他のスレッドから発行された、このような I/O は、\n"
7100 "B<fork>(2) が呼び出される前に完了されるべきである。\n"
7101 "そうしなかった場合、データ破壊や、親プロセスや子プロセスでの予期しない\n"
7102 "動作が起こる可能性がある。\n"
7103 "B<O_DIRECT> I/O 用のメモリバッファが B<shmat>(2) やB<MAP_SHARED> フラグ\n"
7104 "付きの B<mmap>(2) で作成された場合には、この制限はあてはまらない。\n"
7105 "B<madvise>(2) でメモリバッファにアドバイス B<MADV_DONTFORK> が設定され\n"
7106 "ている場合にも、この制限はあてはまらない(B<MADV_DONTFORK> はそのメモリ\n"
7107 "バッファが B<fork>(2) 後に子プロセスからは利用できないことを保証するも\n"
7108 "のである)。"
7109
7110 #. type: Plain text
7111 #: build/C/man2/open.2:835
7112 msgid ""
7113 "The B<O_DIRECT> flag was introduced in SGI IRIX, where it has alignment "
7114 "restrictions similar to those of Linux 2.4.  IRIX has also a B<fcntl>(2)  "
7115 "call to query appropriate alignments, and sizes.  FreeBSD 4.x introduced a "
7116 "flag of the same name, but without alignment restrictions."
7117 msgstr ""
7118 "B<O_DIRECT> フラグは SGI IRIX で導入された。SGI IRIX にも Linux 2.4 と同様の "
7119 "(ユーザーバッファの) アラインメントの制限がある。 また、IRIX には適切な配置と"
7120 "サイズを取得するための B<fcntl>(2)  コールがある。 FreeBSD 4.x も同じ名前のフ"
7121 "ラグを導入したが、アラインメントの制限はない。"
7122
7123 #. type: Plain text
7124 #: build/C/man2/open.2:844
7125 msgid ""
7126 "B<O_DIRECT> support was added under Linux in kernel version 2.4.10.  Older "
7127 "Linux kernels simply ignore this flag.  Some file systems may not implement "
7128 "the flag and B<open>()  will fail with B<EINVAL> if it is used."
7129 msgstr ""
7130 "B<O_DIRECT> が Linux でサポートされたのは、カーネルバージョン 2.4.10 であ"
7131 "る。 古い Linux カーネルは、このフラグを単に無視する。 B<O_DIRECT> フラグをサ"
7132 "ポートしていないファイルシステムもあり、その場合は、 B<O_DIRECT> を使用する"
7133 "と B<open>()  は B<EINVAL> で失敗する。"
7134
7135 #. type: Plain text
7136 #: build/C/man2/open.2:855
7137 msgid ""
7138 "Applications should avoid mixing B<O_DIRECT> and normal I/O to the same "
7139 "file, and especially to overlapping byte regions in the same file.  Even "
7140 "when the file system correctly handles the coherency issues in this "
7141 "situation, overall I/O throughput is likely to be slower than using either "
7142 "mode alone.  Likewise, applications should avoid mixing B<mmap>(2)  of files "
7143 "with direct I/O to the same files."
7144 msgstr ""
7145 "アプリケーションは、同じファイル、 特に同じファイルの重複するバイト領域に対し"
7146 "て、 B<O_DIRECT> と通常の I/O を混ぜて使うのは避けるべきである。 ファイルシス"
7147 "テムがこのような状況において一貫性の問題を正しく 扱うことができる場合であって"
7148 "も、全体の I/O スループットは どちらか一方を使用するときと比べて低速になるで"
7149 "あろう。 同様に、アプリケーションは、同じファイルに対して B<mmap>(2)  と直接 "
7150 "I/O (B<O_DIRECT>)  を混ぜて使うのも避けるべきである。"
7151
7152 #. type: Plain text
7153 #: build/C/man2/open.2:877
7154 #, fuzzy
7155 #| msgid ""
7156 #| "The behaviour of B<O_DIRECT> with NFS will differ from local file "
7157 #| "systems.  Older kernels, or kernels configured in certain ways, may not "
7158 #| "support this combination.  The NFS protocol does not support passing the "
7159 #| "flag to the server, so B<O_DIRECT> I/O will only bypass the page cache on "
7160 #| "the client; the server may still cache the I/O.  The client asks the "
7161 #| "server to make the I/O synchronous to preserve the synchronous semantics "
7162 #| "of B<O_DIRECT>.  Some servers will perform poorly under these "
7163 #| "circumstances, especially if the I/O size is small.  Some servers may "
7164 #| "also be configured to lie to clients about the I/O having reached stable "
7165 #| "storage; this will avoid the performance penalty at some risk to data "
7166 #| "integrity in the event of server power failure.  The Linux NFS client "
7167 #| "places no alignment restrictions on B<O_DIRECT> I/O."
7168 msgid ""
7169 "The behaviour of B<O_DIRECT> with NFS will differ from local file systems.  "
7170 "Older kernels, or kernels configured in certain ways, may not support this "
7171 "combination.  The NFS protocol does not support passing the flag to the "
7172 "server, so B<O_DIRECT> I/O will bypass the page cache only on the client; "
7173 "the server may still cache the I/O.  The client asks the server to make the "
7174 "I/O synchronous to preserve the synchronous semantics of B<O_DIRECT>.  Some "
7175 "servers will perform poorly under these circumstances, especially if the I/O "
7176 "size is small.  Some servers may also be configured to lie to clients about "
7177 "the I/O having reached stable storage; this will avoid the performance "
7178 "penalty at some risk to data integrity in the event of server power "
7179 "failure.  The Linux NFS client places no alignment restrictions on "
7180 "B<O_DIRECT> I/O."
7181 msgstr ""
7182 "NFS で B<O_DIRECT> を使った場合の動作はローカルのファイルシステムの場合と違"
7183 "う。 古いカーネルや、ある種の設定でコンパイルされたカーネルは、 B<O_DIRECT> "
7184 "と NFS の組み合わせをサポートしていないかもしれない。 NFS プロトコル自体は"
7185 "サーバにフラグを渡す機能は持っていないので、 B<O_DIRECT> I/O はクライアント上"
7186 "のページキャッシュをバイパスするだけになり、 サーバは I/O をキャッシュしてい"
7187 "るかもしれない。 クライアントは、 B<O_DIRECT> の同期機構を保持するため、サー"
7188 "バに対して I/O を同期して行うように依頼する。 サーバによっては、こうした状況"
7189 "下、特に I/O サイズが小さい場合に 性能が大きく劣化する。 また、サーバによって"
7190 "は、I/O が安定したストレージにまで行われたと、 クライアントに対して嘘をつくも"
7191 "のもある。 これは、サーバの電源故障が起こった際にデータの完全性が保たれない "
7192 "危険は少しあるが、性能面での不利な条件を回避するために行われている。 Linux "
7193 "の NFS クライアントでは B<O_DIRECT> I/O でのアラインメントの制限はない。"
7194
7195 #. type: Plain text
7196 #: build/C/man2/open.2:884
7197 msgid ""
7198 "In summary, B<O_DIRECT> is a potentially powerful tool that should be used "
7199 "with caution.  It is recommended that applications treat use of B<O_DIRECT> "
7200 "as a performance option which is disabled by default."
7201 msgstr ""
7202 "まとめると、 B<O_DIRECT> は、注意して使うべきであるが、強力なツールとなる可能"
7203 "性を持っている。 アプリケーションは B<O_DIRECT> をデフォルトでは無効になって"
7204 "いる性能向上のためのオプションと 考えておくのがよいであろう。"
7205
7206 #. type: Plain text
7207 #: build/C/man2/open.2:889
7208 msgid ""
7209 "\"The thing that has always disturbed me about O_DIRECT is that the whole "
7210 "interface is just stupid, and was probably designed by a deranged monkey on "
7211 "some serious mind-controlling substances.\"\\(emLinus"
7212 msgstr ""
7213 "「O_DIRECT でいつも困るのは、インタフェース全部が本当にお馬鹿な点だ。 たぶん"
7214 "危ないマインドコントロール剤で 頭がおかしくなったサルが設計したんじゃないか"
7215 "な」 \\(em Linus"
7216
7217 #.  FIXME . Check bugzilla report on open(O_ASYNC)
7218 #.  See http://bugzilla.kernel.org/show_bug.cgi?id=5993
7219 #. type: Plain text
7220 #: build/C/man2/open.2:901
7221 msgid ""
7222 "Currently, it is not possible to enable signal-driven I/O by specifying "
7223 "B<O_ASYNC> when calling B<open>(); use B<fcntl>(2)  to enable this flag."
7224 msgstr ""
7225 "現在のところ、 B<open>()  の呼び出し時に B<O_ASYNC> を指定してシグナル駆動 I/"
7226 "O を有効にすることはできない。 このフラグを有効にするには B<fcntl>(2)  を使用"
7227 "すること。"
7228
7229 #. type: Plain text
7230 #: build/C/man2/open.2:923
7231 msgid ""
7232 "B<chmod>(2), B<chown>(2), B<close>(2), B<dup>(2), B<fcntl>(2), B<link>(2), "
7233 "B<lseek>(2), B<mknod>(2), B<mmap>(2), B<mount>(2), B<openat>(2), B<read>(2), "
7234 "B<socket>(2), B<stat>(2), B<umask>(2), B<unlink>(2), B<write>(2), B<fopen>"
7235 "(3), B<fifo>(7), B<path_resolution>(7), B<symlink>(7)"
7236 msgstr ""
7237 "B<chmod>(2), B<chown>(2), B<close>(2), B<dup>(2), B<fcntl>(2), B<link>(2), "
7238 "B<lseek>(2), B<mknod>(2), B<mmap>(2), B<mount>(2), B<openat>(2), B<read>(2), "
7239 "B<socket>(2), B<stat>(2), B<umask>(2), B<unlink>(2), B<write>(2), B<fopen>"
7240 "(3), B<fifo>(7), B<path_resolution>(7), B<symlink>(7)"
7241
7242 #. type: TH
7243 #: build/C/man3/perror.3:31
7244 #, no-wrap
7245 msgid "PERROR"
7246 msgstr "PERROR"
7247
7248 #. type: TH
7249 #: build/C/man3/perror.3:31
7250 #, no-wrap
7251 msgid "2012-04-17"
7252 msgstr "2012-04-17"
7253
7254 #. type: Plain text
7255 #: build/C/man3/perror.3:34
7256 msgid "perror - print a system error message"
7257 msgstr "perror - システムエラーメッセージを出力する"
7258
7259 #. type: Plain text
7260 #: build/C/man3/perror.3:38
7261 msgid "B<void perror(const char *>I<s>B<);>"
7262 msgstr "B<void perror(const char *>I<s>B<);>"
7263
7264 #. type: Plain text
7265 #: build/C/man3/perror.3:40
7266 msgid "B<#include E<lt>errno.hE<gt>>"
7267 msgstr "B<#include E<lt>errno.hE<gt>>"
7268
7269 #. type: Plain text
7270 #: build/C/man3/perror.3:42
7271 msgid "B<const char *>I<sys_errlist>B<[];>"
7272 msgstr "B<const char *>I<sys_errlist>B<[];>"
7273
7274 #. type: Plain text
7275 #: build/C/man3/perror.3:44
7276 msgid "B<int >I<sys_nerr>B<;>"
7277 msgstr "B<int >I<sys_nerr>B<;>"
7278
7279 #. type: Plain text
7280 #: build/C/man3/perror.3:46
7281 msgid "B<int >I<errno>B<;>"
7282 msgstr "B<int >I<errno>B<;>"
7283
7284 #. type: Plain text
7285 #: build/C/man3/perror.3:55
7286 msgid "I<sys_errlist>, I<sys_nerr>: _BSD_SOURCE"
7287 msgstr "I<sys_errlist>, I<sys_nerr>: _BSD_SOURCE"
7288
7289 #. type: Plain text
7290 #: build/C/man3/perror.3:68
7291 msgid ""
7292 "The routine B<perror>()  produces a message on the standard error output, "
7293 "describing the last error encountered during a call to a system or library "
7294 "function.  First (if I<s> is not NULL and I<*s> is not a null byte (\\(aq"
7295 "\\e0\\(aq)) the argument string I<s> is printed, followed by a colon and a "
7296 "blank.  Then the message and a new-line."
7297 msgstr ""
7298 "関数 B<perror>()  は、システムコールやライブラリ関数の呼び出しにおいて、最後"
7299 "に発生した エラーに関する説明メッセージを生成し、標準エラー出力に出力する。 "
7300 "(I<s> が NULL でなく、 I<*s> が NULL バイト (\\(aq\\e0\\(aq) でない場合には) "
7301 "引き数の文字列 I<s> がまず出力され、続いてコロン、空白が出力され、 それから"
7302 "メッセージと改行が出力される。"
7303
7304 #. type: Plain text
7305 #: build/C/man3/perror.3:76
7306 msgid ""
7307 "To be of most use, the argument string should include the name of the "
7308 "function that incurred the error.  The error number is taken from the "
7309 "external variable I<errno>, which is set when errors occur but not cleared "
7310 "when successful calls are made."
7311 msgstr ""
7312 "このメッセージを最大限活用するためには、引き数文字列にエラーが発生した 関数名"
7313 "を入れておくとよい。 エラー番号は外部変数 I<errno> から取得される。 I<errno> "
7314 "はエラーが発生した時に設定され、 成功した呼び出しではクリアされない。"
7315
7316 #. type: Plain text
7317 #: build/C/man3/perror.3:90
7318 msgid ""
7319 "The global error list I<sys_errlist>[] indexed by I<errno> can be used to "
7320 "obtain the error message without the newline.  The largest message number "
7321 "provided in the table is I<sys_nerr>-1.  Be careful when directly accessing "
7322 "this list because new error values may not have been added to I<sys_errlist>"
7323 "[].  The use of I<sys_errlist>[] is nowadays deprecated."
7324 msgstr ""
7325 "大域変数のエラーリスト I<sys_errlist>[] は I<errno> を添字とする配列で、こ"
7326 "の\n"
7327 "配列から改行無しのエラーメッセージが取得される。 テーブルでの最大のメッセー"
7328 "ジ\n"
7329 "番号は I<sys_nerr> -1 となる。 このテーブルを直接参照する際には注意するこ"
7330 "と。\n"
7331 "なぜなら、新しいエラー番号が I<sys_errlist>[] に追加済とは限らないからであ"
7332 "る。\n"
7333 "現在では、I<sys_errlist>[] の使用は非推奨となっている。"
7334
7335 #. type: Plain text
7336 #: build/C/man3/perror.3:111
7337 msgid ""
7338 "When a system call fails, it usually returns -1 and sets the variable "
7339 "I<errno> to a value describing what went wrong.  (These values can be found "
7340 "in I<E<lt>errno.hE<gt>>.)  Many library functions do likewise.  The function "
7341 "B<perror>()  serves to translate this error code into human-readable form.  "
7342 "Note that I<errno> is undefined after a successful library call: this call "
7343 "may well change this variable, even though it succeeds, for example because "
7344 "it internally used some other library function that failed.  Thus, if a "
7345 "failing call is not immediately followed by a call to B<perror>(), the value "
7346 "of I<errno> should be saved."
7347 msgstr ""
7348 "システムコールが失敗した場合、通常、返り値として -1 が返り、 I<errno> にエ"
7349 "ラーを識別する値が設定される (設定されるエラー番号は I<E<lt>errno.hE<gt>> に"
7350 "記載されている)。 多くのライブラリ関数も同様の動作となる。 関数 B<perror>()  "
7351 "は、このエラーコードの可読なメッセージへの変換を行う。 I<errno> は、ライブラ"
7352 "リ呼び出しが成功した後には未定義であることに注意が必要である: その呼び出し自"
7353 "身は成功したとしても、内部で呼び出した他のライブラリ関数が 失敗して、その結果"
7354 "をこの変数に設定することがあるからだ。 よって、失敗した呼び出しの直後に "
7355 "B<perror>()  を呼ばない場合には I<errno> の値を 保存しておかなければならな"
7356 "い。"
7357
7358 #. type: Plain text
7359 #: build/C/man3/perror.3:124
7360 msgid ""
7361 "The function B<perror>()  and the external I<errno> (see B<errno>(3))  "
7362 "conform to C89, C99, 4.3BSD, POSIX.1-2001.  The externals I<sys_nerr> and "
7363 "I<sys_errlist> conform to BSD."
7364 msgstr ""
7365 "関数 B<perror>()  と外部変数 I<errno> (B<errno>(3)  参照) は C89, 4.3BSD, "
7366 "POSIX.1-2001 に準拠している。 外部変数 I<sys_nerr> と I<sys_errlist> は BSD "
7367 "に準拠している。"
7368
7369 #.  and only when _BSD_SOURCE is defined.
7370 #.  When
7371 #.  .B _GNU_SOURCE
7372 #.  is defined, the symbols
7373 #.  .I _sys_nerr
7374 #.  and
7375 #.  .I _sys_errlist
7376 #.  are provided.
7377 #. type: Plain text
7378 #: build/C/man3/perror.3:139
7379 msgid ""
7380 "The externals I<sys_nerr> and I<sys_errlist> are defined by glibc, but in "
7381 "I<E<lt>stdio.hE<gt>>."
7382 msgstr ""
7383 "外部変数 I<sys_nerr> と I<sys_errlist> は glibc で定義されているが、 "
7384 "I<E<lt>stdio.hE<gt>> に含まれている。"
7385
7386 #. type: Plain text
7387 #: build/C/man3/perror.3:144
7388 msgid "B<err>(3), B<errno>(3), B<error>(3), B<strerror>(3)"
7389 msgstr "B<err>(3), B<errno>(3), B<error>(3), B<strerror>(3)"
7390
7391 #. type: TH
7392 #: build/C/man2/pipe.2:36
7393 #, no-wrap
7394 msgid "PIPE"
7395 msgstr "PIPE"
7396
7397 #. type: TH
7398 #: build/C/man2/pipe.2:36
7399 #, no-wrap
7400 msgid "2012-02-14"
7401 msgstr "2012-02-14"
7402
7403 #. type: Plain text
7404 #: build/C/man2/pipe.2:39
7405 msgid "pipe, pipe2 - create pipe"
7406 msgstr "pipe, pipe2 - パイプを生成する"
7407
7408 #. type: Plain text
7409 #: build/C/man2/pipe.2:42 build/C/man2/read.2:41
7410 #, no-wrap
7411 msgid "B<#include E<lt>unistd.hE<gt>>\n"
7412 msgstr "B<#include E<lt>unistd.hE<gt>>\n"
7413
7414 #. type: Plain text
7415 #: build/C/man2/pipe.2:44
7416 #, no-wrap
7417 msgid "B<int pipe(int >I<pipefd>B<[2]);>\n"
7418 msgstr "B<int pipe(int >I<pipefd>B<[2]);>\n"
7419
7420 #. type: Plain text
7421 #: build/C/man2/pipe.2:48
7422 #, no-wrap
7423 msgid ""
7424 "B<#define _GNU_SOURCE>             /* See feature_test_macros(7) */\n"
7425 "B<#include E<lt>fcntl.hE<gt>>              /* Obtain O_* constant definitions */\n"
7426 "B<#include E<lt>unistd.hE<gt>>\n"
7427 msgstr ""
7428 "B<#define _GNU_SOURCE>             /* feature_test_macros(7) 参照 */\n"
7429 "B<#include E<lt>fcntl.hE<gt>>              /* O_* 定数の定義の取得 */\n"
7430 "B<#include E<lt>unistd.hE<gt>>\n"
7431
7432 #. type: Plain text
7433 #: build/C/man2/pipe.2:50
7434 #, no-wrap
7435 msgid "B<int pipe2(int >I<pipefd>B<[2], int >I<flags>B<);>\n"
7436 msgstr "B<int pipe2(int >I<pipefd>B<[2], int >I<flags>B<);>\n"
7437
7438 #. type: Plain text
7439 #: build/C/man2/pipe.2:66
7440 msgid ""
7441 "B<pipe>()  creates a pipe, a unidirectional data channel that can be used "
7442 "for interprocess communication.  The array I<pipefd> is used to return two "
7443 "file descriptors referring to the ends of the pipe.  I<pipefd[0]> refers to "
7444 "the read end of the pipe.  I<pipefd[1]> refers to the write end of the "
7445 "pipe.  Data written to the write end of the pipe is buffered by the kernel "
7446 "until it is read from the read end of the pipe.  For further details, see "
7447 "B<pipe>(7)."
7448 msgstr ""
7449 "B<pipe>(2)  はパイプを生成する。 パイプは、プロセス間通信に使用できる単方向の"
7450 "データチャネルである。 配列 I<pipefd> は、パイプの両端を参照する二つのファイ"
7451 "ルディスクリプタを 返すのに使用される。 I<pipefd[0]> がパイプの読み出し側、 "
7452 "I<pipefd[1]> がパイプの書き込み側である。 パイプの書き込み側に書き込まれた"
7453 "データは、 パイプの読み出し側から読み出されるまでカーネルでバッファリングされ"
7454 "る。 さらなる詳細は B<pipe>(7)  を参照のこと。"
7455
7456 #. type: Plain text
7457 #: build/C/man2/pipe.2:76
7458 msgid ""
7459 "If I<flags> is 0, then B<pipe2>()  is the same as B<pipe>().  The following "
7460 "values can be bitwise ORed in I<flags> to obtain different behavior:"
7461 msgstr ""
7462 "B<pipe2>()  は I<flags> が 0 の場合には B<pipe>()  と同じである。 I<flags> に"
7463 "以下の値をビット毎の論理和 (OR) で指定することで、 異なる動作をさせることがで"
7464 "きる。"
7465
7466 #. type: TP
7467 #: build/C/man2/pipe.2:76
7468 #, no-wrap
7469 msgid "B<O_NONBLOCK>"
7470 msgstr "B<O_NONBLOCK>"
7471
7472 #. type: Plain text
7473 #: build/C/man2/pipe.2:84
7474 msgid ""
7475 "Set the B<O_NONBLOCK> file status flag on the two new open file "
7476 "descriptions.  Using this flag saves extra calls to B<fcntl>(2)  to achieve "
7477 "the same result."
7478 msgstr ""
7479 "新しく生成される二つのオープンファイル記述 (open file description) の "
7480 "B<O_NONBLOCK> ファイルステータスフラグをセットする。 このフラグを使うこと"
7481 "で、 B<O_NONBLOCK> をセットするために B<fcntl>(2)  を追加で呼び出す必要がなく"
7482 "なる。"
7483
7484 #. type: TP
7485 #: build/C/man2/pipe.2:84
7486 #, no-wrap
7487 msgid "B<O_CLOEXEC>"
7488 msgstr "B<O_CLOEXEC>"
7489
7490 #. type: Plain text
7491 #: build/C/man2/pipe.2:92
7492 msgid ""
7493 "Set the close-on-exec (B<FD_CLOEXEC>)  flag on the two new file "
7494 "descriptors.  See the description of the same flag in B<open>(2)  for "
7495 "reasons why this may be useful."
7496 msgstr ""
7497 "新しく生成される二つのファイルディスクリプタの close-on-exec "
7498 "(B<FD_CLOEXEC>)  フラグをセットする。 このフラグが役に立つ理由については、 "
7499 "B<open>(2)  の B<O_CLOEXEC> フラグの説明を参照のこと。"
7500
7501 #. type: Plain text
7502 #: build/C/man2/pipe.2:102
7503 msgid "I<pipefd> is not valid."
7504 msgstr "I<pipefd> が無効な値である。"
7505
7506 #. type: Plain text
7507 #: build/C/man2/pipe.2:107
7508 msgid "(B<pipe2>())  Invalid value in I<flags>."
7509 msgstr "(B<pipe2>())  I<flags> に無効な値が入っている。"
7510
7511 #. type: Plain text
7512 #: build/C/man2/pipe.2:110
7513 msgid "Too many file descriptors are in use by the process."
7514 msgstr "このプロセスで使われているファイルディスクリプタが多すぎる。"
7515
7516 #. type: Plain text
7517 #: build/C/man2/pipe.2:118
7518 msgid ""
7519 "B<pipe2>()  was added to Linux in version 2.6.27; glibc support is available "
7520 "starting with version 2.9."
7521 msgstr ""
7522 "B<pipe2>()  はバージョン 2.6.27 で Linux に追加された。 glibc によるサポート"
7523 "はバージョン 2.9 以降で利用できる。"
7524
7525 #. type: Plain text
7526 #: build/C/man2/pipe.2:121
7527 msgid "B<pipe>(): POSIX.1-2001."
7528 msgstr "B<pipe>(): POSIX.1-2001."
7529
7530 #. type: Plain text
7531 #: build/C/man2/pipe.2:124
7532 msgid "B<pipe2>()  is Linux-specific."
7533 msgstr "B<pipe2>()  は Linux 固有である。"
7534
7535 #.  fork.2 refers to this example program.
7536 #. type: Plain text
7537 #: build/C/man2/pipe.2:140
7538 msgid ""
7539 "The following program creates a pipe, and then B<fork>(2)s to create a child "
7540 "process; the child inherits a duplicate set of file descriptors that refer "
7541 "to the same pipe.  After the B<fork>(2), each process closes the descriptors "
7542 "that it doesn't need for the pipe (see B<pipe>(7)).  The parent then writes "
7543 "the string contained in the program's command-line argument to the pipe, and "
7544 "the child reads this string a byte at a time from the pipe and echoes it on "
7545 "standard output."
7546 msgstr ""
7547 "以下のプログラムではパイプを生成し、その後 B<fork>(2)  で子プロセスを生成す"
7548 "る。 子プロセスは同じパイプを参照するファイルディスクリプタ集合のコピーを 継"
7549 "承する。 B<fork>(2)  の後、各プロセスはパイプ (B<pipe>(7)  を参照) に必要がな"
7550 "くなったディスクリプタをクローズする。 親プロセスはプログラムのコマンドライン"
7551 "引き数に含まれる 文字列をパイプへ書き込み、 子プロセスはこの文字列をパイプか"
7552 "ら 1 バイトずつ読み込んで標準出力にエコーする。"
7553
7554 #. type: Plain text
7555 #: build/C/man2/pipe.2:147
7556 #, no-wrap
7557 msgid ""
7558 "#include E<lt>sys/wait.hE<gt>\n"
7559 "#include E<lt>stdio.hE<gt>\n"
7560 "#include E<lt>stdlib.hE<gt>\n"
7561 "#include E<lt>unistd.hE<gt>\n"
7562 "#include E<lt>string.hE<gt>\n"
7563 msgstr ""
7564 "#include E<lt>sys/wait.hE<gt>\n"
7565 "#include E<lt>stdio.hE<gt>\n"
7566 "#include E<lt>stdlib.hE<gt>\n"
7567 "#include E<lt>unistd.hE<gt>\n"
7568 "#include E<lt>string.hE<gt>\n"
7569
7570 #. type: Plain text
7571 #: build/C/man2/pipe.2:154
7572 #, no-wrap
7573 msgid ""
7574 "int\n"
7575 "main(int argc, char *argv[])\n"
7576 "{\n"
7577 "    int pipefd[2];\n"
7578 "    pid_t cpid;\n"
7579 "    char buf;\n"
7580 msgstr ""
7581 "int\n"
7582 "main(int argc, char *argv[])\n"
7583 "{\n"
7584 "    int pipefd[2];\n"
7585 "    pid_t cpid;\n"
7586 "    char buf;\n"
7587
7588 #. type: Plain text
7589 #: build/C/man2/pipe.2:159
7590 #, no-wrap
7591 msgid ""
7592 "    if (argc != 2) {\n"
7593 "\tfprintf(stderr, \"Usage: %s E<lt>stringE<gt>\\en\", argv[0]);\n"
7594 "\texit(EXIT_FAILURE);\n"
7595 "    }\n"
7596 msgstr ""
7597 "    if (argc != 2) {\n"
7598 "\tfprintf(stderr, \"Usage: %s E<lt>stringE<gt>\\en\", argv[0]);\n"
7599 "\texit(EXIT_FAILURE);\n"
7600 "    }\n"
7601
7602 #. type: Plain text
7603 #: build/C/man2/pipe.2:164
7604 #, no-wrap
7605 msgid ""
7606 "    if (pipe(pipefd) == -1) {\n"
7607 "        perror(\"pipe\");\n"
7608 "        exit(EXIT_FAILURE);\n"
7609 "    }\n"
7610 msgstr ""
7611 "    if (pipe(pipefd) == -1) {\n"
7612 "        perror(\"pipe\");\n"
7613 "        exit(EXIT_FAILURE);\n"
7614 "    }\n"
7615
7616 #. type: Plain text
7617 #: build/C/man2/pipe.2:170
7618 #, no-wrap
7619 msgid ""
7620 "    cpid = fork();\n"
7621 "    if (cpid == -1) {\n"
7622 "        perror(\"fork\");\n"
7623 "        exit(EXIT_FAILURE);\n"
7624 "    }\n"
7625 msgstr ""
7626 "    cpid = fork();\n"
7627 "    if (cpid == -1) {\n"
7628 "        perror(\"fork\");\n"
7629 "        exit(EXIT_FAILURE);\n"
7630 "    }\n"
7631
7632 #. type: Plain text
7633 #: build/C/man2/pipe.2:173
7634 #, no-wrap
7635 msgid ""
7636 "    if (cpid == 0) {    /* Child reads from pipe */\n"
7637 "        close(pipefd[1]);          /* Close unused write end */\n"
7638 msgstr ""
7639 "    if (cpid == 0) {    /* 子プロセスがパイプから読み込む */\n"
7640 "        close(pipefd[1]);  /* 使用しない write 側はクローズする */\n"
7641
7642 #. type: Plain text
7643 #: build/C/man2/pipe.2:176
7644 #, no-wrap
7645 msgid ""
7646 "        while (read(pipefd[0], &buf, 1) E<gt> 0)\n"
7647 "            write(STDOUT_FILENO, &buf, 1);\n"
7648 msgstr ""
7649 "        while (read(pipefd[0], &buf, 1) E<gt> 0)\n"
7650 "            write(STDOUT_FILENO, &buf, 1);\n"
7651
7652 #. type: Plain text
7653 #: build/C/man2/pipe.2:180
7654 #, no-wrap
7655 msgid ""
7656 "        write(STDOUT_FILENO, \"\\en\", 1);\n"
7657 "        close(pipefd[0]);\n"
7658 "        _exit(EXIT_SUCCESS);\n"
7659 msgstr ""
7660 "        write(STDOUT_FILENO, \"\\en\", 1);\n"
7661 "        close(pipefd[0]);\n"
7662 "        _exit(EXIT_SUCCESS);\n"
7663
7664 #. type: Plain text
7665 #: build/C/man2/pipe.2:189
7666 #, no-wrap
7667 msgid ""
7668 "    } else {            /* Parent writes argv[1] to pipe */\n"
7669 "        close(pipefd[0]);          /* Close unused read end */\n"
7670 "        write(pipefd[1], argv[1], strlen(argv[1]));\n"
7671 "        close(pipefd[1]);          /* Reader will see EOF */\n"
7672 "        wait(NULL);                /* Wait for child */\n"
7673 "        exit(EXIT_SUCCESS);\n"
7674 "    }\n"
7675 "}\n"
7676 msgstr ""
7677 "    } else {            /* 親プロセスは argv[1] をパイプへ書き込む */\n"
7678 "        close(pipefd[0]);          /* 使用しない read 側はクローズする */\n"
7679 "        write(pipefd[1], argv[1], strlen(argv[1]));\n"
7680 "        close(pipefd[1]);          /* 読み込み側が EOF に出会う */\n"
7681 "        wait(NULL);                /* 子プロセスを待つ */\n"
7682 "        exit(EXIT_SUCCESS);\n"
7683 "    }\n"
7684 "}\n"
7685
7686 #. type: Plain text
7687 #: build/C/man2/pipe.2:197
7688 msgid ""
7689 "B<fork>(2), B<read>(2), B<socketpair>(2), B<write>(2), B<popen>(3), B<pipe>"
7690 "(7)"
7691 msgstr ""
7692 "B<fork>(2), B<read>(2), B<socketpair>(2), B<write>(2), B<popen>(3), B<pipe>"
7693 "(7)"
7694
7695 #. type: TH
7696 #: build/C/man3/popen.3:40
7697 #, no-wrap
7698 msgid "POPEN"
7699 msgstr "POPEN"
7700
7701 #. type: TH
7702 #: build/C/man3/popen.3:40
7703 #, no-wrap
7704 msgid "2010-02-03"
7705 msgstr "2010-02-03"
7706
7707 #. type: Plain text
7708 #: build/C/man3/popen.3:43
7709 msgid "popen, pclose - pipe stream to or from a process"
7710 msgstr "popen, pclose - プロセスとの入力/出力用のパイプストリーム"
7711
7712 #. type: Plain text
7713 #: build/C/man3/popen.3:48
7714 #, no-wrap
7715 msgid "B<FILE *popen(const char *>I<command>B<, const char *>I<type>B<);>\n"
7716 msgstr "B<FILE *popen(const char *>I<command>B<, const char *>I<type>B<);>\n"
7717
7718 #. type: Plain text
7719 #: build/C/man3/popen.3:50
7720 #, no-wrap
7721 msgid "B<int pclose(FILE *>I<stream>B<);>\n"
7722 msgstr "B<int pclose(FILE *>I<stream>B<);>\n"
7723
7724 #. type: Plain text
7725 #: build/C/man3/popen.3:60
7726 msgid "B<popen>(), B<pclose>():"
7727 msgstr "B<popen>(), B<pclose>():"
7728
7729 #. type: Plain text
7730 #: build/C/man3/popen.3:62
7731 msgid ""
7732 "_POSIX_C_SOURCE\\ E<gt>=\\ 2 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE"
7733 msgstr ""
7734 "_POSIX_C_SOURCE\\ E<gt>=\\ 2 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE"
7735
7736 #. type: Plain text
7737 #: build/C/man3/popen.3:73
7738 msgid ""
7739 "The B<popen>()  function opens a process by creating a pipe, forking, and "
7740 "invoking the shell.  Since a pipe is by definition unidirectional, the "
7741 "I<type> argument may specify only reading or writing, not both; the "
7742 "resulting stream is correspondingly read-only or write-only."
7743 msgstr ""
7744 "B<popen>()  関数は、プロセスをオープンする。具体的には、 パイプを生成し、"
7745 "フォークを行い、シェルを起動する。 定義から分かるように、パイプは一方向なの"
7746 "で、 I<type> 引き数には読み込みか書き込みのどちらか一方だけを指定できる (両方"
7747 "は指定できない)。 生成されるストリームは、この指定に対応して、読み取り専用ま"
7748 "たは 書き込み専用のいずれかとなる。"
7749
7750 #. type: Plain text
7751 #: build/C/man3/popen.3:97
7752 msgid ""
7753 "The I<command> argument is a pointer to a null-terminated string containing "
7754 "a shell command line.  This command is passed to I</bin/sh> using the B<-c> "
7755 "flag; interpretation, if any, is performed by the shell.  The I<type> "
7756 "argument is a pointer to a null-terminated string which must contain either "
7757 "the letter \\(aqr\\(aq for reading or the letter \\(aqw\\(aq for writing.  "
7758 "Since glibc 2.9, this argument can additionally include the letter \\(aqe"
7759 "\\(aq, which causes the close-on-exec flag (B<FD_CLOEXEC>)  to be set on the "
7760 "underlying file descriptor; see the description of the B<O_CLOEXEC> flag in "
7761 "B<open>(2)  for reasons why this may be useful."
7762 msgstr ""
7763 "I<command> 引き数は、シェルのコマンドラインを含む NULL 終端された文字列へのポ"
7764 "インタである。 このコマンドは B<-c> フラグを用いて I</bin/sh> に渡される。 コ"
7765 "マンドの解釈は (もし必要ならば) シェルによって行われる。 I<type> 引き数は、"
7766 "NULL 終端された文字列へのポインタで、 読み込みを示す文字 \\(aqr\\(aq か、書き"
7767 "込みを示す文字 \\(aqw\\(aq の どちらか一方を指定しなければならない。 glibc "
7768 "2.9 以降では、この引き数に文字 \\(aqe\\(aq を追加で指定できる。 文字 \\(aqe"
7769 "\\(aq を指定すると、 対応するファイルディスクリプタにおいて、 close-on-exec "
7770 "フラグ (B<FD_CLOEXEC>)  がセットされる。 これが役に立つ理由については、 "
7771 "B<open>(2)  の B<O_CLOEXEC> フラグの説明を参照のこと。"
7772
7773 #. type: Plain text
7774 #: build/C/man3/popen.3:113
7775 msgid ""
7776 "The return value from B<popen>()  is a normal standard I/O stream in all "
7777 "respects save that it must be closed with B<pclose>()  rather than B<fclose>"
7778 "(3).  Writing to such a stream writes to the standard input of the command; "
7779 "the command's standard output is the same as that of the process that called "
7780 "B<popen>(), unless this is altered by the command itself.  Conversely, "
7781 "reading from a \"popened\" stream reads the command's standard output, and "
7782 "the command's standard input is the same as that of the process that called "
7783 "B<popen>()."
7784 msgstr ""
7785 "B<popen>()  からの返り値は、通常の標準 I/O ストリームと同じであるが、 "
7786 "B<fclose>(3)  ではなく B<pclose>()  で閉じなくてはならないことだけが異なる。 "
7787 "このストリームへ書き込んだ結果はコマンドの標準入力に書き込まれる。 そして、コ"
7788 "マンドの標準出力は、 コマンドそのものが置き換わってしまわない限り、 B<popen>"
7789 "()  を呼んだプロセスの標準出力と同じことになる。 逆に、\"popened\" (B<popen>"
7790 "()  によって開かれた) ストリームからの読み込みは、 そのコマンドの標準出力を読"
7791 "み込むことになる。 そして、そのコマンドの標準入力は B<popen>()  を呼んだプロ"
7792 "セスの標準入力と同一である。"
7793
7794 #. type: Plain text
7795 #: build/C/man3/popen.3:117
7796 msgid "Note that output B<popen>()  streams are fully buffered by default."
7797 msgstr ""
7798 "デフォルトでは、 B<popen>()  の出力ストリームは完全にバッファリングされること"
7799 "に注意しよう。"
7800
7801 #. type: Plain text
7802 #: build/C/man3/popen.3:123
7803 msgid ""
7804 "The B<pclose>()  function waits for the associated process to terminate and "
7805 "returns the exit status of the command as returned by B<wait4>(2)."
7806 msgstr ""
7807 "B<pclose>()  関数は、(パイプに) 関連づけられたプロセスが終了するのを待ち、 "
7808 "B<wait4>(2)  によって返されたコマンドの終了状態を返す。"
7809
7810 #. type: Plain text
7811 #: build/C/man3/popen.3:131
7812 msgid ""
7813 "The B<popen>()  function returns NULL if the B<fork>(2)  or B<pipe>(2)  "
7814 "calls fail, or if it cannot allocate memory."
7815 msgstr ""
7816 "B<popen>()  関数は、 B<fork>(2)  または B<pipe>(2)  呼び出しが失敗した場合"
7817 "や、 メモリ割り当てができなかった場合、 NULL を返す。"
7818
7819 #.  These conditions actually give undefined results, so I commented
7820 #.  them out.
7821 #.  .I stream
7822 #.  is not associated with a "popen()ed" command, if
7823 #. .I stream
7824 #.  already "pclose()d", or if
7825 #. type: Plain text
7826 #: build/C/man3/popen.3:143
7827 msgid ""
7828 "The B<pclose>()  function returns -1 if B<wait4>(2)  returns an error, or "
7829 "some other error is detected."
7830 msgstr ""
7831 "B<pclose>()  関数は、 B<wait4>(2)  がエラーを返したり、何か他のエラーが見つ"
7832 "かった場合、 -1 を返す。"
7833
7834 #. type: Plain text
7835 #: build/C/man3/popen.3:162
7836 msgid ""
7837 "The B<popen>()  function does not set I<errno> if memory allocation fails.  "
7838 "If the underlying B<fork>(2)  or B<pipe>(2)  fails, I<errno> is set "
7839 "appropriately.  If the I<type> argument is invalid, and this condition is "
7840 "detected, I<errno> is set to B<EINVAL>."
7841 msgstr ""
7842 "B<popen>()  関数は、メモリアロケーションに失敗しても I<errno> をセットしな"
7843 "い。 B<popen>()  が中で呼び出す B<fork>(2)  や B<pipe>(2)  が失敗した場合に"
7844 "は、 I<errno> が適切にセットされる。 引き数 I<type> が無効であり、この状態が"
7845 "検知された場合には、 I<errno> が B<EINVAL> にセットされる。"
7846
7847 #. type: Plain text
7848 #: build/C/man3/popen.3:169
7849 msgid ""
7850 "If B<pclose>()  cannot obtain the child status, I<errno> is set to B<ECHILD>."
7851 msgstr ""
7852 "B<pclose>()  が、子プロセスの状態を取得できなかった場合、 I<errno> が "
7853 "B<ECHILD> にセットされる。"
7854
7855 #. type: Plain text
7856 #: build/C/man3/popen.3:175
7857 msgid "The \\(aqe\\(aq value for I<type> is a Linux extension."
7858 msgstr "I<type> に指定できる \\(aqe\\(aq は Linux での拡張である。"
7859
7860 #. type: Plain text
7861 #: build/C/man3/popen.3:188
7862 msgid ""
7863 "Since the standard input of a command opened for reading shares its seek "
7864 "offset with the process that called B<popen>(), if the original process has "
7865 "done a buffered read, the command's input position may not be as expected.  "
7866 "Similarly, the output from a command opened for writing may become "
7867 "intermingled with that of the original process.  The latter can be avoided "
7868 "by calling B<fflush>(3)  before B<popen>()."
7869 msgstr ""
7870 "読み込みのために開かれたコマンドの標準入力は B<popen>(), を呼んだプロセスと一"
7871 "緒に、その読み取り位置を共有する。 そのため、もとのプロセスがバッファリングさ"
7872 "れた読み取りを終了したら、 そのコマンドの入力位置は予想されたものには なって"
7873 "いないかもしれない。 同様に、書き込みのために開かれたコマンドからの出力は、 "
7874 "もとのプロセスの出力と混ざり合うことになるかもしれない。 後者は B<popen>()  "
7875 "の前に B<fflush>(3)  を呼び出すことによって回避可能である。"
7876
7877 #.  .SH HISTORY
7878 #.  A
7879 #.  .BR popen ()
7880 #.  and a
7881 #.  .BR pclose ()
7882 #.  function appeared in Version 7 AT&T UNIX.
7883 #. type: Plain text
7884 #: build/C/man3/popen.3:198
7885 msgid ""
7886 "Failure to execute the shell is indistinguishable from the shell's failure "
7887 "to execute command, or an immediate exit of the command.  The only hint is "
7888 "an exit status of 127."
7889 msgstr ""
7890 "シェルの実行の失敗は、 シェルがコマンドの実行に失敗したことや、 コマンドがす"
7891 "ぐに終了してしまったことと、区別がつかない。 唯一のヒントは終了状態が 127 に"
7892 "なることである。"
7893
7894 #. type: Plain text
7895 #: build/C/man3/popen.3:208
7896 msgid ""
7897 "B<sh>(1), B<fork>(2), B<pipe>(2), B<wait4>(2), B<fclose>(3), B<fflush>(3), "
7898 "B<fopen>(3), B<stdio>(3), B<system>(3)"
7899 msgstr ""
7900 "B<sh>(1), B<fork>(2), B<pipe>(2), B<wait4>(2), B<fclose>(3), B<fflush>(3), "
7901 "B<fopen>(3), B<stdio>(3), B<system>(3)"
7902
7903 #. type: TH
7904 #: build/C/man3/printf.3:34
7905 #, no-wrap
7906 msgid "PRINTF"
7907 msgstr "PRINTF"
7908
7909 #. type: TH
7910 #: build/C/man3/printf.3:34
7911 #, no-wrap
7912 msgid "2013-03-05"
7913 msgstr "2013-03-05"
7914
7915 #. type: Plain text
7916 #: build/C/man3/printf.3:38
7917 msgid ""
7918 "printf, fprintf, sprintf, snprintf, vprintf, vfprintf, vsprintf, vsnprintf - "
7919 "formatted output conversion"
7920 msgstr ""
7921 "printf, fprintf, sprintf, snprintf, vprintf, vfprintf, vsprintf, vsnprintf - "
7922 "指定された書式に変換して出力を行う"
7923
7924 #. type: Plain text
7925 #: build/C/man3/printf.3:42
7926 msgid "B<int printf(const char *>I<format>B<, ...);>"
7927 msgstr "B<int printf(const char *>I<format>B<, ...);>"
7928
7929 #. type: Plain text
7930 #: build/C/man3/printf.3:44
7931 msgid "B<int fprintf(FILE *>I<stream>B<, const char *>I<format>B<, ...);>"
7932 msgstr "B<int fprintf(FILE *>I<stream>B<, const char *>I<format>B<, ...);>"
7933
7934 #. type: Plain text
7935 #: build/C/man3/printf.3:46
7936 msgid "B<int sprintf(char *>I<str>B<, const char *>I<format>B<, ...);>"
7937 msgstr "B<int sprintf(char *>I<str>B<, const char *>I<format>B<, ...);>"
7938
7939 #. type: Plain text
7940 #: build/C/man3/printf.3:48
7941 msgid ""
7942 "B<int snprintf(char *>I<str>B<, size_t >I<size>B<, const char "
7943 "*>I<format>B<, ...);>"
7944 msgstr ""
7945 "B<int snprintf(char *>I<str>B<, size_t >I<size>B<, const char "
7946 "*>I<format>B<, ...);>"
7947
7948 #. type: Plain text
7949 #: build/C/man3/printf.3:50
7950 msgid "B<#include E<lt>stdarg.hE<gt>>"
7951 msgstr "B<#include E<lt>stdarg.hE<gt>>"
7952
7953 #. type: Plain text
7954 #: build/C/man3/printf.3:52
7955 msgid "B<int vprintf(const char *>I<format>B<, va_list >I<ap>B<);>"
7956 msgstr "B<int vprintf(const char *>I<format>B<, va_list >I<ap>B<);>"
7957
7958 #. type: Plain text
7959 #: build/C/man3/printf.3:54
7960 msgid ""
7961 "B<int vfprintf(FILE *>I<stream>B<, const char *>I<format>B<, va_list "
7962 ">I<ap>B<);>"
7963 msgstr ""
7964 "B<int vfprintf(FILE *>I<stream>B<, const char *>I<format>B<, va_list "
7965 ">I<ap>B<);>"
7966
7967 #. type: Plain text
7968 #: build/C/man3/printf.3:56
7969 msgid ""
7970 "B<int vsprintf(char *>I<str>B<, const char *>I<format>B<, va_list >I<ap>B<);>"
7971 msgstr ""
7972 "B<int vsprintf(char *>I<str>B<, const char *>I<format>B<, va_list >I<ap>B<);>"
7973
7974 #. type: Plain text
7975 #: build/C/man3/printf.3:59
7976 msgid ""
7977 "B<int vsnprintf(char *>I<str>B<, size_t >I<size>B<, const char "
7978 "*>I<format>B<, va_list >I<ap>B<);>"
7979 msgstr ""
7980 "B<int vsnprintf(char *>I<str>B<, size_t >I<size>B<, const char "
7981 "*>I<format>B<, va_list >I<ap>B<);>"
7982
7983 #. type: Plain text
7984 #: build/C/man3/printf.3:68
7985 msgid "B<snprintf>(), B<vsnprintf>():"
7986 msgstr "B<snprintf>(), B<vsnprintf>():"
7987
7988 #. type: Plain text
7989 #: build/C/man3/printf.3:71
7990 msgid ""
7991 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _ISOC99_SOURCE || "
7992 "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L;"
7993 msgstr ""
7994 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _ISOC99_SOURCE || "
7995 "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L;"
7996
7997 #. type: Plain text
7998 #: build/C/man3/printf.3:74 build/C/man3/scanf.3:85
7999 msgid "or I<cc -std=c99>"
8000 msgstr "or I<cc -std=c99>"
8001
8002 #. type: Plain text
8003 #: build/C/man3/printf.3:101
8004 msgid ""
8005 "The functions in the B<printf>()  family produce output according to a "
8006 "I<format> as described below.  The functions B<printf>()  and B<vprintf>()  "
8007 "write output to I<stdout>, the standard output stream; B<fprintf>()  and "
8008 "B<vfprintf>()  write output to the given output I<stream>; B<sprintf>(), "
8009 "B<snprintf>(), B<vsprintf>()  and B<vsnprintf>()  write to the character "
8010 "string I<str>."
8011 msgstr ""
8012 "B<printf>()  関数グループは、以下で述べるように、 I<format> に従って出力を生"
8013 "成するものである。 B<printf>()  と B<vprintf>()  は出力を I<stdout> (標準出力"
8014 "ストリーム) に書き出す。 B<fprintf>()  と B<vfprintf>()  は出力を指定された出"
8015 "力 I<stream> に書き出す。 B<sprintf>(), B<snprintf>(), B<vsprintf>(), "
8016 "B<vsnprintf>()  は出力を文字列 I<str> に書き込む。"
8017
8018 #. type: Plain text
8019 #: build/C/man3/printf.3:110
8020 msgid ""
8021 "The functions B<snprintf>()  and B<vsnprintf>()  write at most I<size> bytes "
8022 "(including the terminating null byte (\\(aq\\e0\\(aq)) to I<str>."
8023 msgstr ""
8024 "B<snprintf>()  と B<vsnprintf>()  は最大で I<size> バイトを I<str> に書き込"
8025 "む (I<size> には文字列を終端する NULL バイト (\\(aq\\e0\\(aq) もを含まれる)。"
8026
8027 #. type: Plain text
8028 #: build/C/man3/printf.3:134
8029 msgid ""
8030 "The functions B<vprintf>(), B<vfprintf>(), B<vsprintf>(), B<vsnprintf>()  "
8031 "are equivalent to the functions B<printf>(), B<fprintf>(), B<sprintf>(), "
8032 "B<snprintf>(), respectively, except that they are called with a I<va_list> "
8033 "instead of a variable number of arguments.  These functions do not call the "
8034 "I<va_end> macro.  Because they invoke the I<va_arg> macro, the value of "
8035 "I<ap> is undefined after the call.  See B<stdarg>(3)."
8036 msgstr ""
8037 "B<vprintf>(), B<vfprintf>(), B<vsprintf>(), B<vsnprintf>()  の各関数はそれぞ"
8038 "れ B<printf>(), B<fprintf>(), B<sprintf>(), B<snprintf>(), の各関数と等価であ"
8039 "り、可変数引き数の代わりに I<va_list> を引き数として呼び出される点だけが異な"
8040 "る。 これらの関数では I<va_end> マクロは呼び出されない。 これらの関数は "
8041 "I<va_arg> を呼び出すので、呼び出し後の I<ap> の値は未定義である。 B<stdarg>"
8042 "(3)  を参照のこと。"
8043
8044 #. type: Plain text
8045 #: build/C/man3/printf.3:141
8046 msgid ""
8047 "These eight functions write the output under the control of a I<format> "
8048 "string that specifies how subsequent arguments (or arguments accessed via "
8049 "the variable-length argument facilities of B<stdarg>(3))  are converted for "
8050 "output."
8051 msgstr ""
8052 "これらの 8 つの関数は I<format> 文字列の制御に従って出力を書き出す。 "
8053 "I<format> 文字列は、これに続く引き数 (または B<stdarg>(3)  の可変長引き数機構"
8054 "を使ってアクセスできる引き数)  をどのように変換して出力するかを指定する。"
8055
8056 #. type: Plain text
8057 #: build/C/man3/printf.3:152
8058 msgid ""
8059 "C99 and POSIX.1-2001 specify that the results are undefined if a call to "
8060 "B<sprintf>(), B<snprintf>(), B<vsprintf>(), or B<vsnprintf>()  would cause "
8061 "copying to take place between objects that overlap (e.g., if the target "
8062 "string array and one of the supplied input arguments refer to the same "
8063 "buffer).  See NOTES."
8064 msgstr ""
8065 "C99 と POSIX.1-2001 では、 B<sprintf>(), B<snprintf>(), B<vsprintf>(), "
8066 "B<vsnprintf>()  の呼び出しで、範囲が重複するオブジェクト間でコピーが発生する"
8067 "場合の 結果は不定であると規定されている (例えば、出力先の文字列と入力された "
8068 "引き数の一つが同じバッファを参照している場合などである)。 「注意」の節を参"
8069 "照。"
8070
8071 #. type: SS
8072 #: build/C/man3/printf.3:152
8073 #, no-wrap
8074 msgid "Return value"
8075 msgstr "Return Values"
8076
8077 #. type: Plain text
8078 #: build/C/man3/printf.3:155
8079 msgid ""
8080 "Upon successful return, these functions return the number of characters "
8081 "printed (excluding the null byte used to end output to strings)."
8082 msgstr ""
8083 "成功時には、上記の関数は書き込まれた文字数を返す (文字列の最後を示すために使"
8084 "用する NULL バイトは数に含まれない)。"
8085
8086 #. type: Plain text
8087 #: build/C/man3/printf.3:171
8088 msgid ""
8089 "The functions B<snprintf>()  and B<vsnprintf>()  do not write more than "
8090 "I<size> bytes (including the terminating null byte (\\(aq\\e0\\(aq)).  If "
8091 "the output was truncated due to this limit then the return value is the "
8092 "number of characters (excluding the terminating null byte)  which would have "
8093 "been written to the final string if enough space had been available.  Thus, "
8094 "a return value of I<size> or more means that the output was truncated.  (See "
8095 "also below under NOTES.)"
8096 msgstr ""
8097 "B<snprintf>()  と B<vsnprintf>()  は、 I<size> バイトを越える文字数を書き込ま"
8098 "ない (I<size> には文字列を終端する NULL バイト (\\(aq\\e0\\(aq) も含まれ"
8099 "る)。 この制限によって出力が切り詰められた場合には、 もし十分なスペースがあれ"
8100 "ば書き込まれたであろう文字の個数 (文字列を終端する NULL バイトを除く) を返"
8101 "す。 従って、返り値が I<size> 以上だった場合、出力が切り詰められたことを意味"
8102 "する (後述の注意も参照のこと)。"
8103
8104 #. type: Plain text
8105 #: build/C/man3/printf.3:173
8106 msgid "If an output error is encountered, a negative value is returned."
8107 msgstr "エラーが発生した場合は、負の数を返す。"
8108
8109 #. type: SS
8110 #: build/C/man3/printf.3:173
8111 #, no-wrap
8112 msgid "Format of the format string"
8113 msgstr "フォーマット文字列のフォーマット"
8114
8115 #. type: Plain text
8116 #: build/C/man3/printf.3:195
8117 msgid ""
8118 "The format string is a character string, beginning and ending in its initial "
8119 "shift state, if any.  The format string is composed of zero or more "
8120 "directives: ordinary characters (not B<%>), which are copied unchanged to "
8121 "the output stream; and conversion specifications, each of which results in "
8122 "fetching zero or more subsequent arguments.  Each conversion specification "
8123 "is introduced by the character B<%>, and ends with a I<conversion "
8124 "specifier>.  In between there may be (in this order) zero or more I<flags>, "
8125 "an optional minimum I<field width>, an optional I<precision> and an optional "
8126 "I<length modifier>."
8127 msgstr ""
8128 "フォーマット文字列は文字の列で、 (もしあるなら) 初期シフト状態で始まり、初期"
8129 "シフト状態で終わる。 フォーマット用の文字列は 0 個以上の命令 (directives) に"
8130 "よって構成される。 命令には、通常文字と変換指定 (conversion specifications) "
8131 "がある。 通常文字は B<%> 以外の文字で、出力ストリームにそのままコピーされ"
8132 "る。 変換指定は、それぞれが 0 個以上の引き数を取る。 各変換指定は文字 B<%> で"
8133 "始まり、 I<変換指定子 (conversion specifier)> で終わる。 B<%> と変換指定子の"
8134 "間には、0 個以上の I<フラグ 、> 最小 I<フィールド幅 、> I<精度 、> I<長さ修飾"
8135 "子> を (この順序で) 置くことができる。"
8136
8137 #. type: Plain text
8138 #: build/C/man3/printf.3:208
8139 msgid ""
8140 "The arguments must correspond properly (after type promotion) with the "
8141 "conversion specifier.  By default, the arguments are used in the order "
8142 "given, where each \\(aq*\\(aq and each conversion specifier asks for the "
8143 "next argument (and it is an error if insufficiently many arguments are "
8144 "given).  One can also specify explicitly which argument is taken, at each "
8145 "place where an argument is required, by writing \"%m$\" instead of \\(aq%"
8146 "\\(aq and \"*m$\" instead of \\(aq*\\(aq, where the decimal integer m "
8147 "denotes the position in the argument list of the desired argument, indexed "
8148 "starting from 1.  Thus,"
8149 msgstr ""
8150 "引き数は (型の格上げの後は) 変換指定子が表す型と正確に対応しなければならな"
8151 "い。 デフォルトでは、\\(aq*\\(aq や変換指定子が出てくる毎に次の引き数を要求さ"
8152 "れ、 引き数は指定された順序で使用されていく (指定された引き数の個数が不十分な"
8153 "らエラーとなる)。 また、引き数が必要な箇所で \\(aq%\\(aq の代わりに \"%m$"
8154 "\"、 \\(aq*\\(aqの代わりに \"*m$\" と書くことで、 明示的にどの引き数を使用す"
8155 "るかを指定することもできる。 ここで 10進の整数 m は希望の引き数の引き数リスト"
8156 "での位置を示す (最初の引き数の番号が 1 である)。 従って、"
8157
8158 #. type: Plain text
8159 #: build/C/man3/printf.3:212
8160 #, no-wrap
8161 msgid "printf(\"%*d\", width, num);\n"
8162 msgstr "printf(\"%*d\", width, num);\n"
8163
8164 #. type: Plain text
8165 #: build/C/man3/printf.3:216
8166 msgid "and"
8167 msgstr "と"
8168
8169 #. type: Plain text
8170 #: build/C/man3/printf.3:220
8171 #, no-wrap
8172 msgid "printf(\"%2$*1$d\", width, num);\n"
8173 msgstr "printf(\"%2$*1$d\", width, num);\n"
8174
8175 #. type: Plain text
8176 #: build/C/man3/printf.3:236
8177 msgid ""
8178 "are equivalent.  The second style allows repeated references to the same "
8179 "argument.  The C99 standard does not include the style using \\(aq$\\(aq, "
8180 "which comes from the Single UNIX Specification.  If the style using \\(aq$"
8181 "\\(aq is used, it must be used throughout for all conversions taking an "
8182 "argument and all width and precision arguments, but it may be mixed with \"%%"
8183 "\" formats which do not consume an argument.  There may be no gaps in the "
8184 "numbers of arguments specified using \\(aq$\\(aq; for example, if arguments "
8185 "1 and 3 are specified, argument 2 must also be specified somewhere in the "
8186 "format string."
8187 msgstr ""
8188 "は等価である。 二番目の書き方では同じ引き数を繰り返し参照することができる。 "
8189 "C99 標準には、 Single UNIX Specification 由来の \\(aq$\\(aq を使った書き方は"
8190 "含まれていない。 \\(aq$\\(aq を使ったスタイルを使うと、引き数を取る変換及び幅"
8191 "と精度の引き数を 全てこのスタイルで指定しなければならないが、 引き数を消費し"
8192 "ない \"%%\" フォーマットと混ざっているかもしれない。 \\(aq$\\(aq で指定される"
8193 "引き数の番号に空きがあってはならない。 例えば、もし引き数 1 と 3 が指定される"
8194 "と、引き数 2 もフォーマット文字列のどこかで 指定されなければならない。"
8195
8196 #. type: Plain text
8197 #: build/C/man3/printf.3:246
8198 msgid ""
8199 "For some numeric conversions a radix character (\"decimal point\") or "
8200 "thousands' grouping character is used.  The actual character used depends on "
8201 "the B<LC_NUMERIC> part of the locale.  The POSIX locale uses \\(aq.\\(aq as "
8202 "radix character, and does not have a grouping character.  Thus,"
8203 msgstr ""
8204 "数値変換には小数点や 1000 単位の区切り文字を使うものもある。 実際にどの文字を"
8205 "使うかはロケールの B<LC_NUMERIC> による。 POSIX ロケールでは小数点に \\(aq."
8206 "\\(aq を用い、 区切り文字は使わない。 従って、"
8207
8208 #. type: Plain text
8209 #: build/C/man3/printf.3:250
8210 #, no-wrap
8211 msgid "    printf(\"%\\(aq.2f\", 1234567.89);\n"
8212 msgstr "printf(\"%\\(aq.2f\", 1234567.89);\n"
8213
8214 #. type: Plain text
8215 #: build/C/man3/printf.3:255
8216 msgid ""
8217 "results in \"1234567.89\" in the POSIX locale, in \"1234567,89\" in the "
8218 "nl_NL locale, and in \"1.234.567,89\" in the da_DK locale."
8219 msgstr ""
8220 "は、 POSIX ロケールでは \"1234567.89\" 、 nl_NL ロケールでは "
8221 "\"1234567,89\"、 da_DK ロケールでは \"1.234.567,89\" となる。"
8222
8223 #. type: SS
8224 #: build/C/man3/printf.3:255
8225 #, no-wrap
8226 msgid "The flag characters"
8227 msgstr "フラグ文字"
8228
8229 #. type: Plain text
8230 #: build/C/man3/printf.3:257
8231 msgid "The character % is followed by zero or more of the following flags:"
8232 msgstr "% 文字の後ろには 0 個以上のフラグ文字が続く。"
8233
8234 #. type: TP
8235 #: build/C/man3/printf.3:257
8236 #, no-wrap
8237 msgid "B<#>"
8238 msgstr "B<#>"
8239
8240 #. type: Plain text
8241 #: build/C/man3/printf.3:291
8242 msgid ""
8243 "The value should be converted to an \"alternate form\".  For B<o> "
8244 "conversions, the first character of the output string is made zero (by "
8245 "prefixing a 0 if it was not zero already).  For B<x> and B<X> conversions, a "
8246 "nonzero result has the string \"0x\" (or \"0X\" for B<X> conversions) "
8247 "prepended to it.  For B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, and B<G> "
8248 "conversions, the result will always contain a decimal point, even if no "
8249 "digits follow it (normally, a decimal point appears in the results of those "
8250 "conversions only if a digit follows).  For B<g> and B<G> conversions, "
8251 "trailing zeros are not removed from the result as they would otherwise be.  "
8252 "For other conversions, the result is undefined."
8253 msgstr ""
8254 "値は「別の形式」に変換される。 B<o> 変換の場合、(先頭文字が 0 になっていない"
8255 "場合に先頭に 0 を追加することで)  出力文字列の最初の文字を 0 にする。 B<x> "
8256 "と B<X> 変換の場合、数値が 0 でないときには文字列 \"0x\" (B<X> 変換の場合に"
8257 "は \"0X\") が前に付与される。 B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, B<G> "
8258 "変換では、 小数点に続く数字がなくても、 出力には常に小数点が含まれる (通常"
8259 "は、小数点の後に数字が続く場合にのみ、 小数点が表示される)。 B<g> と B<G> 変"
8260 "換の場合、他の変換とは異なり、末尾のゼロが変換結果から削除されない。 その他の"
8261 "変換では、結果は未定義である。"
8262
8263 #. type: TP
8264 #: build/C/man3/printf.3:291
8265 #, no-wrap
8266 msgid "B<\\&0>"
8267 msgstr "B<\\&0>"
8268
8269 #. type: Plain text
8270 #: build/C/man3/printf.3:331
8271 msgid ""
8272 "The value should be zero padded.  For B<d>, B<i>, B<o>, B<u>, B<x>, B<X>, "
8273 "B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, and B<G> conversions, the "
8274 "converted value is padded on the left with zeros rather than blanks.  If the "
8275 "B<\\&0> and B<-> flags both appear, the B<\\&0> flag is ignored.  If a "
8276 "precision is given with a numeric conversion (B<d>, B<i>, B<o>, B<u>, B<x>, "
8277 "and B<X>), the B<\\&0> flag is ignored.  For other conversions, the behavior "
8278 "is undefined."
8279 msgstr ""
8280 "値をゼロで埋める。 B<d>, B<i>, B<o>, B<u>, B<x>, B<X>, B<a>, B<A>, B<e>, "
8281 "B<E>, B<f>, B<F>, B<g>, B<G> 変換では、変換した値の左側を空白文字の代わりにゼ"
8282 "ロで埋める。 B<\\&0> と B<-> が両方とも指定された場合は、 B<\\&0> フラグは無"
8283 "視される。 精度が数値変換 (B<d>, B<i>, B<o>, B<u>, B<x>, B<X>)  と同時に指定"
8284 "された場合には、 B<\\&0> フラグは無視される。 その他の変換では、動作は未定義"
8285 "である。"
8286
8287 #. type: TP
8288 #: build/C/man3/printf.3:331
8289 #, no-wrap
8290 msgid "B<->"
8291 msgstr "B<->"
8292
8293 #. type: Plain text
8294 #: build/C/man3/printf.3:344
8295 msgid ""
8296 "The converted value is to be left adjusted on the field boundary.  (The "
8297 "default is right justification.)  Except for B<n> conversions, the converted "
8298 "value is padded on the right with blanks, rather than on the left with "
8299 "blanks or zeros.  A B<-> overrides a B<\\&0> if both are given."
8300 msgstr ""
8301 "変換値をフィールド境界で左揃えにする (デフォルトは右揃えである)。 B<n> 変換以"
8302 "外では、変換された値は 左側ではなく右側を空白文字やゼロで埋められる。 B<-> "
8303 "と B<\\&0> の両方が指定された場合には、 B<-> が優先される。"
8304
8305 #. type: TP
8306 #: build/C/man3/printf.3:344
8307 #, no-wrap
8308 msgid "B<\\(aq \\(aq>"
8309 msgstr "B<' '>"
8310
8311 #. type: Plain text
8312 #: build/C/man3/printf.3:348
8313 msgid ""
8314 "(a space) A blank should be left before a positive number (or empty string) "
8315 "produced by a signed conversion."
8316 msgstr ""
8317 "(1個の半角スペース)  符号付き変換で生成された正の数字の前に空白 (または空文字"
8318 "列) が置かれる。"
8319
8320 #. type: TP
8321 #: build/C/man3/printf.3:348
8322 #, no-wrap
8323 msgid "B<+>"
8324 msgstr "B<+>"
8325
8326 #. type: Plain text
8327 #: build/C/man3/printf.3:356
8328 msgid ""
8329 "A sign (+ or -) should always be placed before a number produced by a signed "
8330 "conversion.  By default a sign is used only for negative numbers.  A B<+> "
8331 "overrides a space if both are used."
8332 msgstr ""
8333 "符号付き変換によって出力される数字の前に、常に符号 (+ か -) が置かれる。 デ"
8334 "フォルトでは、符号は負の数字の場合のみ付与される。 B<+> と半角スペースの 両方"
8335 "が使われている場合には、 B<+> が優先される。"
8336
8337 #. type: Plain text
8338 #: build/C/man3/printf.3:359
8339 msgid ""
8340 "The five flag characters above are defined in the C standard.  The SUSv2 "
8341 "specifies one further flag character."
8342 msgstr ""
8343 "上記の 5 つのフラグは C 標準で定義されている。 SUSv2 では、さらにもう一つフラ"
8344 "グ文字が規定されている。"
8345
8346 #. type: TP
8347 #: build/C/man3/printf.3:359
8348 #, no-wrap
8349 msgid "B<\\(aq>"
8350 msgstr "B<\\(aq>"
8351
8352 #. type: Plain text
8353 #: build/C/man3/printf.3:376
8354 msgid ""
8355 "For decimal conversion (B<i>, B<d>, B<u>, B<f>, B<F>, B<g>, B<G>)  the "
8356 "output is to be grouped with thousands' grouping characters if the locale "
8357 "information indicates any.  Note that many versions of B<gcc>(1)  cannot "
8358 "parse this option and will issue a warning.  SUSv2 does not include I<%"
8359 "\\(aqF>."
8360 msgstr ""
8361 "10進数変換 (B<i>, B<d>, B<u>, B<f>, B<F>, B<g>, B<G>)  において、ロケール情報"
8362 "に指定があれば 1000 単位の区切り文字を出力する。 B<gcc>(1)  の多くのバージョ"
8363 "ンは、このオプションを解釈することができず、 警告を出力することに注意せよ。 %"
8364 "\\(aqF は SUSv2 には含まれていない。"
8365
8366 #. type: Plain text
8367 #: build/C/man3/printf.3:378
8368 msgid "glibc 2.2 adds one further flag character."
8369 msgstr "glibc 2.2 では、さらに一つフラグ文字が追加されている。"
8370
8371 #. type: TP
8372 #: build/C/man3/printf.3:378
8373 #, no-wrap
8374 msgid "B<I>"
8375 msgstr "B<I>"
8376
8377 #.  outdigits keyword in locale file
8378 #. type: Plain text
8379 #: build/C/man3/printf.3:388
8380 msgid ""
8381 "For decimal integer conversion (B<i>, B<d>, B<u>)  the output uses the "
8382 "locale's alternative output digits, if any.  For example, since glibc 2.2.3 "
8383 "this will give Arabic-Indic digits in the Persian (\"fa_IR\") locale."
8384 msgstr ""
8385 "10進整数変換 (B<i>, B<d>, B<u>)  において、ロケールの代替出力数字があれば、そ"
8386 "れを用いて出力する。 例えば、 glibc 2.2.3 以降では、ペルシア (\"fa_IR\") ロ"
8387 "ケールで アラビア数字 (Arabic-Indic digits) を出力できる。"
8388
8389 #. type: SS
8390 #: build/C/man3/printf.3:388
8391 #, no-wrap
8392 msgid "The field width"
8393 msgstr "フィールド幅"
8394
8395 #. type: Plain text
8396 #: build/C/man3/printf.3:404
8397 msgid ""
8398 "An optional decimal digit string (with nonzero first digit) specifying a "
8399 "minimum field width.  If the converted value has fewer characters than the "
8400 "field width, it will be padded with spaces on the left (or right, if the "
8401 "left-adjustment flag has been given).  Instead of a decimal digit string one "
8402 "may write \"*\" or \"*m$\" (for some decimal integer I<m>) to specify that "
8403 "the field width is given in the next argument, or in the I<m>-th argument, "
8404 "respectively, which must be of type I<int>.  A negative field width is taken "
8405 "as a \\(aq-\\(aq flag followed by a positive field width.  In no case does a "
8406 "nonexistent or small field width cause truncation of a field; if the result "
8407 "of a conversion is wider than the field width, the field is expanded to "
8408 "contain the conversion result."
8409 msgstr ""
8410 "最小のフィールド幅を指定する 10進数の数値文字列 (文字列の最初の文字は ゼロ以"
8411 "外)。本項目はオプションである。 変換された値の文字数がフィールド長よりも少な"
8412 "い場合、 フィールドの左側をスペースで埋める (左揃えのフラグがある場合は右側を"
8413 "埋める)。 10進数の文字列の代わりに \"*\" や \"*m$\" (I<m> は 10進整数) を書く"
8414 "こともできる。 \"*\" と \"*m$\" はそれぞれ、次の引き数と I<m> 番目の引き数を"
8415 "フィールド幅として 使うことを指定する (これらの引き数は I<int> 型でなければな"
8416 "らない)。 フィールド幅に負の数が指定された場合は、 \\(aq-\\(aq フラグと正の数"
8417 "のフィールド幅として扱われる。 フィールド幅が小さかったり指定がなかったりして"
8418 "も、フィールドが切り詰められる ことはない。もし変換結果がフィールド幅よりも広"
8419 "かった場合、 フィールドは変換結果が入る幅に広げられる。"
8420
8421 #. type: SS
8422 #: build/C/man3/printf.3:404
8423 #, no-wrap
8424 msgid "The precision"
8425 msgstr "精度"
8426
8427 #. type: Plain text
8428 #: build/C/man3/printf.3:440
8429 msgid ""
8430 "An optional precision, in the form of a period (\\(aq.\\(aq)  followed by an "
8431 "optional decimal digit string.  Instead of a decimal digit string one may "
8432 "write \"*\" or \"*m$\" (for some decimal integer m) to specify that the "
8433 "precision is given in the next argument, or in the m-th argument, "
8434 "respectively, which must be of type I<int>.  If the precision is given as "
8435 "just \\(aq.\\(aq, or the precision is negative, the precision is taken to be "
8436 "zero.  This gives the minimum number of digits to appear for B<d>, B<i>, "
8437 "B<o>, B<u>, B<x>, and B<X> conversions, the number of digits to appear after "
8438 "the radix character for B<a>, B<A>, B<e>, B<E>, B<f>, and B<F> conversions, "
8439 "the maximum number of significant digits for B<g> and B<G> conversions, or "
8440 "the maximum number of characters to be printed from a string for B<s> and "
8441 "B<S> conversions."
8442 msgstr ""
8443 "オプションである精度は、ピリオド (\\(aq.\\(aq) とそれに続く10進数という 形式"
8444 "で指定する (10進数はオプション) 。 10進数の文字列の代わりに \"*\" や \"*m$"
8445 "\" (m は 10 進整数)を書くこともできる。 \"*\" と \"*m$\" はそれぞれ、次の引き"
8446 "数と m 番目の引き数を精度として 使うことを指定する (これらの引き数は I<int> "
8447 "型でなければならない)。 精度として \\(aq.\\(aq だけが指定されたり、精度が負の"
8448 "数だった場合、 精度はゼロとみなされる。 B<d>, B<i>, B<o>, B<u>, B<x>, B<X> 変"
8449 "換では、表示される最小の桁数を指定する。 B<a>, B<A>, B<e>, B<E>, B<f>, B<F> "
8450 "変換では、小数点以下に表示される数字の桁数を指定する。 B<g> と B<G> 変換で"
8451 "は、有効数字の最大桁数を指定する。 B<s> と B<S> 変換では、文字列から出力され"
8452 "る最大文字数を指定する。"
8453
8454 #. type: SS
8455 #: build/C/man3/printf.3:440
8456 #, no-wrap
8457 msgid "The length modifier"
8458 msgstr "長さ修飾子"
8459
8460 #. type: Plain text
8461 #: build/C/man3/printf.3:450
8462 msgid ""
8463 "Here, \"integer conversion\" stands for B<d>, B<i>, B<o>, B<u>, B<x>, or "
8464 "B<X> conversion."
8465 msgstr ""
8466 "「整数変換」とは、 B<d>, B<i>, B<o>, B<u>, B<x>, B<X> 変換のことである。"
8467
8468 #. type: TP
8469 #: build/C/man3/printf.3:450 build/C/man3/scanf.3:294
8470 #, no-wrap
8471 msgid "B<hh>"
8472 msgstr "B<hh>"
8473
8474 #. type: Plain text
8475 #: build/C/man3/printf.3:461
8476 msgid ""
8477 "A following integer conversion corresponds to a I<signed char> or I<unsigned "
8478 "char> argument, or a following B<n> conversion corresponds to a pointer to a "
8479 "I<signed char> argument."
8480 msgstr ""
8481 "整数変換に対応する引き数が I<signed char> か I<unsigned char> で、 B<n> 変換"
8482 "に対応する引き数が I<signed char> へのポインタであることを示す。"
8483
8484 #. type: TP
8485 #: build/C/man3/printf.3:461 build/C/man3/scanf.3:284
8486 #, no-wrap
8487 msgid "B<h>"
8488 msgstr "B<h>"
8489
8490 #. type: Plain text
8491 #: build/C/man3/printf.3:472
8492 msgid ""
8493 "A following integer conversion corresponds to a I<short int> or I<unsigned "
8494 "short int> argument, or a following B<n> conversion corresponds to a pointer "
8495 "to a I<short int> argument."
8496 msgstr ""
8497 "整数変換に対応する引き数が I<short int> か I<unsigned short int> で、 B<n> 変"
8498 "換に対応する引き数が I<short int> へのポインタであることを示す。"
8499
8500 #. type: TP
8501 #: build/C/man3/printf.3:472 build/C/man3/scanf.3:311
8502 #, no-wrap
8503 msgid "B<l>"
8504 msgstr "B<l>"
8505
8506 #. type: Plain text
8507 #: build/C/man3/printf.3:491
8508 msgid ""
8509 "(ell) A following integer conversion corresponds to a I<long int> or "
8510 "I<unsigned long int> argument, or a following B<n> conversion corresponds to "
8511 "a pointer to a I<long int> argument, or a following B<c> conversion "
8512 "corresponds to a I<wint_t> argument, or a following B<s> conversion "
8513 "corresponds to a pointer to I<wchar_t> argument."
8514 msgstr ""
8515 "各変換に対応する引き数が、 整数変換では I<long int>か I<unsigned long int>、 "
8516 "B<n> 変換では I<long long int> へのポインタ、 B<c> 変換では I<wint_t>、 B<s> "
8517 "変換では I<wchar_t> へのポインタであることを示す。"
8518
8519 #. type: TP
8520 #: build/C/man3/printf.3:491
8521 #, no-wrap
8522 msgid "B<ll>"
8523 msgstr "B<ll> (エルエル)"
8524
8525 #. type: Plain text
8526 #: build/C/man3/printf.3:503
8527 msgid ""
8528 "(ell-ell).  A following integer conversion corresponds to a I<long long int> "
8529 "or I<unsigned long long int> argument, or a following B<n> conversion "
8530 "corresponds to a pointer to a I<long long int> argument."
8531 msgstr ""
8532 "整数変換に対応する引き数が I<long long int> か I<unsigned long long int> "
8533 "で、 B<n> 変換に対応する引き数が I<long int> へのポインタであることを示す。"
8534
8535 #. type: TP
8536 #: build/C/man3/printf.3:503 build/C/man3/scanf.3:338
8537 #, no-wrap
8538 msgid "B<L>"
8539 msgstr "B<L>"
8540
8541 #. type: Plain text
8542 #: build/C/man3/printf.3:519
8543 msgid ""
8544 "A following B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, or B<G> conversion "
8545 "corresponds to a I<long double> argument.  (C99 allows %LF, but SUSv2 does "
8546 "not.)"
8547 msgstr ""
8548 "B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, B<G> 変換に対応する引き数が I<long "
8549 "double> であることを示す。 (C99 では %LF を使うことを認めているが、SUSv2 では"
8550 "認められていない。)"
8551
8552 #. type: TP
8553 #: build/C/man3/printf.3:519 build/C/man3/scanf.3:354
8554 #, no-wrap
8555 msgid "B<q>"
8556 msgstr "B<q>"
8557
8558 #. type: Plain text
8559 #: build/C/man3/printf.3:525
8560 msgid ""
8561 "(\"quad\". 4.4BSD and Linux libc5 only.  Don't use.)  This is a synonym for "
8562 "B<ll>."
8563 msgstr ""
8564 "(\"quad\"。 4.4BSD と Linux libc5 のみ有効。使ってはならない。)  B<ll> と同じ"
8565 "意味である。"
8566
8567 #. type: TP
8568 #: build/C/man3/printf.3:525 build/C/man3/scanf.3:302
8569 #, no-wrap
8570 msgid "B<j>"
8571 msgstr "B<j>"
8572
8573 #. type: Plain text
8574 #: build/C/man3/printf.3:532
8575 msgid ""
8576 "A following integer conversion corresponds to an I<intmax_t> or I<uintmax_t> "
8577 "argument."
8578 msgstr ""
8579 "整数変換に対応する引き数が I<intmax_t> か I<uintmax_t> であることを示す。"
8580
8581 #. type: TP
8582 #: build/C/man3/printf.3:532 build/C/man3/scanf.3:366
8583 #, no-wrap
8584 msgid "B<z>"
8585 msgstr "B<z>"
8586
8587 #. type: Plain text
8588 #: build/C/man3/printf.3:543
8589 msgid ""
8590 "A following integer conversion corresponds to a I<size_t> or I<ssize_t> "
8591 "argument.  (Linux libc5 has B<Z> with this meaning.  Don't use it.)"
8592 msgstr ""
8593 "整数変換に対応する引き数が I<size_t> か I<ssize_t> であることを示す。 (Linux "
8594 "libc5 では、これを指定するのに B<Z> を用いる。使ってはならない。)"
8595
8596 #. type: TP
8597 #: build/C/man3/printf.3:543 build/C/man3/scanf.3:359
8598 #, no-wrap
8599 msgid "B<t>"
8600 msgstr "B<t>"
8601
8602 #. type: Plain text
8603 #: build/C/man3/printf.3:548
8604 msgid "A following integer conversion corresponds to a I<ptrdiff_t> argument."
8605 msgstr "整数変換に対応する引き数が I<ptrdiff_t> であることを示す。"
8606
8607 #. type: Plain text
8608 #: build/C/man3/printf.3:577
8609 #, fuzzy
8610 #| msgid ""
8611 #| "The SUSv2 only knows about the length modifiers B<h> (in B<hd>, B<hi>, "
8612 #| "B<ho>, B<hx>, B<hX>, B<hn>)  and B<l> (in B<ld>, B<li>, B<lo>, B<lx>, "
8613 #| "B<lX>, B<ln>, B<lc>, B<ls>)  and B<L> (in B<Le>, B<LE>, B<Lf>, B<Lg>, "
8614 #| "B<LG>)."
8615 msgid ""
8616 "The SUSv2 knows about only the length modifiers B<h> (in B<hd>, B<hi>, "
8617 "B<ho>, B<hx>, B<hX>, B<hn>)  and B<l> (in B<ld>, B<li>, B<lo>, B<lx>, B<lX>, "
8618 "B<ln>, B<lc>, B<ls>)  and B<L> (in B<Le>, B<LE>, B<Lf>, B<Lg>, B<LG>)."
8619 msgstr ""
8620 "SUSv2 で長さ修飾子として使用できるのは、 B<h> (B<hd>, B<hi>, B<ho>, B<hx>, "
8621 "B<hX>, B<hn>), B<l> (B<ld>, B<li>, B<lo>, B<lx>, B<lX>, B<ln>, B<lc>, "
8622 "B<ls>), B<L> (B<Le>, B<LE>, B<Lf>, B<Lg>, B<LG>)  だけである。"
8623
8624 #. type: SS
8625 #: build/C/man3/printf.3:577
8626 #, no-wrap
8627 msgid "The conversion specifier"
8628 msgstr "変換指定子"
8629
8630 #. type: Plain text
8631 #: build/C/man3/printf.3:580
8632 msgid ""
8633 "A character that specifies the type of conversion to be applied.  The "
8634 "conversion specifiers and their meanings are:"
8635 msgstr ""
8636 "適用される変換の型を指定する文字。 変換指定子とその意味は以下の通りである。"
8637
8638 #. type: TP
8639 #: build/C/man3/printf.3:580
8640 #, no-wrap
8641 msgid "B<d>, B<i>"
8642 msgstr "B<d>, B<i>"
8643
8644 #. type: Plain text
8645 #: build/C/man3/printf.3:590
8646 msgid ""
8647 "The I<int> argument is converted to signed decimal notation.  The precision, "
8648 "if any, gives the minimum number of digits that must appear; if the "
8649 "converted value requires fewer digits, it is padded on the left with zeros.  "
8650 "The default precision is 1.  When 0 is printed with an explicit precision 0, "
8651 "the output is empty."
8652 msgstr ""
8653 "I<int> 引き数を符号付き 10 進表記に変換する。 精度指定があれば、精度で指定し"
8654 "た桁数は必ず出力される。変換後の値が 指定された桁数に足りない場合は、左側が "
8655 "0 で埋められる。 デフォルトの精度は 1 である。 0 を表示しようとした時に、明示"
8656 "的に精度として 0 が指定されていると、 出力は空文字列となる。"
8657
8658 #. type: TP
8659 #: build/C/man3/printf.3:590
8660 #, no-wrap
8661 msgid "B<o>, B<u>, B<x>, B<X>"
8662 msgstr "B<o>, B<u>, B<x>, B<X>"
8663
8664 #. type: Plain text
8665 #: build/C/man3/printf.3:617
8666 msgid ""
8667 "The I<unsigned int> argument is converted to unsigned octal (B<o>), unsigned "
8668 "decimal (B<u>), or unsigned hexadecimal (B<x> and B<X>)  notation.  The "
8669 "letters B<abcdef> are used for B<x> conversions; the letters B<ABCDEF> are "
8670 "used for B<X> conversions.  The precision, if any, gives the minimum number "
8671 "of digits that must appear; if the converted value requires fewer digits, it "
8672 "is padded on the left with zeros.  The default precision is 1.  When 0 is "
8673 "printed with an explicit precision 0, the output is empty."
8674 msgstr ""
8675 "I<unsigned int> 引き数を、 符号なし8進数 (B<o>), 符号なし10進数 (B<u>), 符号"
8676 "なし16進数 (B<x> と B<X>)  に変換する。 B<x> 変換では B<abcdef> が使用され、 "
8677 "B<X> 変換では B<ABCDEF> が使用される。 精度指定があれば、精度で指定した桁数は"
8678 "必ず出力される。変換後の値が 指定された桁数に足りない場合は、左側が 0 で埋め"
8679 "られる。"
8680
8681 #. type: TP
8682 #: build/C/man3/printf.3:617
8683 #, no-wrap
8684 msgid "B<e>, B<E>"
8685 msgstr "B<e>, B<E>"
8686
8687 #. type: Plain text
8688 #: build/C/man3/printf.3:636
8689 msgid ""
8690 "The I<double> argument is rounded and converted in the style [-]dB<\\&."
8691 ">dddB<e>\\(+-dd where there is one digit before the decimal-point character "
8692 "and the number of digits after it is equal to the precision; if the "
8693 "precision is missing, it is taken as 6; if the precision is zero, no decimal-"
8694 "point character appears.  An B<E> conversion uses the letter B<E> (rather "
8695 "than B<e>)  to introduce the exponent.  The exponent always contains at "
8696 "least two digits; if the value is zero, the exponent is 00."
8697 msgstr ""
8698 "I<double> 引き数を丸めて [-]dB<\\&.>dddB<e>\\(+-dd の形に変換する。\n"
8699 "小数点の前には一桁の数字があり、小数点以下の桁数は精度で指定された桁数\n"
8700 "になる。精度は指定されなかった場合 6 とみなされる。 精度が 0 の場合には、\n"
8701 "小数点以下は表示されない。B<E> 変換では、指数を表現するときに (B<e> で\n"
8702 "はなく) B<E> が使われる。指数部分は少なくとも 2桁表示される。つまり、\n"
8703 "指数の値が 0 の場合には、00 と表示される。"
8704
8705 #. type: TP
8706 #: build/C/man3/printf.3:636
8707 #, no-wrap
8708 msgid "B<f>, B<F>"
8709 msgstr "B<f>, B<F>"
8710
8711 #. type: Plain text
8712 #: build/C/man3/printf.3:647
8713 msgid ""
8714 "The I<double> argument is rounded and converted to decimal notation in the "
8715 "style [-]dddB<\\&.>ddd, where the number of digits after the decimal-point "
8716 "character is equal to the precision specification.  If the precision is "
8717 "missing, it is taken as 6; if the precision is explicitly zero, no decimal-"
8718 "point character appears.  If a decimal point appears, at least one digit "
8719 "appears before it."
8720 msgstr ""
8721 "I<double> 引き数を丸めて [-]dddB<\\&.>ddd の形の10進表現に変換する。 小数点の"
8722 "後の桁数は、精度で指定された値となる。 精度が指定されていない場合には 6 とし"
8723 "て扱われる。 精度として明示的に 0 が指定されたときには、小数点以下は表示され"
8724 "ない。 小数点を表示する際には、小数点の前に少なくとも一桁は数字が表示される。"
8725
8726 #. type: Plain text
8727 #: build/C/man3/printf.3:658
8728 msgid ""
8729 "(The SUSv2 does not know about B<F> and says that character string "
8730 "representations for infinity and NaN may be made available.  The C99 "
8731 "standard specifies \"[-]inf\" or \"[-]infinity\" for infinity, and a string "
8732 "starting with \"nan\" for NaN, in the case of B<f> conversion, and \"[-]INF"
8733 "\" or \"[-]INFINITY\" or \"NAN*\" in the case of B<F> conversion.)"
8734 msgstr ""
8735 "(SUSv2 では、B<F> は規定されておらず、無限や NaN に関する文字列表現を\n"
8736 "行ってもよいことになっている。\n"
8737 " C99 標準では、B<f> 変換では、無限は \"[-]inf\" か \"[-]infinity\" と表示"
8738 "し、\n"
8739 "NaN は文字列の先頭に `nan' をつけて表示するように規定されている。\n"
8740 "B<F> 変換の場合は \"[-]INF\", \"[-]INFINITY\", \"NAN*\" と表示される。)"
8741
8742 #. type: TP
8743 #: build/C/man3/printf.3:658
8744 #, no-wrap
8745 msgid "B<g>, B<G>"
8746 msgstr "B<g>, B<G>"
8747
8748 #. type: Plain text
8749 #: build/C/man3/printf.3:683
8750 msgid ""
8751 "The I<double> argument is converted in style B<f> or B<e> (or B<F> or B<E> "
8752 "for B<G> conversions).  The precision specifies the number of significant "
8753 "digits.  If the precision is missing, 6 digits are given; if the precision "
8754 "is zero, it is treated as 1.  Style B<e> is used if the exponent from its "
8755 "conversion is less than -4 or greater than or equal to the precision.  "
8756 "Trailing zeros are removed from the fractional part of the result; a decimal "
8757 "point appears only if it is followed by at least one digit."
8758 msgstr ""
8759 "I<double> 引き数を B<f> か B<e> (B<G> 変換の場合は B<F> か B<E>)  の形式に変"
8760 "換する。 精度は表示する桁数を指定する。 精度が指定されない場合は、6桁とみなさ"
8761 "れる。 精度が 0 の場合は、1桁とみなされる。 変換される値の指数が、 -4 より小"
8762 "さいか、精度以上の場合に、 B<e> 形式が使用される。 変換された結果の小数部分の"
8763 "末尾の 0 は削除される。小数点が表示されるのは、 小数点以下に数字が少なくとも"
8764 "一つある場合にだけである。"
8765
8766 #. type: TP
8767 #: build/C/man3/printf.3:683
8768 #, no-wrap
8769 msgid "B<a>, B<A>"
8770 msgstr "B<a>, B<A>"
8771
8772 #. type: Plain text
8773 #: build/C/man3/printf.3:707
8774 msgid ""
8775 "(C99; not in SUSv2) For B<a> conversion, the I<double> argument is converted "
8776 "to hexadecimal notation (using the letters abcdef)  in the style [-]B<0x>hB<"
8777 "\\&.>hhhhB<p>\\(+-; for B<A> conversion the prefix B<0X>, the letters "
8778 "ABCDEF, and the exponent separator B<P> is used.  There is one hexadecimal "
8779 "digit before the decimal point, and the number of digits after it is equal "
8780 "to the precision.  The default precision suffices for an exact "
8781 "representation of the value if an exact representation in base 2 exists and "
8782 "otherwise is sufficiently large to distinguish values of type I<double>.  "
8783 "The digit before the decimal point is unspecified for nonnormalized numbers, "
8784 "and nonzero but otherwise unspecified for normalized numbers."
8785 msgstr ""
8786 "(C99 にはあるが SUSv2 にはない) B<a> 変換では、 I<double> 引き数を\n"
8787 "(abcdef の文字を使って) [-]B<0x>hB<\\&.>hhhhB<p>\\(+- 形式の\n"
8788 "16 進表記に変換する。\n"
8789 "B<A> 変換では、前置文字列 B<0X>, 文字 ABCDEF, 指数文字 B<P> を用いる。\n"
8790 "小数点の前には 1 桁の 16 進数が置かれ、小数点の後ろの桁数は 精度で指定\n"
8791 "された値となる。デフォルトの精度は、その値が 2 進数で正確に表現できる\n"
8792 "場合には、その値を正確に表現できる桁数となる。それ以外の場合は、\n"
8793 "I<double> 型の値を区別するのに十分な大きさとなる。 小数点の前の数字は、\n"
8794 "正規化されていない数の場合はいくつになるか分からない。 正規化された数の\n"
8795 "場合は、 0 以外の値になるが、いくつになるかは分からない。"
8796
8797 #. type: TP
8798 #: build/C/man3/printf.3:707 build/C/man3/scanf.3:459
8799 #: build/C/man3/wprintf.3:134
8800 #, no-wrap
8801 msgid "B<c>"
8802 msgstr "B<c>"
8803
8804 #. type: Plain text
8805 #: build/C/man3/printf.3:725
8806 msgid ""
8807 "If no B<l> modifier is present, the I<int> argument is converted to an "
8808 "I<unsigned char>, and the resulting character is written.  If an B<l> "
8809 "modifier is present, the I<wint_t> (wide character) argument is converted to "
8810 "a multibyte sequence by a call to the B<wcrtomb>(3)  function, with a "
8811 "conversion state starting in the initial state, and the resulting multibyte "
8812 "string is written."
8813 msgstr ""
8814 "B<l> 修飾子がなければ、 I<int> 引き数を I<unsigned char> に変換して、その結果"
8815 "に対応する文字を出力する。 B<l> 修飾子があれば、 I<wint_t> (ワイド文字) 引き"
8816 "数を、 B<wcrtomb>(3)  関数を初期シフト状態で呼び出してマルチバイト文字列に変"
8817 "換し、 変換されたマルチバイト文字列を出力する。"
8818
8819 #. type: TP
8820 #: build/C/man3/printf.3:725 build/C/man3/scanf.3:451
8821 #: build/C/man3/wprintf.3:148
8822 #, no-wrap
8823 msgid "B<s>"
8824 msgstr "B<s>"
8825
8826 #. type: Plain text
8827 #: build/C/man3/printf.3:740
8828 msgid ""
8829 "If no B<l> modifier is present: The I<const char *> argument is expected to "
8830 "be a pointer to an array of character type (pointer to a string).  "
8831 "Characters from the array are written up to (but not including) a "
8832 "terminating null byte (\\(aq\\e0\\(aq); if a precision is specified, no more "
8833 "than the number specified are written.  If a precision is given, no null "
8834 "byte need be present; if the precision is not specified, or is greater than "
8835 "the size of the array, the array must contain a terminating null byte."
8836 msgstr ""
8837 "B<l> 修飾子がない場合、 引き数は I<const char *> 型で文字型の配列へのポイン"
8838 "タ (文字列へのポインタ) であることが 期待されている。配列中の文字は、終端の "
8839 "NULL バイト (\\(aq\\e0\\(aq)  が出てくるまで出力される (終端文字は出力されな"
8840 "い)。 精度が指定されていると、指定された字数以上は出力されない。 精度が指定さ"
8841 "れた場合には、終端バイトが存在する必要はない。 精度が指定されていなかったり、"
8842 "精度の値が配列の大きさより大きい場合には、 配列は終端の NULL バイトを含んでい"
8843 "なければならない。"
8844
8845 #. type: Plain text
8846 #: build/C/man3/printf.3:767
8847 msgid ""
8848 "If an B<l> modifier is present: The I<const wchar_t *> argument is expected "
8849 "to be a pointer to an array of wide characters.  Wide characters from the "
8850 "array are converted to multibyte characters (each by a call to the B<wcrtomb>"
8851 "(3)  function, with a conversion state starting in the initial state before "
8852 "the first wide character), up to and including a terminating null wide "
8853 "character.  The resulting multibyte characters are written up to (but not "
8854 "including) the terminating null byte.  If a precision is specified, no more "
8855 "bytes than the number specified are written, but no partial multibyte "
8856 "characters are written.  Note that the precision determines the number of "
8857 "I<bytes> written, not the number of I<wide characters> or I<screen "
8858 "positions>.  The array must contain a terminating null wide character, "
8859 "unless a precision is given and it is so small that the number of bytes "
8860 "written exceeds it before the end of the array is reached."
8861 msgstr ""
8862 "B<l> 修飾子が指定されている場合、 引き数は I<const wchar_t *> 型でワイド文字"
8863 "の配列へのポインタであることが期待されている。 配列中のワイド文字は (1文字毎"
8864 "に B<wcrtomb>(3)  を呼び出して) マルチバイト文字に変換される (最初のワイド文"
8865 "字の変換の前に B<wcrtomb>()  のシフト状態を初期状態に戻してから変換は行われ"
8866 "る)。 マルチバイト文字への変換は、文字列を終端する NULL ワイド文字が 出てくる"
8867 "まで行われ、終端 NULL ワイド文字も含めて変換される。 結果のマルチバイト文字列"
8868 "は、終端の NULL バイトが出てくるまで 出力される (終端の NULL バイトは出力され"
8869 "ない)。 精度が指定された場合、指定されたバイト数以上には出力されない。 但し、"
8870 "マルチバイト文字の一部分だけが出力されることはない。 精度は「バイト」数を指定"
8871 "するものであり、「ワイド文字」数や 「画面での位置」を指定するものではないこと"
8872 "に注意。 精度が指定されていて、さらに出力が配列の末尾に達する前に出力バイト数"
8873 "が 精度の値を超える場合だけは、配列は NULL ワイド文字で終端されていなくてもよ"
8874 "い。 それ以外の場合は、必ず配列は NULL ワイド文字で終端されていなければならな"
8875 "い。"
8876
8877 #. type: TP
8878 #: build/C/man3/printf.3:767
8879 #, no-wrap
8880 msgid "B<C>"
8881 msgstr "B<C>"
8882
8883 #. type: Plain text
8884 #: build/C/man3/printf.3:773
8885 msgid "(Not in C99, but in SUSv2.)  Synonym for B<lc>.  Don't use."
8886 msgstr "(C99 にはないが SUSv2 にはある)  B<lc> と同じ。使ってはならない。"
8887
8888 #. type: TP
8889 #: build/C/man3/printf.3:773
8890 #, no-wrap
8891 msgid "B<S>"
8892 msgstr "B<S>"
8893
8894 #. type: Plain text
8895 #: build/C/man3/printf.3:779
8896 msgid "(Not in C99, but in SUSv2.)  Synonym for B<ls>.  Don't use."
8897 msgstr "(C99 にはないが SUSv2 にはある)  B<ls> と同じ。使ってはならない。"
8898
8899 #. type: TP
8900 #: build/C/man3/printf.3:779 build/C/man3/scanf.3:503
8901 #, no-wrap
8902 msgid "B<p>"
8903 msgstr "B<p>"
8904
8905 #. type: Plain text
8906 #: build/C/man3/printf.3:787
8907 msgid ""
8908 "The I<void *> pointer argument is printed in hexadecimal (as if by B<%#x> or "
8909 "B<%#lx>)."
8910 msgstr ""
8911 "I<void *> ポインタ引き数を (B<%#x> や B<%#lx> のような) 16 進数で出力する。"
8912
8913 #. type: TP
8914 #: build/C/man3/printf.3:787 build/C/man3/scanf.3:511
8915 #, no-wrap
8916 msgid "B<n>"
8917 msgstr "B<n>"
8918
8919 #. type: Plain text
8920 #: build/C/man3/printf.3:794
8921 msgid ""
8922 "The number of characters written so far is stored into the integer indicated "
8923 "by the I<int *> (or variant) pointer argument.  No argument is converted."
8924 msgstr ""
8925 "これまでに出力された文字数を I<int *> (または類似の型) のポインタ引き数が指す"
8926 "整数に保存する。 引き数の変換は行われない。"
8927
8928 #. type: TP
8929 #: build/C/man3/printf.3:794
8930 #, no-wrap
8931 msgid "B<m>"
8932 msgstr "B<m>"
8933
8934 #. type: Plain text
8935 #: build/C/man3/printf.3:800
8936 msgid ""
8937 "(Glibc extension.)  Print output of I<strerror(errno)>.  No argument is "
8938 "required."
8939 msgstr ""
8940 "(glibc での拡張)  I<strerror(errno)> の出力を表示する。引き数は必要ない。"
8941
8942 #. type: TP
8943 #: build/C/man3/printf.3:800 build/C/man3/scanf.3:377
8944 #, no-wrap
8945 msgid "B<%>"
8946 msgstr "B<%>"
8947
8948 #. type: Plain text
8949 #: build/C/man3/printf.3:806
8950 msgid ""
8951 "A \\(aq%\\(aq is written.  No argument is converted.  The complete "
8952 "conversion specification is \\(aq%%\\(aq."
8953 msgstr ""
8954 "\\(aq%\\(aq 文字を出力する。変換される引き数は無い。 変換指定全体を書くと \"%"
8955 "%\" となる。"
8956
8957 #. type: Plain text
8958 #: build/C/man3/printf.3:821
8959 msgid ""
8960 "The B<fprintf>(), B<printf>(), B<sprintf>(), B<vprintf>(), B<vfprintf>(), "
8961 "and B<vsprintf>()  functions conform to C89 and C99.  The B<snprintf>()  and "
8962 "B<vsnprintf>()  functions conform to C99."
8963 msgstr ""
8964 "B<fprintf>(), B<printf>(), B<sprintf>(), B<vprintf>(), B<vfprintf>(), "
8965 "B<vsprintf>()  関数は、C89 と C99 に準拠している。 B<snprintf>()  と "
8966 "B<vsnprintf>()  は C99 に準拠している。"
8967
8968 #. type: Plain text
8969 #: build/C/man3/printf.3:834
8970 msgid ""
8971 "Concerning the return value of B<snprintf>(), SUSv2 and C99 contradict each "
8972 "other: when B<snprintf>()  is called with I<size>=0 then SUSv2 stipulates an "
8973 "unspecified return value less than 1, while C99 allows I<str> to be NULL in "
8974 "this case, and gives the return value (as always)  as the number of "
8975 "characters that would have been written in case the output string has been "
8976 "large enough."
8977 msgstr ""
8978 "B<snprintf>()  の返り値を見ると、 SUSv2 と C99 標準は互いに矛盾している。 "
8979 "SUSv2 では、 B<snprintf>()  が I<size>=0 で呼び出された場合、 1 未満の値を何"
8980 "か返り値とするように規定している。 一方 C99 では、このような場合 I<str> を "
8981 "NULL とし、返り値として (通常通り) 出力バッファが十分な大きさが あった場合に"
8982 "出力されるであろう文字数を返す。"
8983
8984 #. type: Plain text
8985 #: build/C/man3/printf.3:848
8986 msgid ""
8987 "Linux libc4 knows about the five C standard flags.  It knows about the "
8988 "length modifiers B<h>, B<l>, B<L>, and the conversions B<c>, B<d>, B<e>, "
8989 "B<E>, B<f>, B<F>, B<g>, B<G>, B<i>, B<n>, B<o>, B<p>, B<s>, B<u>, B<x>, and "
8990 "B<X>, where B<F> is a synonym for B<f>.  Additionally, it accepts B<D>, "
8991 "B<O>, and B<U> as synonyms for B<ld>, B<lo>, and B<lu>.  (This is bad, and "
8992 "caused serious bugs later, when support for B<%D> disappeared.)  No locale-"
8993 "dependent radix character, no thousands' separator, no NaN or infinity, no "
8994 "\"%m$\" and \"*m$\"."
8995 msgstr ""
8996 "Linux libc4 では、 5 つの C 標準のフラグ、 長さ修飾子 B<h>, B<l>, B<L>、変換 "
8997 "B<c>, B<d>, B<e>, B<E>, B<f>, B<F>, B<g>, B<G>, B<i>, B<n>, B<o>, B<p>, "
8998 "B<s>, B<u>, B<x>, B<X> が使える。 但し B<F> は B<f> と同義である。 また、 "
8999 "B<D>, B<O>, and B<U> を B<ld>, B<lo>, and B<lu> と同じものとして使える (これ"
9000 "はまずい仕様で、 後に B<%D> の対応が打ち切られた時に深刻なバグを 引き起こし"
9001 "た)。ロケール依存の小数点、1000 区切り、 NaN と無限、 \"%m$\" と \"*m$\" は使"
9002 "えない。"
9003
9004 #. type: Plain text
9005 #: build/C/man3/printf.3:859
9006 msgid ""
9007 "Linux libc5 knows about the five C standard flags and the \\(aq flag, "
9008 "locale, \"%m$\" and \"*m$\".  It knows about the length modifiers B<h>, "
9009 "B<l>, B<L>, B<Z>, and B<q>, but accepts B<L> and B<q> both for I<long "
9010 "double> and for I<long long int> (this is a bug).  It no longer recognizes "
9011 "B<F>, B<D>, B<O>, and B<U>, but adds the conversion character B<m>, which "
9012 "outputs I<strerror(errno)>."
9013 msgstr ""
9014 "Linux libc5 では、 5 つの C 標準のフラグと \\(aq フラグ、ロケール、 \"%m$\" "
9015 "と \"*m$\" が使える。 また、長さ修飾子 B<h>, B<l>, B<L>, B<Z>, iand B<q> が使"
9016 "えるが、 B<L> と B<q> は両方とも I<long double> と I<long long int> に対応し"
9017 "ている (これはバグである)。 現在では変換 B<F>, B<D>, B<O>, B<U> は認識されな"
9018 "いが、変換文字 B<m> が追加された。これは I<strerror(errno)> を出力するもので"
9019 "ある。"
9020
9021 #. type: Plain text
9022 #: build/C/man3/printf.3:861
9023 msgid "glibc 2.0 adds conversion characters B<C> and B<S>."
9024 msgstr "glibc 2.0 では、変換文字 B<C> と B<S> が追加された。"
9025
9026 #. type: Plain text
9027 #: build/C/man3/printf.3:864
9028 msgid ""
9029 "glibc 2.1 adds length modifiers B<hh>, B<j>, B<t>, and B<z> and conversion "
9030 "characters B<a> and B<A>."
9031 msgstr ""
9032 "glibc 2.1 では、長さ修飾子 B<hh>, B<j>, B<t>, B<z> と変換文字 B<a>, B<A> が追"
9033 "加された。"
9034
9035 #. type: Plain text
9036 #: build/C/man3/printf.3:867
9037 msgid ""
9038 "glibc 2.2 adds the conversion character B<F> with C99 semantics, and the "
9039 "flag character B<I>."
9040 msgstr ""
9041 "glibc 2.2 では、 C99 で規定された意味での変換文字 B<F> と フラグ文字 B<I> が"
9042 "追加された。"
9043
9044 #. type: Plain text
9045 #: build/C/man3/printf.3:869
9046 msgid "Some programs imprudently rely on code such as the following"
9047 msgstr ""
9048 "テキストを I<buf> に追加するのに、軽率にも次のようなコードを使っているプログ"
9049 "ラムがある。"
9050
9051 #. type: Plain text
9052 #: build/C/man3/printf.3:871
9053 #, no-wrap
9054 msgid "    sprintf(buf, \"%s some further text\", buf);\n"
9055 msgstr "    sprintf(buf, \"%s some further text\", buf);\n"
9056
9057 #.  http://sourceware.org/bugzilla/show_bug.cgi?id=7075
9058 #. type: Plain text
9059 #: build/C/man3/printf.3:887
9060 msgid ""
9061 "to append text to I<buf>.  However, the standards explicitly note that the "
9062 "results are undefined if source and destination buffers overlap when calling "
9063 "B<sprintf>(), B<snprintf>(), B<vsprintf>(), and B<vsnprintf>().  Depending "
9064 "on the version of B<gcc>(1)  used, and the compiler options employed, calls "
9065 "such as the above will B<not> produce the expected results."
9066 msgstr ""
9067 "しかしながら、標準規格では、 B<sprintf>(), B<snprintf>(), B<vsprintf>(), "
9068 "B<vsnprintf>()  の呼び出しにおいて、コピー元とコピー先のバッファが重なってい"
9069 "た場合の 結果は不定である、と明記されている。 使用する B<gcc>(1)  のバージョ"
9070 "ンや指定したコンパイラのオプション次第では、 上記のような呼び出しで、期待した"
9071 "結果が得られ「ない」ことがある。"
9072
9073 #.  .SH HISTORY
9074 #.  UNIX V7 defines the three routines
9075 #.  .BR printf (),
9076 #.  .BR fprintf (),
9077 #.  .BR sprintf (),
9078 #.  and has the flag \-, the width or precision *, the length modifier l,
9079 #.  and the conversions doxfegcsu, and also D,O,U,X as synonyms for ld,lo,lu,lx.
9080 #.  This is still true for 2.9.1BSD, but 2.10BSD has the flags
9081 #.  #, + and <space> and no longer mentions D,O,U,X.
9082 #.  2.11BSD has
9083 #.  .BR vprintf (),
9084 #.  .BR vfprintf (),
9085 #.  .BR vsprintf (),
9086 #.  and warns not to use D,O,U,X.
9087 #.  4.3BSD Reno has the flag 0, the length modifiers h and L,
9088 #.  and the conversions n, p, E, G, X (with current meaning)
9089 #.  and deprecates D,O,U.
9090 #.  4.4BSD introduces the functions
9091 #.  .BR snprintf ()
9092 #.  and
9093 #.  .BR vsnprintf (),
9094 #.  and the length modifier q.
9095 #.  FreeBSD also has functions
9096 #.  .BR asprintf ()
9097 #.  and
9098 #.  .BR vasprintf (),
9099 #.  that allocate a buffer large enough for
9100 #.  .BR sprintf ().
9101 #.  In glibc there are functions
9102 #.  .BR dprintf ()
9103 #.  and
9104 #.  .BR vdprintf ()
9105 #.  that print to a file descriptor instead of a stream.
9106 #. type: Plain text
9107 #: build/C/man3/printf.3:929
9108 msgid ""
9109 "The glibc implementation of the functions B<snprintf>()  and B<vsnprintf>()  "
9110 "conforms to the C99 standard, that is, behaves as described above, since "
9111 "glibc version 2.1.  Until glibc 2.0.6 they would return -1 when the output "
9112 "was truncated."
9113 msgstr ""
9114 "glibc の B<snprintf>()  と B<vsnprintf>()  の実装は、バージョン 2.1 以降は "
9115 "C99 標準に準拠しており、 上記の通りの動作をする。 glibc 2.0.6 までは、出力が"
9116 "切り詰められた場合は -1 を返す。"
9117
9118 #. type: Plain text
9119 #: build/C/man3/printf.3:946
9120 msgid ""
9121 "Because B<sprintf>()  and B<vsprintf>()  assume an arbitrarily long string, "
9122 "callers must be careful not to overflow the actual space; this is often "
9123 "impossible to assure.  Note that the length of the strings produced is "
9124 "locale-dependent and difficult to predict.  Use B<snprintf>()  and "
9125 "B<vsnprintf>()  instead (or B<asprintf>(3)  and B<vasprintf>(3))."
9126 msgstr ""
9127 "B<sprintf>()  と B<vsprintf>()  は勝手に十分に長い文字列領域があると仮定する"
9128 "ので、呼び出し側は 実際の領域からあふれないように注意しなければならない。 し"
9129 "かし、これを保証することが不可能な場合が多い。 生成される文字列の長さはロケー"
9130 "ル依存であり、予測が難しいことに注意。 代わりに B<snprintf>()  と "
9131 "B<vsnprintf>()  (または B<asprintf>(3)  と B<vasprintf>(3))  を使うこと。"
9132
9133 #. type: Plain text
9134 #: build/C/man3/printf.3:959
9135 msgid ""
9136 "Linux libc4.[45] does not have a B<snprintf>(), but provides a libbsd that "
9137 "contains an B<snprintf>()  equivalent to B<sprintf>(), that is, one that "
9138 "ignores the I<size> argument.  Thus, the use of B<snprintf>()  with early "
9139 "libc4 leads to serious security problems."
9140 msgstr ""
9141 "Linux libc4.[45] には B<snprintf>()  はないが、 libbsd が提供されており、 そ"
9142 "の中には B<sprintf>()  と等価な (つまり I<size> 引き数を無視する)  "
9143 "B<snprintf>()  がある。 したがって、初期の libc4 で B<snprintf>()  を使うと、"
9144 "深刻なセキュリティ問題を引き起こすことがある。"
9145
9146 #.  .PP
9147 #.  Some floating-point conversions under early libc4
9148 #.  caused memory leaks.
9149 #. type: Plain text
9150 #: build/C/man3/printf.3:973
9151 msgid ""
9152 "Code such as B<printf(>I<foo>B<);> often indicates a bug, since I<foo> may "
9153 "contain a % character.  If I<foo> comes from untrusted user input, it may "
9154 "contain B<%n>, causing the B<printf>()  call to write to memory and creating "
9155 "a security hole."
9156 msgstr ""
9157 "B<printf(>I<foo>B<);> のようなコードはしばしばバグを引き起こす。 なぜなら "
9158 "I<foo> に % 文字が含まれてるかもしれないからである。 I<foo> が信頼できない"
9159 "ユーザー入力から作られている場合には、 その中に B<%n> が含まれていることがあ"
9160 "り、 B<printf>()  呼び出し時にメモリへの書き込みが起こり、 セキュリティーホー"
9161 "ルを作ることになるかもしれない。"
9162
9163 #. type: Plain text
9164 #: build/C/man3/printf.3:977
9165 msgid "To print I<Pi> to five decimal places:"
9166 msgstr "I<Pi> を 5 桁で出力する。"
9167
9168 #. type: Plain text
9169 #: build/C/man3/printf.3:983
9170 #, no-wrap
9171 msgid ""
9172 "#include E<lt>math.hE<gt>\n"
9173 "#include E<lt>stdio.hE<gt>\n"
9174 "fprintf(stdout, \"pi = %.5f\\en\", 4 * atan(1.0));\n"
9175 msgstr ""
9176 "#include E<lt>math.hE<gt>\n"
9177 "#include E<lt>stdio.hE<gt>\n"
9178 "fprintf(stdout, \"pi = %.5f\\en\", 4 * atan(1.0));\n"
9179
9180 #. type: Plain text
9181 #: build/C/man3/printf.3:992
9182 msgid ""
9183 "To print a date and time in the form \"Sunday, July 3, 10:02\", where "
9184 "I<weekday> and I<month> are pointers to strings:"
9185 msgstr ""
9186 "日付と時間を \"Sunday, July 3, 10:02\" の形式で出力する。 (I<weekday> と "
9187 "I<month> は文字列へのポインタである)"
9188
9189 #. type: Plain text
9190 #: build/C/man3/printf.3:998
9191 #, no-wrap
9192 msgid ""
9193 "#include E<lt>stdio.hE<gt>\n"
9194 "fprintf(stdout, \"%s, %s %d, %.2d:%.2d\\en\",\n"
9195 "        weekday, month, day, hour, min);\n"
9196 msgstr ""
9197 "#include E<lt>stdio.hE<gt>\n"
9198 "fprintf(stdout, \"%s, %s %d, %.2d:%.2d\\en\",\n"
9199 "\tweekday, month, day, hour, min);\n"
9200
9201 #. type: Plain text
9202 #: build/C/man3/printf.3:1004
9203 msgid ""
9204 "Many countries use the day-month-year order.  Hence, an internationalized "
9205 "version must be able to print the arguments in an order specified by the "
9206 "format:"
9207 msgstr ""
9208 "日 - 月 - 年 の順序で表示を行う国も多い。 従って、国際版では書式で指定された"
9209 "順番で 引き数を表示できなければならない。"
9210
9211 #. type: Plain text
9212 #: build/C/man3/printf.3:1010
9213 #, no-wrap
9214 msgid ""
9215 "#include E<lt>stdio.hE<gt>\n"
9216 "fprintf(stdout, format,\n"
9217 "        weekday, month, day, hour, min);\n"
9218 msgstr ""
9219 "#include E<lt>stdio.hE<gt>\n"
9220 "fprintf(stdout, format,\n"
9221 "\tweekday, month, day, hour, min);\n"
9222
9223 #. type: Plain text
9224 #: build/C/man3/printf.3:1017
9225 msgid ""
9226 "where I<format> depends on locale, and may permute the arguments.  With the "
9227 "value:"
9228 msgstr ""
9229 "I<format> はロケールに依存しており、引き数の順番を変えることもできる。 "
9230 "I<format> が"
9231
9232 #. type: Plain text
9233 #: build/C/man3/printf.3:1021
9234 #, no-wrap
9235 msgid "\"%1$s, %3$d. %2$s, %4$d:%5$.2d\\en\"\n"
9236 msgstr "\"%1$s, %3$d. %2$s, %4$d:%5$.2d\\en\"\n"
9237
9238 #. type: Plain text
9239 #: build/C/man3/printf.3:1025
9240 msgid "one might obtain \"Sonntag, 3. Juli, 10:02\"."
9241 msgstr "であれば、 \"Sonntag, 3. Juli, 10:02\" という結果になる。"
9242
9243 #. type: Plain text
9244 #: build/C/man3/printf.3:1028
9245 msgid ""
9246 "To allocate a sufficiently large string and print into it (code correct for "
9247 "both glibc 2.0 and glibc 2.1):"
9248 msgstr ""
9249 "十分に大きな文字列領域を確保して、そこにメッセージを格納するには (glibc 2.0 "
9250 "と glibc 2.1 の両方で正しく動作するコード):"
9251
9252 #. type: Plain text
9253 #: build/C/man3/printf.3:1031
9254 msgid ""
9255 "If truncation occurs in glibc versions prior to 2.0.6, this is treated as an "
9256 "error instead of being handled gracefully."
9257 msgstr ""
9258
9259 #. type: Plain text
9260 #: build/C/man3/printf.3:1036
9261 #, no-wrap
9262 msgid ""
9263 "#include E<lt>stdio.hE<gt>\n"
9264 "#include E<lt>stdlib.hE<gt>\n"
9265 "#include E<lt>stdarg.hE<gt>\n"
9266 msgstr ""
9267 "#include E<lt>stdio.hE<gt>\n"
9268 "#include E<lt>stdlib.hE<gt>\n"
9269 "#include E<lt>stdarg.hE<gt>\n"
9270
9271 #. type: Plain text
9272 #: build/C/man3/printf.3:1044
9273 #, no-wrap
9274 msgid ""
9275 "char *\n"
9276 "make_message(const char *fmt, ...)\n"
9277 "{\n"
9278 "    int n;\n"
9279 "    int size = 100;     /* Guess we need no more than 100 bytes */\n"
9280 "    char *p, *np;\n"
9281 "    va_list ap;\n"
9282 msgstr ""
9283 "char *\n"
9284 "make_message(const char *fmt, ...)\n"
9285 "{\n"
9286 "    int n;\n"
9287 "    int size = 100;     /* Guess we need no more than 100 bytes */\n"
9288 "    char *p, *np;\n"
9289 "    va_list ap;\n"
9290
9291 #. type: Plain text
9292 #: build/C/man3/printf.3:1047
9293 #, no-wrap
9294 msgid ""
9295 "    if ((p = malloc(size)) == NULL)\n"
9296 "        return NULL;\n"
9297 msgstr ""
9298 "    if ((p = malloc(size)) == NULL)\n"
9299 "        return NULL;\n"
9300
9301 #. type: Plain text
9302 #: build/C/man3/printf.3:1049
9303 #, no-wrap
9304 msgid "    while (1) {\n"
9305 msgstr "    while (1) {\n"
9306
9307 #. type: Plain text
9308 #: build/C/man3/printf.3:1051
9309 #, no-wrap
9310 msgid "        /* Try to print in the allocated space */\n"
9311 msgstr "        /* Try to print in the allocated space */\n"
9312
9313 #. type: Plain text
9314 #: build/C/man3/printf.3:1055
9315 #, no-wrap
9316 msgid ""
9317 "        va_start(ap, fmt);\n"
9318 "        n = vsnprintf(p, size, fmt, ap);\n"
9319 "        va_end(ap);\n"
9320 msgstr ""
9321 "        va_start(ap, fmt);\n"
9322 "        n = vsnprintf(p, size, fmt, ap);\n"
9323 "        va_end(ap);\n"
9324
9325 #. type: Plain text
9326 #: build/C/man3/printf.3:1057
9327 #, no-wrap
9328 msgid "        /* Check error code */\n"
9329 msgstr "        /* Check error code */\n"
9330
9331 #. type: Plain text
9332 #: build/C/man3/printf.3:1060
9333 #, no-wrap
9334 msgid ""
9335 "        if (n E<lt> 0)\n"
9336 "            return NULL;\n"
9337 msgstr ""
9338 "        if (n E<lt> 0)\n"
9339 "            return NULL;\n"
9340
9341 #. type: Plain text
9342 #: build/C/man3/printf.3:1062
9343 #, no-wrap
9344 msgid "        /* If that worked, return the string */\n"
9345 msgstr "        /* If that worked, return the string */\n"
9346
9347 #. type: Plain text
9348 #: build/C/man3/printf.3:1065
9349 #, no-wrap
9350 msgid ""
9351 "        if (n E<lt> size)\n"
9352 "            return p;\n"
9353 msgstr ""
9354 "        if (n E<lt> size)\n"
9355 "            return p;\n"
9356
9357 #. type: Plain text
9358 #: build/C/man3/printf.3:1067
9359 #, no-wrap
9360 msgid "        /* Else try again with more space */\n"
9361 msgstr "        /* Else try again with more space */\n"
9362
9363 #. type: Plain text
9364 #: build/C/man3/printf.3:1069
9365 #, no-wrap
9366 msgid "        size = n + 1;       /* Precisely what is needed */\n"
9367 msgstr "        size = n + 1;       /* Precisely what is needed */\n"
9368
9369 #. type: Plain text
9370 #: build/C/man3/printf.3:1079
9371 #, no-wrap
9372 msgid ""
9373 "        if ((np = realloc (p, size)) == NULL) {\n"
9374 "            free(p);\n"
9375 "            return NULL;\n"
9376 "        } else {\n"
9377 "            p = np;\n"
9378 "        }\n"
9379 "    }\n"
9380 "}\n"
9381 msgstr ""
9382 "        if ((np = realloc (p, size)) == NULL) {\n"
9383 "            free(p);\n"
9384 "            return NULL;\n"
9385 "        } else {\n"
9386 "            p = np;\n"
9387 "        }\n"
9388 "    }\n"
9389 "}\n"
9390
9391 #. type: Plain text
9392 #: build/C/man3/printf.3:1089
9393 msgid ""
9394 "B<printf>(1), B<asprintf>(3), B<dprintf>(3), B<scanf>(3), B<setlocale>(3), "
9395 "B<wcrtomb>(3), B<wprintf>(3), B<locale>(5)"
9396 msgstr ""
9397 "B<printf>(1), B<asprintf>(3), B<dprintf>(3), B<scanf>(3), B<setlocale>(3), "
9398 "B<wcrtomb>(3), B<wprintf>(3), B<locale>(5)"
9399
9400 #. type: TH
9401 #: build/C/man3/puts.3:26
9402 #, no-wrap
9403 msgid "PUTS"
9404 msgstr "PUTS"
9405
9406 #. type: TH
9407 #: build/C/man3/puts.3:26
9408 #, no-wrap
9409 msgid "2011-09-28"
9410 msgstr "2011-09-28"
9411
9412 #. type: Plain text
9413 #: build/C/man3/puts.3:29
9414 msgid "fputc, fputs, putc, putchar, puts - output of characters and strings"
9415 msgstr "fputc, fputs, putc, putchar, puts - 文字と文字列の出力"
9416
9417 #. type: Plain text
9418 #: build/C/man3/puts.3:34
9419 #, no-wrap
9420 msgid "B<int fputc(int >I<c>B<, FILE *>I<stream>B<);>\n"
9421 msgstr "B<int fputc(int >I<c>B<, FILE *>I<stream>B<);>\n"
9422
9423 #. type: Plain text
9424 #: build/C/man3/puts.3:36
9425 #, no-wrap
9426 msgid "B<int fputs(const char *>I<s>B<, FILE *>I<stream>B<);>\n"
9427 msgstr "B<int fputs(const char *>I<s>B<, FILE *>I<stream>B<);>\n"
9428
9429 #. type: Plain text
9430 #: build/C/man3/puts.3:38
9431 #, no-wrap
9432 msgid "B<int putc(int >I<c>B<, FILE *>I<stream>B<);>\n"
9433 msgstr "B<int putc(int >I<c>B<, FILE *>I<stream>B<);>\n"
9434
9435 #. type: Plain text
9436 #: build/C/man3/puts.3:40
9437 #, no-wrap
9438 msgid "B<int putchar(int >I<c>B<);>\n"
9439 msgstr "B<int putchar(int >I<c>B<);>\n"
9440
9441 #. type: Plain text
9442 #: build/C/man3/puts.3:42
9443 #, no-wrap
9444 msgid "B<int puts(const char *>I<s>B<);>\n"
9445 msgstr "B<int puts(const char *>I<s>B<);>\n"
9446
9447 #. type: Plain text
9448 #: build/C/man3/puts.3:51
9449 msgid ""
9450 "B<fputc>()  writes the character I<c>, cast to an I<unsigned char>, to "
9451 "I<stream>."
9452 msgstr ""
9453 "B<fputc>()  は、キャラクタ I<c> を I<unsigned char> にキャストし、 I<stream> "
9454 "に書き込む。"
9455
9456 #. type: Plain text
9457 #: build/C/man3/puts.3:58
9458 msgid ""
9459 "B<fputs>()  writes the string I<s> to I<stream>, without its terminating "
9460 "null byte (\\(aq\\e0\\(aq)."
9461 msgstr ""
9462 "B<fputs>()  は、文字列 I<s> を I<stream> に書き込む。 文字列終端の NULL バイ"
9463 "ト (\\(aq\\e0\\(aq) は出力しない。"
9464
9465 #. type: Plain text
9466 #: build/C/man3/puts.3:65
9467 msgid ""
9468 "B<putc>()  is equivalent to B<fputc>()  except that it may be implemented as "
9469 "a macro which evaluates I<stream> more than once."
9470 msgstr ""
9471 "B<putc>()  は、 I<stream> を一度以上評価するマクロとして実装されているかも知"
9472 "れないという点を除き、 B<fputc>()  と同じである。"
9473
9474 #. type: Plain text
9475 #: build/C/man3/puts.3:69
9476 msgid "B<putchar(>I<c>B<);> is equivalent to B<putc(>I<c>B<,>I<stdout>B<).>"
9477 msgstr "B<putchar(>I<c>B<);> は、 B<putc(>I<c>B<,>I<stdout>B<)> と同じである。"
9478
9479 #. type: Plain text
9480 #: build/C/man3/puts.3:76
9481 msgid "B<puts>()  writes the string I<s> and a trailing newline to I<stdout>."
9482 msgstr "B<puts>()  は、文字列 I<s> と改行を I<stdout> に書き込む。"
9483
9484 #. type: Plain text
9485 #: build/C/man3/puts.3:81
9486 msgid ""
9487 "Calls to the functions described here can be mixed with each other and with "
9488 "calls to other output functions from the I<stdio> library for the same "
9489 "output stream."
9490 msgstr ""
9491 "ここで説明された関数はお互いに混在して使用することができ、また、 I<stdio> ラ"
9492 "イブラリに含まれる他の出力関数を同じ出力ストリームに対して 呼び出す事が出来"
9493 "る。"
9494
9495 #. type: Plain text
9496 #: build/C/man3/puts.3:96
9497 msgid ""
9498 "B<fputc>(), B<putc>()  and B<putchar>()  return the character written as an "
9499 "I<unsigned char> cast to an I<int> or B<EOF> on error."
9500 msgstr ""
9501 "B<fputc>(), B<putc>(), B<putchar>()  は I<unsigned char> として書き込まれた文"
9502 "字を I<int> にキャストして返す。 エラーが発生した場合は B<EOF> を返す。"
9503
9504 #. type: Plain text
9505 #: build/C/man3/puts.3:103
9506 msgid ""
9507 "B<puts>()  and B<fputs>()  return a nonnegative number on success, or B<EOF> "
9508 "on error."
9509 msgstr ""
9510 "B<puts>()  と B<fputs>()  は、成功すると負ではない数を、エラーが発生した場合"
9511 "は B<EOF> を返す。"
9512
9513 #. type: Plain text
9514 #: build/C/man3/puts.3:112
9515 msgid ""
9516 "It is not advisable to mix calls to output functions from the I<stdio> "
9517 "library with low-level calls to B<write>(2)  for the file descriptor "
9518 "associated with the same output stream; the results will be undefined and "
9519 "very probably not what you want."
9520 msgstr ""
9521 "I<stdio> ライブラリに含まれる出力関数と、同じ出力ストリームに結びつけられた "
9522 "ファイルディスクリプタに対する B<write>(2)  の低レベル呼び出しを混在して 使用"
9523 "することは賢明ではない。 その結果は定義されておらず、望む結果が得られない可能"
9524 "性が高い。"
9525
9526 #. type: Plain text
9527 #: build/C/man3/puts.3:124
9528 msgid ""
9529 "B<write>(2), B<ferror>(3), B<fopen>(3), B<fputwc>(3), B<fputws>(3), B<fseek>"
9530 "(3), B<fwrite>(3), B<gets>(3), B<putwchar>(3), B<scanf>(3), B<unlocked_stdio>"
9531 "(3)"
9532 msgstr ""
9533 "B<write>(2), B<ferror>(3), B<fopen>(3), B<fputwc>(3), B<fputws>(3), B<fseek>"
9534 "(3), B<fwrite>(3), B<gets>(3), B<putwchar>(3), B<scanf>(3), B<unlocked_stdio>"
9535 "(3)"
9536
9537 #. type: TH
9538 #: build/C/man2/read.2:35
9539 #, no-wrap
9540 msgid "READ"
9541 msgstr "READ"
9542
9543 #. type: TH
9544 #: build/C/man2/read.2:35
9545 #, no-wrap
9546 msgid "2013-02-12"
9547 msgstr "2013-02-12"
9548
9549 #. type: Plain text
9550 #: build/C/man2/read.2:38
9551 msgid "read - read from a file descriptor"
9552 msgstr "read - ファイルディスクリプタから読み込む"
9553
9554 #. type: Plain text
9555 #: build/C/man2/read.2:43
9556 #, no-wrap
9557 msgid "B<ssize_t read(int >I<fd>B<, void *>I<buf>B<, size_t >I<count>B<);>\n"
9558 msgstr "B<ssize_t read(int >I<fd>B<, void *>I<buf>B<, size_t >I<count>B<);>\n"
9559
9560 #. type: Plain text
9561 #: build/C/man2/read.2:52
9562 msgid ""
9563 "B<read>()  attempts to read up to I<count> bytes from file descriptor I<fd> "
9564 "into the buffer starting at I<buf>."
9565 msgstr ""
9566 "B<read>()  はファイルディスクリプタ (file descriptor)  I<fd> から最大 "
9567 "I<count> バイトを I<buf> で始まるバッファーへ読み込もうとする。"
9568
9569 #. type: Plain text
9570 #: build/C/man2/read.2:60
9571 msgid ""
9572 "On files that support seeking, the read operation commences at the current "
9573 "file offset, and the file offset is incremented by the number of bytes "
9574 "read.  If the current file offset is at or past the end of file, no bytes "
9575 "are read, and B<read>()  returns zero."
9576 msgstr ""
9577
9578 #. type: Plain text
9579 #: build/C/man2/read.2:75
9580 msgid ""
9581 "If I<count> is zero, B<read>()  I<may> detect the errors described below.  "
9582 "In the absence of any errors, or if B<read>()  does not check for errors, a "
9583 "B<read>()  with a I<count> of 0 returns zero and has no other effects."
9584 msgstr ""
9585
9586 #. type: Plain text
9587 #: build/C/man2/read.2:81
9588 msgid "If I<count> is greater than B<SSIZE_MAX>, the result is unspecified."
9589 msgstr "I<count> が B<SSIZE_MAX> より大きければ、結果は規定できない。"
9590
9591 #. type: Plain text
9592 #: build/C/man2/read.2:95
9593 msgid ""
9594 "On success, the number of bytes read is returned (zero indicates end of "
9595 "file), and the file position is advanced by this number.  It is not an error "
9596 "if this number is smaller than the number of bytes requested; this may "
9597 "happen for example because fewer bytes are actually available right now "
9598 "(maybe because we were close to end-of-file, or because we are reading from "
9599 "a pipe, or from a terminal), or because B<read>()  was interrupted by a "
9600 "signal.  On error, -1 is returned, and I<errno> is set appropriately.  In "
9601 "this case it is left unspecified whether the file position (if any) changes."
9602 msgstr ""
9603 "成功した場合、読み込んだバイト数を返す (0 はファイルの終りを意味する)。 ファ"
9604 "イル位置はこの数だけ進められる。 この数が要求した数より小さかったとしてもエ"
9605 "ラーではない; 例えば今すぐには実際にそれだけの数しかない場合 (ファイルの最後"
9606 "に近いのかも しれないし、パイプ (pipe) や端末 (terminal) から読み込んでいるか"
9607 "もしれない) や B<read>()  がシグナル (signal) によって割り込まれた場合にこれ"
9608 "は起こりえる。 エラーの場合は、-1 が返され、 I<errno> が適切に設定される。こ"
9609 "の場合はファイル位置が変更されるかどうかは 不定である。"
9610
9611 #. type: TP
9612 #: build/C/man2/read.2:96 build/C/man3/scanf.3:549 build/C/man2/write.2:108
9613 #, no-wrap
9614 msgid "B<EAGAIN>"
9615 msgstr "B<EAGAIN>"
9616
9617 #. type: Plain text
9618 #: build/C/man2/read.2:103
9619 msgid ""
9620 "The file descriptor I<fd> refers to a file other than a socket and has been "
9621 "marked nonblocking (B<O_NONBLOCK>), and the read would block."
9622 msgstr ""
9623 "ファイルディスクリプタ I<fd> がソケット以外のファイルを参照していて、 非停止 "
9624 "(nonblocking) モード (B<O_NONBLOCK>)  に設定されており、読み込みを行うと停止"
9625 "する状況にある。"
9626
9627 #. type: TP
9628 #: build/C/man2/read.2:103 build/C/man2/write.2:115
9629 #, no-wrap
9630 msgid "B<EAGAIN> or B<EWOULDBLOCK>"
9631 msgstr "B<EAGAIN> または B<EWOULDBLOCK>"
9632
9633 #.  Actually EAGAIN on Linux
9634 #. type: Plain text
9635 #: build/C/man2/read.2:114
9636 msgid ""
9637 "The file descriptor I<fd> refers to a socket and has been marked nonblocking "
9638 "(B<O_NONBLOCK>), and the read would block.  POSIX.1-2001 allows either error "
9639 "to be returned for this case, and does not require these constants to have "
9640 "the same value, so a portable application should check for both "
9641 "possibilities."
9642 msgstr ""
9643 "ファイルディスクリプタ I<fd> がソケットを参照していて、非停止 (nonblocking) "
9644 "モード (B<O_NONBLOCK>)  に設定されており、読み込みを行うと停止する状況にあ"
9645 "る。 POSIX.1-2001 は、この場合にどちらのエラーを返すことも認めており、 これ"
9646 "ら 2 つの定数が同じ値を持つことも求めていない。 したがって、移植性が必要なア"
9647 "プリケーションでは、両方の可能性を 確認すべきである。"
9648
9649 #. type: Plain text
9650 #: build/C/man2/read.2:118
9651 msgid "I<fd> is not a valid file descriptor or is not open for reading."
9652 msgstr ""
9653 "I<fd> が有効なファイルディスクリプタでないか、読み込みのために オープン "
9654 "(open) されていない。"
9655
9656 #. type: Plain text
9657 #: build/C/man2/read.2:122 build/C/man2/write.2:145
9658 msgid "I<buf> is outside your accessible address space."
9659 msgstr "I<buf> がアクセス可能なアドレス空間の外にある。"
9660
9661 #. type: Plain text
9662 #: build/C/man2/read.2:126
9663 msgid ""
9664 "The call was interrupted by a signal before any data was read; see B<signal>"
9665 "(7)."
9666 msgstr ""
9667 "何のデータも読み込まないうちにシグナルに割り込まれた。 B<signal>(7)  参照。"
9668
9669 #. type: Plain text
9670 #: build/C/man2/read.2:137
9671 msgid ""
9672 "I<fd> is attached to an object which is unsuitable for reading; or the file "
9673 "was opened with the B<O_DIRECT> flag, and either the address specified in "
9674 "I<buf>, the value specified in I<count>, or the current file offset is not "
9675 "suitably aligned."
9676 msgstr ""
9677 "I<fd> は読み込みに適していないオブジェクトを参照している。 もしくは、ファイル"
9678 "が B<O_DIRECT> フラグを指定してオープンされているが、 I<buf> に指定されたアド"
9679 "レス、 I<count> に指定された値、 現在のファイルオフセットのいずれかの アライ"
9680 "ンメントが不適切である。"
9681
9682 #. type: Plain text
9683 #: build/C/man2/read.2:147
9684 msgid ""
9685 "I<fd> was created via a call to B<timerfd_create>(2)  and the wrong size "
9686 "buffer was given to B<read>(); see B<timerfd_create>(2)  for further "
9687 "information."
9688 msgstr ""
9689 "I<fd> が B<timerfd_create>(2)  の呼び出しで作成されたが、 B<read>()  に間違っ"
9690 "たサイズのバッファが渡された。 さらなる情報は B<timerfd_create>(2)  を参照の"
9691 "こと。"
9692
9693 #. type: Plain text
9694 #: build/C/man2/read.2:158
9695 msgid ""
9696 "I/O error.  This will happen for example when the process is in a background "
9697 "process group, tries to read from its controlling terminal, and either it is "
9698 "ignoring or blocking B<SIGTTIN> or its process group is orphaned.  It may "
9699 "also occur when there is a low-level I/O error while reading from a disk or "
9700 "tape."
9701 msgstr ""
9702 "I/O エラー。これは例えばプロセスがバックグランド・プロセスグループで、それを"
9703 "制御している端末から読み込もうとし、 B<SIGTTIN> が無視 (ignore) または禁止 "
9704 "(blocking) されている場合や、 そのプロセスグループが孤立 (orphan) している場"
9705 "合に起こる。 またディスクやテープを読んでいる時に低レベル I/O エラー が発生し"
9706 "た場合にも起こる。"
9707
9708 #. type: Plain text
9709 #: build/C/man2/read.2:162
9710 msgid "I<fd> refers to a directory."
9711 msgstr "I<fd> がディレクトリを参照している。"
9712
9713 #. type: Plain text
9714 #: build/C/man2/read.2:173
9715 msgid ""
9716 "Other errors may occur, depending on the object connected to I<fd>.  POSIX "
9717 "allows a B<read>()  that is interrupted after reading some data to return -1 "
9718 "(with I<errno> set to B<EINTR>)  or to return the number of bytes already "
9719 "read."
9720 msgstr ""
9721 "I<fd> が接続しているオブジェクトによっては他のエラーも起こりえる。 POSIX で"
9722 "は、 いくらかのデータを読んだ後に割り込みが起こった場合、 B<read>()  は "
9723 "(I<errno> に B<EINTR> を設定して) -1 を返してもよいし、 既に読み込んだバイト"
9724 "数を返してもよい。"
9725
9726 #. type: Plain text
9727 #: build/C/man2/read.2:187
9728 #, fuzzy
9729 #| msgid ""
9730 #| "On NFS file systems, reading small amounts of data will only update the "
9731 #| "timestamp the first time, subsequent calls may not do so.  This is caused "
9732 #| "by client side attribute caching, because most if not all NFS clients "
9733 #| "leave st_atime (last file access time)  updates to the server and client "
9734 #| "side reads satisfied from the client's cache will not cause st_atime "
9735 #| "updates on the server as there are no server side reads.  UNIX semantics "
9736 #| "can be obtained by disabling client side attribute caching, but in most "
9737 #| "situations this will substantially increase server load and decrease "
9738 #| "performance."
9739 msgid ""
9740 "On NFS file systems, reading small amounts of data will update the timestamp "
9741 "only the first time, subsequent calls may not do so.  This is caused by "
9742 "client side attribute caching, because most if not all NFS clients leave "
9743 "st_atime (last file access time)  updates to the server and client side "
9744 "reads satisfied from the client's cache will not cause st_atime updates on "
9745 "the server as there are no server side reads.  UNIX semantics can be "
9746 "obtained by disabling client side attribute caching, but in most situations "
9747 "this will substantially increase server load and decrease performance."
9748 msgstr ""
9749 "NFS において。少量のデータを読み込む場合、最初の時のみにタイム スタンプが更新"
9750 "され、続くコールでは更新されないだろう。 これはクライアント側で属性のキャッシ"
9751 "ングを行なうためである。 なぜならば、もし全ての NFS クライアントが st_atime "
9752 "(最終ファイルアクセス時刻)  の更新をサーバーに送らず、クライアント側でキャッ"
9753 "シュを読むことに満足して いれば、サーバー側での read は発生しないので "
9754 "st_atime の更新は行なわれからだ。 UNIX の方式では、クライアント側の属性の"
9755 "キャッシングを無効にすることで、 これを得ることができる。しかしほとんどの状況"
9756 "ではこれは続くサーバーの 負荷を増加させ、パフォーマンスの低下をもたらす。"
9757
9758 #. type: Plain text
9759 #: build/C/man2/read.2:200
9760 msgid ""
9761 "B<close>(2), B<fcntl>(2), B<ioctl>(2), B<lseek>(2), B<open>(2), B<pread>(2), "
9762 "B<readdir>(2), B<readlink>(2), B<readv>(2), B<select>(2), B<write>(2), "
9763 "B<fread>(3)"
9764 msgstr ""
9765 "B<close>(2), B<fcntl>(2), B<ioctl>(2), B<lseek>(2), B<open>(2), B<pread>(2), "
9766 "B<readdir>(2), B<readlink>(2), B<readv>(2), B<select>(2), B<write>(2), "
9767 "B<fread>(3)"
9768
9769 #. type: TH
9770 #: build/C/man2/readlink.2:43
9771 #, no-wrap
9772 msgid "READLINK"
9773 msgstr "READLINK"
9774
9775 #. type: TH
9776 #: build/C/man2/readlink.2:43
9777 #, no-wrap
9778 msgid "2011-09-20"
9779 msgstr "2011-09-20"
9780
9781 #. type: Plain text
9782 #: build/C/man2/readlink.2:46
9783 msgid "readlink - read value of a symbolic link"
9784 msgstr "readlink - シンボリックリンクの値を読む"
9785
9786 #. type: Plain text
9787 #: build/C/man2/readlink.2:50
9788 msgid ""
9789 "B<ssize_t readlink(const char *>I<path>B<, char *>I<buf>B<, size_t "
9790 ">I<bufsiz>B<);>"
9791 msgstr ""
9792 "B<ssize_t readlink(const char *>I<path>B<, char *>I<buf>B<, size_t "
9793 ">I<bufsiz>B<);>"
9794
9795 #. type: Plain text
9796 #: build/C/man2/readlink.2:58
9797 msgid "B<readlink>():"
9798 msgstr "B<readlink>():"
9799
9800 #. type: Plain text
9801 #: build/C/man2/readlink.2:61 build/C/man2/symlink.2:50
9802 msgid ""
9803 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
9804 "_XOPEN_SOURCE_EXTENDED || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
9805 msgstr ""
9806 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
9807 "_XOPEN_SOURCE_EXTENDED || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
9808
9809 #. type: Plain text
9810 #: build/C/man2/readlink.2:77
9811 msgid ""
9812 "B<readlink>()  places the contents of the symbolic link I<path> in the "
9813 "buffer I<buf>, which has size I<bufsiz>.  B<readlink>()  does not append a "
9814 "null byte to I<buf>.  It will truncate the contents (to a length of "
9815 "I<bufsiz> characters), in case the buffer is too small to hold all of the "
9816 "contents."
9817 msgstr ""
9818 "B<readlink>()  は I<path> で与えられたシンボリックリンクの内容を I<buf> バッ"
9819 "ファーへ格納する、 I<buf> のサイズは I<bufsiz> である。 B<readlink>()  は "
9820 "NULL バイトを I<buf> に追加しない。 その内容全てを格納するのにバッファーが小"
9821 "さ過ぎる場合は、 (I<bufsiz> バイトの長さに) 内容を切り詰める。"
9822
9823 #. type: Plain text
9824 #: build/C/man2/readlink.2:85
9825 msgid ""
9826 "On success, B<readlink>()  returns the number of bytes placed in I<buf>.  On "
9827 "error, -1 is returned and I<errno> is set to indicate the error."
9828 msgstr ""
9829 "成功すると、 B<readlink>()  は I<buf> に格納されたバイト数を返す。 エラーの場"
9830 "合、-1 を返し、 I<errno> にエラーを示す値を設定する。"
9831
9832 #. type: Plain text
9833 #: build/C/man2/readlink.2:91
9834 msgid ""
9835 "Search permission is denied for a component of the path prefix.  (See also "
9836 "B<path_resolution>(7).)"
9837 msgstr ""
9838 "パスのディレクトリ部分に検索許可が与えられていない (B<path_resolution>(7)  も"
9839 "参照すること)。"
9840
9841 #. type: Plain text
9842 #: build/C/man2/readlink.2:95
9843 msgid "I<buf> extends outside the process's allocated address space."
9844 msgstr "I<buf> がプロセスに割り当てられたアドレス空間の外を指している。"
9845
9846 #.  At the glibc level, bufsiz is unsigned, so this error can only occur
9847 #.  if bufsiz==0.  However, the in the kernel syscall, bufsiz is signed,
9848 #.  and this error can also occur if bufsiz < 0.
9849 #.  See: http://thread.gmane.org/gmane.linux.man/380
9850 #.  Subject: [patch 0/3] [RFC] kernel/glibc mismatch of "readlink" syscall?
9851 #. type: Plain text
9852 #: build/C/man2/readlink.2:104
9853 msgid "I<bufsiz> is not positive."
9854 msgstr "I<bufsiz> が正でない。"
9855
9856 #. type: Plain text
9857 #: build/C/man2/readlink.2:107
9858 msgid "The named file is not a symbolic link."
9859 msgstr "指定したファイルがシンボリックリンクでない。"
9860
9861 #. type: Plain text
9862 #: build/C/man2/readlink.2:110
9863 msgid "An I/O error occurred while reading from the file system."
9864 msgstr "ファイルシステムの読み込み中に I/O エラーが起こった。"
9865
9866 #. type: Plain text
9867 #: build/C/man2/readlink.2:113
9868 msgid "Too many symbolic links were encountered in translating the pathname."
9869 msgstr "パス名にシンボリックリンクが多すぎる。"
9870
9871 #. type: Plain text
9872 #: build/C/man2/readlink.2:116
9873 msgid "A pathname, or a component of a pathname, was too long."
9874 msgstr "パス名かパス名の一部分が長過ぎる。"
9875
9876 #. type: Plain text
9877 #: build/C/man2/readlink.2:119
9878 msgid "The named file does not exist."
9879 msgstr "その名前のファイルが存在しない。"
9880
9881 #. type: Plain text
9882 #: build/C/man2/readlink.2:125
9883 msgid "A component of the path prefix is not a directory."
9884 msgstr "パスのディレクトリ部分がディレクトリでない。"
9885
9886 #. type: Plain text
9887 #: build/C/man2/readlink.2:130
9888 msgid "4.4BSD (B<readlink>()  first appeared in 4.2BSD), POSIX.1-2001."
9889 msgstr "4.4BSD (B<readlink>()  は 4.2BSD で初めて登場した), POSIX.1-2001."
9890
9891 #. type: Plain text
9892 #: build/C/man2/readlink.2:138
9893 msgid ""
9894 "In versions of glibc up to and including glibc 2.4, the return type of "
9895 "B<readlink>()  was declared as I<int>.  Nowadays, the return type is "
9896 "declared as I<ssize_t>, as (newly) required in POSIX.1-2001."
9897 msgstr ""
9898 "バージョン 2.4 以前の glibc (バージョン 2.4 を含む) では、 B<readlink>()  の"
9899 "返り値の型は I<int> で宣言されていた。現在では、返り値の型は I<ssize_t> であ"
9900 "る (返り値 I<ssize_t> は POSIX.1-2001 で (新たに) 必須となった)。"
9901
9902 #. type: Plain text
9903 #: build/C/man2/readlink.2:157
9904 msgid ""
9905 "Using a statically sized buffer might not provide enough room for the "
9906 "symbolic link contents.  The required size for the buffer can be obtained "
9907 "from the I<stat.st_size> value returned by a call to B<lstat>(2)  on the "
9908 "link.  However, the number of bytes written by B<readlink>()  should be "
9909 "checked to make sure that the size of the symbolic link did not increase "
9910 "between the calls.  Dynamically allocating the buffer for B<readlink>()  "
9911 "also addresses a common portability problem when using I<PATH_MAX> for the "
9912 "buffer size, as this constant is not guaranteed to be defined per POSIX if "
9913 "the system does not have such limit."
9914 msgstr ""
9915 "静的な大きさのバッファを使うと、シンボリックリンクの内容を\n"
9916 "格納するのに十分な領域がない場合がある。\n"
9917 "バッファに必要なサイズは、そのシンボリックリンクに対して B<lstat>(2)\n"
9918 "の呼び出しで返される I<stat.st_size> の値から取得できる。\n"
9919 "ただし、 B<readlink>() が書き込んだバイト数をチェックして、\n"
9920 "シンボリックリンクのサイズが B<lstat>(2) と B<readlink>() の呼び出し\n"
9921 "の間で増えていないことを確認すべきである。\n"
9922 "B<readlink>() 用のバッファを動的に割り当てる方法でも、\n"
9923 "バッファサイズとして I<PATH_MAX> を使用する場合に共通する移植性の\n"
9924 "問題を解決することができる。なぜなら、POSIX では、\n"
9925 "システムがそのような上限値を定義していない場合には、\n"
9926 "I<PATH_MAX> が定義されることが保証されていないからである。"
9927
9928 #. type: Plain text
9929 #: build/C/man2/readlink.2:163
9930 msgid ""
9931 "The following program allocates the buffer needed by B<readlink>()  "
9932 "dynamically from the information provided by B<lstat>(), making sure there's "
9933 "no race condition between the calls."
9934 msgstr ""
9935 "以下のプログラムは、 B<readlink>() が必要とするバッファを、\n"
9936 "B<lstat>() が提供する情報に基づいて動的に割り当てる。\n"
9937 "また、両方の呼び出し間で競合条件がないことを保証している。"
9938
9939 #. type: Plain text
9940 #: build/C/man2/readlink.2:170
9941 #, no-wrap
9942 msgid ""
9943 "#include E<lt>sys/types.hE<gt>\n"
9944 "#include E<lt>sys/stat.hE<gt>\n"
9945 "#include E<lt>stdio.hE<gt>\n"
9946 "#include E<lt>stdlib.hE<gt>\n"
9947 "#include E<lt>unistd.hE<gt>\n"
9948 msgstr ""
9949 "#include E<lt>sys/types.hE<gt>\n"
9950 "#include E<lt>sys/stat.hE<gt>\n"
9951 "#include E<lt>stdio.hE<gt>\n"
9952 "#include E<lt>stdlib.hE<gt>\n"
9953 "#include E<lt>unistd.hE<gt>\n"
9954
9955 #. type: Plain text
9956 #: build/C/man2/readlink.2:177
9957 #, no-wrap
9958 msgid ""
9959 "int\n"
9960 "main(int argc, char *argv[])\n"
9961 "{\n"
9962 "    struct stat sb;\n"
9963 "    char *linkname;\n"
9964 "    ssize_t r;\n"
9965 msgstr ""
9966 "int\n"
9967 "main(int argc, char *argv[])\n"
9968 "{\n"
9969 "    struct stat sb;\n"
9970 "    char *linkname;\n"
9971 "    ssize_t r;\n"
9972
9973 #. type: Plain text
9974 #: build/C/man2/readlink.2:182
9975 #, no-wrap
9976 msgid ""
9977 "    if (argc != 2) {\n"
9978 "        fprintf(stderr, \"Usage: %s E<lt>pathnameE<gt>\\en\", argv[0]);\n"
9979 "        exit(EXIT_FAILURE);\n"
9980 "    }\n"
9981 msgstr ""
9982 "    if (argc != 2) {\n"
9983 "        fprintf(stderr, \"Usage: %s E<lt>pathnameE<gt>\\en\", argv[0]);\n"
9984 "        exit(EXIT_FAILURE);\n"
9985 "    }\n"
9986
9987 #. type: Plain text
9988 #: build/C/man2/readlink.2:187
9989 #, no-wrap
9990 msgid ""
9991 "    if (lstat(argv[1], &sb) == -1) {\n"
9992 "        perror(\"lstat\");\n"
9993 "        exit(EXIT_FAILURE);\n"
9994 "    }\n"
9995 msgstr ""
9996 "    if (lstat(argv[1], &sb) == -1) {\n"
9997 "        perror(\"lstat\");\n"
9998 "        exit(EXIT_FAILURE);\n"
9999 "    }\n"
10000
10001 #. type: Plain text
10002 #: build/C/man2/readlink.2:193
10003 #, no-wrap
10004 msgid ""
10005 "    linkname = malloc(sb.st_size + 1);\n"
10006 "    if (linkname == NULL) {\n"
10007 "        fprintf(stderr, \"insufficient memory\\en\");\n"
10008 "        exit(EXIT_FAILURE);\n"
10009 "    }\n"
10010 msgstr ""
10011 "    linkname = malloc(sb.st_size + 1);\n"
10012 "    if (linkname == NULL) {\n"
10013 "        fprintf(stderr, \"insufficient memory\\en\");\n"
10014 "        exit(EXIT_FAILURE);\n"
10015 "    }\n"
10016
10017 #. type: Plain text
10018 #: build/C/man2/readlink.2:195
10019 #, no-wrap
10020 msgid "    r = readlink(argv[1], linkname, sb.st_size + 1);\n"
10021 msgstr "    r = readlink(argv[1], linkname, sb.st_size + 1);\n"
10022
10023 #. type: Plain text
10024 #: build/C/man2/readlink.2:200
10025 #, no-wrap
10026 msgid ""
10027 "    if (r E<lt> 0) {\n"
10028 "        perror(\"lstat\");\n"
10029 "        exit(EXIT_FAILURE);\n"
10030 "    }\n"
10031 msgstr ""
10032 "    if (r E<lt> 0) {\n"
10033 "        perror(\"lstat\");\n"
10034 "        exit(EXIT_FAILURE);\n"
10035 "    }\n"
10036
10037 #. type: Plain text
10038 #: build/C/man2/readlink.2:206
10039 #, no-wrap
10040 msgid ""
10041 "    if (r E<gt> sb.st_size) {\n"
10042 "        fprintf(stderr, \"symlink increased in size \"\n"
10043 "                        \"between lstat() and readlink()\\en\");\n"
10044 "        exit(EXIT_FAILURE);\n"
10045 "    }\n"
10046 msgstr ""
10047 "    if (r E<gt> sb.st_size) {\n"
10048 "        fprintf(stderr, \"symlink increased in size \"\n"
10049 "                        \"between lstat() and readlink()\\en\");\n"
10050 "        exit(EXIT_FAILURE);\n"
10051 "    }\n"
10052
10053 #. type: Plain text
10054 #: build/C/man2/readlink.2:208
10055 #, no-wrap
10056 msgid "    linkname[sb.st_size] = \\(aq\\e0\\(aq;\n"
10057 msgstr "    linkname[sb.st_size] = \\(aq\\e0\\(aq;\n"
10058
10059 #. type: Plain text
10060 #: build/C/man2/readlink.2:210
10061 #, no-wrap
10062 msgid "    printf(\"\\(aq%s\\(aq points to \\(aq%s\\(aq\\en\", argv[1], linkname);\n"
10063 msgstr "    printf(\"\\(aq%s\\(aq points to \\(aq%s\\(aq\\en\", argv[1], linkname);\n"
10064
10065 #. type: Plain text
10066 #: build/C/man2/readlink.2:222
10067 msgid ""
10068 "B<readlink>(1), B<lstat>(2), B<readlinkat>(2), B<stat>(2), B<symlink>(2), "
10069 "B<path_resolution>(7), B<symlink>(7)"
10070 msgstr ""
10071 "B<readlink>(1), B<lstat>(2), B<readlinkat>(2), B<stat>(2), B<symlink>(2),\n"
10072 "B<path_resolution>(7), B<symlink>(7)"
10073
10074 #. type: TH
10075 #: build/C/man2/readv.2:32
10076 #, no-wrap
10077 msgid "READV"
10078 msgstr "READV"
10079
10080 #. type: TH
10081 #: build/C/man2/readv.2:32
10082 #, no-wrap
10083 msgid "2010-11-17"
10084 msgstr "2010-11-17"
10085
10086 #. type: Plain text
10087 #: build/C/man2/readv.2:35
10088 msgid ""
10089 "readv, writev, preadv, pwritev - read or write data into multiple buffers"
10090 msgstr "readv, writev, preadv, pwritev - 複数のバッファへの読み書きを行なう"
10091
10092 #. type: Plain text
10093 #: build/C/man2/readv.2:38
10094 #, no-wrap
10095 msgid "B<#include E<lt>sys/uio.hE<gt>>\n"
10096 msgstr "B<#include E<lt>sys/uio.hE<gt>>\n"
10097
10098 #. type: Plain text
10099 #: build/C/man2/readv.2:40
10100 #, no-wrap
10101 msgid "B<ssize_t readv(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<);>\n"
10102 msgstr "B<ssize_t readv(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<);>\n"
10103
10104 #. type: Plain text
10105 #: build/C/man2/readv.2:42
10106 #, no-wrap
10107 msgid "B<ssize_t writev(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<);>\n"
10108 msgstr "B<ssize_t writev(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<);>\n"
10109
10110 #. type: Plain text
10111 #: build/C/man2/readv.2:45
10112 #, no-wrap
10113 msgid ""
10114 "B<ssize_t preadv(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<,>\n"
10115 "B<               off_t >I<offset>B<);>\n"
10116 msgstr ""
10117 "B<ssize_t preadv(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<,>\n"
10118 "B<               off_t >I<offset>B<);>\n"
10119
10120 #. type: Plain text
10121 #: build/C/man2/readv.2:48
10122 #, no-wrap
10123 msgid ""
10124 "B<ssize_t pwritev(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<,>\n"
10125 "B<                off_t >I<offset>B<);>\n"
10126 msgstr ""
10127 "B<ssize_t pwritev(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<,>\n"
10128 "B<                off_t >I<offset>B<);>\n"
10129
10130 #. type: Plain text
10131 #: build/C/man2/readv.2:58
10132 msgid "B<preadv>(), B<pwritev>(): _BSD_SOURCE"
10133 msgstr "B<preadv>(), B<pwritev>(): _BSD_SOURCE"
10134
10135 #. type: Plain text
10136 #: build/C/man2/readv.2:68
10137 msgid ""
10138 "The B<readv>()  system call reads I<iovcnt> buffers from the file associated "
10139 "with the file descriptor I<fd> into the buffers described by I<iov> "
10140 "(\"scatter input\")."
10141 msgstr ""
10142 "B<readv>() システムコールは、ファイルディスクリプタ I<fd> に関連付けられた\n"
10143 "ファイルから、 I<iovcnt> 個のバッファ分のデータを読み込み、 I<iov> で指定\n"
10144 "されたバッファに格納する (\"scatter input\";「ばらまき入力」)。"
10145
10146 #. type: Plain text
10147 #: build/C/man2/readv.2:78
10148 msgid ""
10149 "The B<writev>()  system call writes I<iovcnt> buffers of data described by "
10150 "I<iov> to the file associated with the file descriptor I<fd> (\"gather output"
10151 "\")."
10152 msgstr ""
10153 "B<writev>() システムコールは、 I<iov> で指定されたバッファから最大 "
10154 "I<iovcnt>\n"
10155 "個のバッファ分のデータを取り出し、 ファイルディスクリプタ I<fd> に関連付け"
10156 "ら\n"
10157 "れたファイルに書き込む (\"gather output\";「かき集め出力」)。"
10158
10159 #. type: Plain text
10160 #: build/C/man2/readv.2:87
10161 msgid ""
10162 "The pointer I<iov> points to an array of I<iovec> structures, defined in "
10163 "I<E<lt>sys/uio.hE<gt>> as:"
10164 msgstr ""
10165 "ポインタ I<iov> は I<iovec> 構造体の配列へのポインタである。 I<iovec> 構造体"
10166 "は I<E<lt>sys/uio.hE<gt>> で以下のように定義されている:"
10167
10168 #. type: Plain text
10169 #: build/C/man2/readv.2:95
10170 #, no-wrap
10171 msgid ""
10172 "struct iovec {\n"
10173 "    void  *iov_base;    /* Starting address */\n"
10174 "    size_t iov_len;     /* Number of bytes to transfer */\n"
10175 "};\n"
10176 msgstr ""
10177 "struct iovec {\n"
10178 "    void  *iov_base;    /* Starting address */\n"
10179 "    size_t iov_len;     /* Number of bytes to transfer */\n"
10180 "};\n"
10181
10182 #. type: Plain text
10183 #: build/C/man2/readv.2:103
10184 msgid ""
10185 "The B<readv>()  system call works just like B<read>(2)  except that multiple "
10186 "buffers are filled."
10187 msgstr ""
10188 "B<readv>() システムコールは、複数のバッファにデータを読み込む点を除いて\n"
10189 "B<read>(2) と全く同様の動作を行う。"
10190
10191 #. type: Plain text
10192 #: build/C/man2/readv.2:109
10193 msgid ""
10194 "The B<writev>()  system call works just like B<write>(2)  except that "
10195 "multiple buffers are written out."
10196 msgstr ""
10197 "B<writev>() システムコールは、複数のバッファのデータを書き出す点以外は\n"
10198 "B<write>(2) と全く同様の動作を行う。"
10199
10200 #. type: Plain text
10201 #: build/C/man2/readv.2:128
10202 msgid ""
10203 "Buffers are processed in array order.  This means that B<readv>()  "
10204 "completely fills I<iov>[0] before proceeding to I<iov>[1], and so on.  (If "
10205 "there is insufficient data, then not all buffers pointed to by I<iov> may be "
10206 "filled.)  Similarly, B<writev>()  writes out the entire contents of I<iov>"
10207 "[0] before proceeding to I<iov>[1], and so on."
10208 msgstr ""
10209 "バッファは配列の順序で処理される。これは、 B<readv>()  が I<iov>[0] が完全に"
10210 "一杯になるまでデータを詰めてから、 I<iov>[1] などに進むことを意味する (データ"
10211 "が十分ない場合は、 I<iov> が指すバッファのいずれも一杯にならない)。 同様に、 "
10212 "B<writev>()  は I<iov>[0] の内容を全部書き出してから I<iov>[1] などに進む。"
10213
10214 #. type: Plain text
10215 #: build/C/man2/readv.2:146
10216 msgid ""
10217 "The data transfers performed by B<readv>()  and B<writev>()  are atomic: the "
10218 "data written by B<writev>()  is written as a single block that is not "
10219 "intermingled with output from writes in other processes (but see B<pipe>(7)  "
10220 "for an exception); analogously, B<readv>()  is guaranteed to read a "
10221 "contiguous block of data from the file, regardless of read operations "
10222 "performed in other threads or processes that have file descriptors referring "
10223 "to the same open file description (see B<open>(2))."
10224 msgstr ""
10225 "B<readv>()  と B<writev>()  によるデータ転送は atomic に行われる。つまり、 "
10226 "B<writev>()  によるデータ書き込みは一つのブロックとして行われ、他のプロセス"
10227 "の write による書き込みと混ざり合うことはない (例外に関しては B<pipe>(7)  を"
10228 "参照のこと)。同様に、 B<readv>()  はファイルから連続するデータブロックが読み"
10229 "出すことが保証され、 同じファイル記述 (file description; B<open>(2)  参照) を"
10230 "参照するファイルディスクリプタを持つ他のスレッドやプロセスが 実行した read 操"
10231 "作の影響を受けることはない。"
10232
10233 #. type: SS
10234 #: build/C/man2/readv.2:146
10235 #, no-wrap
10236 msgid "preadv() and pwritev()"
10237 msgstr "preadv() と pwritev()"
10238
10239 #. type: Plain text
10240 #: build/C/man2/readv.2:159
10241 msgid ""
10242 "The B<preadv>()  system call combines the functionality of B<readv>()  and "
10243 "B<pread>(2).  It performs the same task as B<readv>(), but adds a fourth "
10244 "argument, I<offset>, which specifies the file offset at which the input "
10245 "operation is to be performed."
10246 msgstr ""
10247 "B<preadv>() システムコールは B<readv>() と B<preadv>(2) の機能を\n"
10248 "組み合わせたものである。\n"
10249 "B<readv>() と同じ処理を実行するが、\n"
10250 "4 番目の引き数 I<offset> が追加されており、\n"
10251 "この引き数は入力操作を行うファイルオフセットを指定する。"
10252
10253 #. type: Plain text
10254 #: build/C/man2/readv.2:172
10255 msgid ""
10256 "The B<pwritev>()  system call combines the functionality of B<writev>()  and "
10257 "B<pwrite>(2).  It performs the same task as B<writev>(), but adds a fourth "
10258 "argument, I<offset>, which specifies the file offset at which the output "
10259 "operation is to be performed."
10260 msgstr ""
10261 "B<pwritev>() システムコールは B<writev>() と B<pwrite>(2) の機能を\n"
10262 "組み合わせたものである。\n"
10263 "B<writev>() と同じ処理を実行するが、\n"
10264 "4 番目の引き数 I<offset> が追加されており、\n"
10265 "この引き数は出力操作を行うファイルオフセットを指定する。"
10266
10267 #. type: Plain text
10268 #: build/C/man2/readv.2:177
10269 msgid ""
10270 "The file offset is not changed by these system calls.  The file referred to "
10271 "by I<fd> must be capable of seeking."
10272 msgstr ""
10273 "これらのシステムコールで、ファイルオフセットは変更されない。\n"
10274 "I<fd> が参照するファイルは seek 可能でなければならない。"
10275
10276 #. type: Plain text
10277 #: build/C/man2/readv.2:188
10278 msgid ""
10279 "On success, B<readv>()  and B<preadv>()  return the number of bytes read; "
10280 "B<writev>()  and B<pwritev>()  return the number of bytes written.  On "
10281 "error, -1 is returned, and I<errno> is set appropriately."
10282 msgstr ""
10283 "成功した場合、 B<readv>() と B<preadv> は読み込んだバイト数を返し、\n"
10284 "B<writev>() と B<pwritev>()は書き込んだバイト数を返す。\n"
10285 "エラーの場合 -1 を返し、I<errno> を適切に設定する。"
10286
10287 #. type: Plain text
10288 #: build/C/man2/readv.2:200
10289 msgid ""
10290 "The errors are as given for B<read>(2)  and B<write>(2).  Furthermore, "
10291 "B<preadv>()  and B<pwritev>()  can also fail for the same reasons as B<lseek>"
10292 "(2).  Additionally, the following error is defined:"
10293 msgstr ""
10294 "B<read>(2)  や B<write>(2)  と同じエラーが定義されている。\n"
10295 "さらに、 B<preadv>() と B<pwritev>() は B<lseek>(2) と同じ理由でも失敗す"
10296 "る。\n"
10297 "また、追加で以下のエラーが定義されている:"
10298
10299 #. type: Plain text
10300 #: build/C/man2/readv.2:209
10301 msgid ""
10302 "The sum of the I<iov_len> values overflows an I<ssize_t> value.  Or, the "
10303 "vector count I<iovcnt> is less than zero or greater than the permitted "
10304 "maximum."
10305 msgstr ""
10306 "I<iov_len> の合計が I<ssize_t> の範囲をオーバーフローした。もしくは、 ベクタ"
10307 "数 I<iovcnt> が 0 より小さいか許可された最大値よりも大きかった。"
10308
10309 #. type: Plain text
10310 #: build/C/man2/readv.2:214
10311 msgid ""
10312 "B<preadv>()  and B<pwritev>()  first appeared in Linux 2.6.30; library "
10313 "support was added in glibc 2.10."
10314 msgstr ""
10315 "B<preadv>() と B<pwritev>() は Linux 2.6.30 で初めて登場した。\n"
10316 "ライブラリによるサポートは glibc 2.10 で追加された。"
10317
10318 #.  The readv/writev system calls were buggy before Linux 1.3.40.
10319 #.  (Says release.libc.)
10320 #. type: Plain text
10321 #: build/C/man2/readv.2:222
10322 msgid ""
10323 "B<readv>(), B<writev>(): 4.4BSD (these system calls first appeared in "
10324 "4.2BSD), POSIX.1-2001.  Linux libc5 used I<size_t> as the type of the "
10325 "I<iovcnt> argument, and I<int> as the return type."
10326 msgstr ""
10327 "B<readv>(), B<writev>(): \n"
10328 "4.4BSD (これらのシステムコールは 4.2BSD で最初に現われた)、POSIX.1-2001。 \n"
10329 "Linux libc5 では、 I<iovcnt> 引き数の型として I<size_t> を、\n"
10330 "返り値の型として I<int> を使用していた。"
10331
10332 #. type: Plain text
10333 #: build/C/man2/readv.2:226
10334 msgid ""
10335 "B<preadv>(), B<pwritev>(): nonstandard, but present also on the modern BSDs."
10336 msgstr "B<preadv>(), B<pwritev>(): 非標準だが、最近の BSD にも存在する。"
10337
10338 #. type: SS
10339 #: build/C/man2/readv.2:227
10340 #, no-wrap
10341 msgid "Linux notes"
10342 msgstr "Linux での注意"
10343
10344 #. type: Plain text
10345 #: build/C/man2/readv.2:258
10346 msgid ""
10347 "POSIX.1-2001 allows an implementation to place a limit on the number of "
10348 "items that can be passed in I<iov>.  An implementation can advertise its "
10349 "limit by defining B<IOV_MAX> in I<E<lt>limits.hE<gt>> or at run time via the "
10350 "return value from I<sysconf(_SC_IOV_MAX)>.  On Linux, the limit advertised "
10351 "by these mechanisms is 1024, which is the true kernel limit.  However, the "
10352 "glibc wrapper functions do some extra work if they detect that the "
10353 "underlying kernel system call failed because this limit was exceeded.  In "
10354 "the case of B<readv>()  the wrapper function allocates a temporary buffer "
10355 "large enough for all of the items specified by I<iov>, passes that buffer in "
10356 "a call to B<read>(2), copies data from the buffer to the locations specified "
10357 "by the I<iov_base> fields of the elements of I<iov>, and then frees the "
10358 "buffer.  The wrapper function for B<writev>()  performs the analogous task "
10359 "using a temporary buffer and a call to B<write>(2)."
10360 msgstr ""
10361 "POSIX.1-2001 では、 I<iov> で渡すことができる要素数に上限を設ける実装が認めら"
10362 "れている。 実装は、 I<E<lt>limits.hE<gt>> の B<IOV_MAX> を定義することや、実"
10363 "行時に I<sysconf(_SC_IOV_MAX)> の返り値経由で、この上限を広告することができ"
10364 "る。 Linux では、この仕組みにより広告される上限は 1024 であり、 この値はカー"
10365 "ネルでの上限そのものである。 一方で、glibc のラッパー関数は、その関数の内部で"
10366 "呼ばれるカーネル システムコールがこの上限を超過して失敗したことを検出する"
10367 "と、 追加の動作をする。 B<readv>()  の場合、ラッパー関数は I<iov> で指定され"
10368 "た全ての要素を格納できる大きさの一時バッファを割り当て、 B<read>(2)  を呼び出"
10369 "す際にそのバッファを渡し、 そのバッファのデータを I<iov> の各要素の "
10370 "I<iov_base> フィールドが指定する場所にコピーしてから、 そのバッファを解放す"
10371 "る。 B<writev>()  のラッパー関数も、同じように一時バッファを使って B<write>"
10372 "(2)  を呼び出す。"
10373
10374 #. type: Plain text
10375 #: build/C/man2/readv.2:265
10376 msgid ""
10377 "It is not advisable to mix calls to B<readv>()  or B<writev>(), which "
10378 "operate on file descriptors, with the functions from the stdio library; the "
10379 "results will be undefined and probably not what you want."
10380 msgstr ""
10381 "ファイルディスクリプタに対する操作を行う B<readv>() や B<writev>() と、\n"
10382 "標準入出力ライブラリの関数をごちゃまぜにして呼ぶのはお薦めしない。\n"
10383 "どんな結果になるかは定義されておらず、おそらく期待する結果は\n"
10384 "得られないだろう。"
10385
10386 #. type: Plain text
10387 #: build/C/man2/readv.2:268
10388 msgid "The following code sample demonstrates the use of B<writev>():"
10389 msgstr "以下のサンプルコードは B<writev>()  の使用方法を示すものである。"
10390
10391 #. type: Plain text
10392 #: build/C/man2/readv.2:275
10393 #, no-wrap
10394 msgid ""
10395 "char *str0 = \"hello \";\n"
10396 "char *str1 = \"world\\en\";\n"
10397 "struct iovec iov[2];\n"
10398 "ssize_t nwritten;\n"
10399 msgstr ""
10400 "char *str0 = \"hello \";\n"
10401 "char *str1 = \"world\\en\";\n"
10402 "struct iovec iov[2];\n"
10403 "ssize_t nwritten;\n"
10404
10405 #. type: Plain text
10406 #: build/C/man2/readv.2:280
10407 #, no-wrap
10408 msgid ""
10409 "iov[0].iov_base = str0;\n"
10410 "iov[0].iov_len = strlen(str0);\n"
10411 "iov[1].iov_base = str1;\n"
10412 "iov[1].iov_len = strlen(str1);\n"
10413 msgstr ""
10414 "iov[0].iov_base = str0;\n"
10415 "iov[0].iov_len = strlen(str0);\n"
10416 "iov[1].iov_base = str1;\n"
10417 "iov[1].iov_len = strlen(str1);\n"
10418
10419 #. type: Plain text
10420 #: build/C/man2/readv.2:282
10421 #, no-wrap
10422 msgid "nwritten = writev(STDOUT_FILENO, iov, 2);\n"
10423 msgstr "nwritten = writev(STDOUT_FILENO, iov, 2);\n"
10424
10425 #. type: Plain text
10426 #: build/C/man2/readv.2:288
10427 msgid "B<pread>(2), B<read>(2), B<write>(2)"
10428 msgstr "B<pread>(2), B<read>(2), B<write>(2)"
10429
10430 #. type: TH
10431 #: build/C/man3/remove.3:31
10432 #, no-wrap
10433 msgid "REMOVE"
10434 msgstr "REMOVE"
10435
10436 #. type: TH
10437 #: build/C/man3/remove.3:31
10438 #, no-wrap
10439 msgid "2008-12-03"
10440 msgstr "2008-12-03"
10441
10442 #. type: Plain text
10443 #: build/C/man3/remove.3:34
10444 msgid "remove - remove a file or directory"
10445 msgstr "remove - ファイルやディレクトリを削除する"
10446
10447 #. type: Plain text
10448 #: build/C/man3/remove.3:38
10449 msgid "B<int remove(const char *>I<pathname>B<);>"
10450 msgstr "B<int remove(const char *>I<pathname>B<);>"
10451
10452 #. type: Plain text
10453 #: build/C/man3/remove.3:46
10454 msgid ""
10455 "B<remove>()  deletes a name from the file system.  It calls B<unlink>(2)  "
10456 "for files, and B<rmdir>(2)  for directories."
10457 msgstr ""
10458 "B<remove>()  はファイルシステムからファイル名を削除する。 ファイルに対しては "
10459 "B<unlink>(2)  を、ディレクトリに対しては B<rmdir>(2)  を呼び出す。"
10460
10461 #. type: Plain text
10462 #: build/C/man3/remove.3:50
10463 msgid ""
10464 "If the removed name was the last link to a file and no processes have the "
10465 "file open, the file is deleted and the space it was using is made available "
10466 "for reuse."
10467 msgstr ""
10468 "もしその名前が ファイルへの最後のリンクで、かつ、どのプロセスもそのファイル"
10469 "を 開いていないなら、ファイルも削除する。ファイルの占めていた 領域は他で使う"
10470 "ことができるようになる。"
10471
10472 #. type: Plain text
10473 #: build/C/man3/remove.3:55
10474 msgid ""
10475 "If the name was the last link to a file, but any processes still have the "
10476 "file open, the file will remain in existence until the last file descriptor "
10477 "referring to it is closed."
10478 msgstr ""
10479 "名前がファイルへの最後のリンクであっても、どこかのプロセスが そのファイルを開"
10480 "いているなら、ファイルの最後のファイル記述子 (file descriptor) が閉じられるま"
10481 "でファイルは存在し続ける。"
10482
10483 #. type: Plain text
10484 #: build/C/man3/remove.3:57
10485 msgid "If the name referred to a symbolic link, the link is removed."
10486 msgstr "名前が指しているのがシンボリックリンクなら、そのリンクを削除する。"
10487
10488 #. type: Plain text
10489 #: build/C/man3/remove.3:60
10490 msgid ""
10491 "If the name referred to a socket, FIFO, or device, the name is removed, but "
10492 "processes which have the object open may continue to use it."
10493 msgstr ""
10494 "名前が指しているのがソケット、FIFO、デバイスの場合、名前は削除されるが、 その"
10495 "ソケットなどを開いているプロセスはそのまま使い続けることができる。"
10496
10497 #. type: Plain text
10498 #: build/C/man3/remove.3:70
10499 msgid "The errors that occur are those for B<unlink>(2)  and B<rmdir>(2)."
10500 msgstr "発生するエラーは B<unlink>(2)  および B<rmdir>(2)  と同じものである。"
10501
10502 #. type: Plain text
10503 #: build/C/man3/remove.3:72
10504 msgid "C89, C99, 4.3BSD, POSIX.1-2001."
10505 msgstr "C89, C99, 4.3BSD, POSIX.1-2001."
10506
10507 #. type: Plain text
10508 #: build/C/man3/remove.3:78
10509 msgid ""
10510 "Under libc4 and libc5, B<remove>()  was an alias for B<unlink>(2)  (and "
10511 "hence would not remove directories)."
10512 msgstr ""
10513 "libc4 と libc5 においては、 B<remove>()  は B<unlink>(2)  の別名であった "
10514 "(従ってディレクトリを削除できなかった)。"
10515
10516 #. type: Plain text
10517 #: build/C/man3/remove.3:81 build/C/man2/unlink.2:148
10518 msgid ""
10519 "Infelicities in the protocol underlying NFS can cause the unexpected "
10520 "disappearance of files which are still being used."
10521 msgstr ""
10522 "NFS プロトコルに内在する問題により、まだ使用中のファイルが想定外に消えてしま"
10523 "うことがありえる。"
10524
10525 #. type: Plain text
10526 #: build/C/man3/remove.3:92
10527 msgid ""
10528 "B<rm>(1), B<unlink>(1), B<link>(2), B<mknod>(2), B<open>(2), B<rename>(2), "
10529 "B<rmdir>(2), B<unlink>(2), B<mkfifo>(3), B<symlink>(7)"
10530 msgstr ""
10531 "B<rm>(1), B<unlink>(1), B<link>(2), B<mknod>(2), B<open>(2), B<rename>(2), "
10532 "B<rmdir>(2), B<unlink>(2), B<mkfifo>(3), B<symlink>(7)"
10533
10534 #. type: TH
10535 #: build/C/man2/rename.2:32
10536 #, no-wrap
10537 msgid "RENAME"
10538 msgstr "RENAME"
10539
10540 #. type: Plain text
10541 #: build/C/man2/rename.2:35
10542 msgid "rename - change the name or location of a file"
10543 msgstr "rename - ファイルの名前や位置を変更する"
10544
10545 #. type: Plain text
10546 #: build/C/man2/rename.2:39
10547 msgid "B<int rename(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
10548 msgstr "B<int rename(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
10549
10550 #. type: Plain text
10551 #: build/C/man2/rename.2:48
10552 msgid ""
10553 "B<rename>()  renames a file, moving it between directories if required.  Any "
10554 "other hard links to the file (as created using B<link>(2))  are unaffected.  "
10555 "Open file descriptors for I<oldpath> are also unaffected."
10556 msgstr ""
10557 "B<rename>()  はファイルの名前を変更し、必要ならばディレクトリ間の移動を行な"
10558 "う。 そのファイルに対する (B<link>(2)  を使用して作られた) 他のハードリンク "
10559 "(hard link) には影響はない。 オープン済の I<oldpath> に対するファイルディスク"
10560 "リプタにも影響はない。"
10561
10562 #. type: Plain text
10563 #: build/C/man2/rename.2:56
10564 msgid ""
10565 "If I<newpath> already exists it will be atomically replaced (subject to a "
10566 "few conditions; see ERRORS below), so that there is no point at which "
10567 "another process attempting to access I<newpath> will find it missing."
10568 msgstr ""
10569 "I<newpath> が既に存在する場合、それは不可分操作で (atomically) 置き換えられ"
10570 "る (ただし、いくつかの条件がある; 以下の「エラー」のセクションを参照)。 その"
10571 "ため、 I<newpath> にアクセスしようとしている他のプロセスがファイルを見失うこ"
10572 "とはない (訳註: 常にアクセス可能である)。"
10573
10574 #. type: Plain text
10575 #: build/C/man2/rename.2:64
10576 msgid ""
10577 "If I<oldpath> and I<newpath> are existing hard links referring to the same "
10578 "file, then B<rename>()  does nothing, and returns a success status."
10579 msgstr ""
10580 "I<oldpath> と I<newpath> がどちらも既存のハードリンクで、同じファイルを参照し"
10581 "ている場合、 B<rename>()  は何も行わず、ステータスとして成功を返す。"
10582
10583 #. type: Plain text
10584 #: build/C/man2/rename.2:72
10585 msgid ""
10586 "If I<newpath> exists but the operation fails for some reason B<rename>()  "
10587 "guarantees to leave an instance of I<newpath> in place."
10588 msgstr ""
10589 "I<newpath> が存在し、何らかの理由で操作が失敗した場合、 B<rename>()  は "
10590 "I<newpath> の実体を元のまま残すことを保証する。"
10591
10592 #. type: Plain text
10593 #: build/C/man2/rename.2:78
10594 msgid ""
10595 "I<oldpath> can specify a directory.  In this case, I<newpath> must either "
10596 "not exist, or it must specify an empty directory."
10597 msgstr ""
10598 "I<oldpath> にはディレクトリを指定することもできる。 この場合、 I<newpath> は"
10599 "存在しないか、空のディレクトリでなければならない。"
10600
10601 #. type: Plain text
10602 #: build/C/man2/rename.2:85
10603 msgid ""
10604 "However, when overwriting there will probably be a window in which both "
10605 "I<oldpath> and I<newpath> refer to the file being renamed."
10606 msgstr ""
10607 "一方で、上書きを行なう場合は、rename が行なわれるファイルを I<oldpath> と "
10608 "I<newpath> の両方で参照できる瞬間がおそらく存在する。"
10609
10610 #. type: Plain text
10611 #: build/C/man2/rename.2:91
10612 msgid ""
10613 "If I<oldpath> refers to a symbolic link the link is renamed; if I<newpath> "
10614 "refers to a symbolic link the link will be overwritten."
10615 msgstr ""
10616 "I<oldpath> がシンボリックリンク (symbolic link) を参照している場合は、 リンク"
10617 "の名前が変更される。 また、 I<newpath> がシンボリックリンクを参照している場合"
10618 "は、リンクが上書きされる。"
10619
10620 #. type: Plain text
10621 #: build/C/man2/rename.2:116
10622 msgid ""
10623 "Write permission is denied for the directory containing I<oldpath> or "
10624 "I<newpath>, or, search permission is denied for one of the directories in "
10625 "the path prefix of I<oldpath> or I<newpath>, or I<oldpath> is a directory "
10626 "and does not allow write permission (needed to update the I<..> entry).  "
10627 "(See also B<path_resolution>(7).)"
10628 msgstr ""
10629 "I<oldpath> または I<newpath> を含んでいるディレクトリの書き込み許可がない。 "
10630 "または、 I<oldpath> または I<newpath> のディレクトリ部分のどれかに検索許可が"
10631 "ない。 または、 I<oldpath> がディレクトリで (I<..> エントリを更新するのに必要"
10632 "な) 書き込み許可がない (B<path_resolution>(7)  も参照)。"
10633
10634 #. type: TP
10635 #: build/C/man2/rename.2:116 build/C/man2/rmdir.2:55 build/C/man2/unlink.2:71
10636 #, no-wrap
10637 msgid "B<EBUSY>"
10638 msgstr "B<EBUSY>"
10639
10640 #. type: Plain text
10641 #: build/C/man2/rename.2:133
10642 msgid ""
10643 "The rename fails because I<oldpath> or I<newpath> is a directory that is in "
10644 "use by some process (perhaps as current working directory, or as root "
10645 "directory, or because it was open for reading) or is in use by the system "
10646 "(for example as mount point), while the system considers this an error.  "
10647 "(Note that there is no requirement to return B<EBUSY> in such cases"
10648 "\\(emthere is nothing wrong with doing the rename anyway\\(embut it is "
10649 "allowed to return B<EBUSY> if the system cannot otherwise handle such "
10650 "situations.)"
10651 msgstr ""
10652 "I<oldpath> または I<newpath> がディレクトリで、何らかのプロセスが使用中 (多"
10653 "分、カレントワーキングディレクトリか、ルートディレクトリか、 読み込みのために"
10654 "オープンされているかでろう)  もしくは、システムが使用中 (例えばマウントポイン"
10655 "トである)  であり、システムがこれをエラーであると判断したために rename が失敗"
10656 "した。 (このような場合に B<EBUSY> を返すことは規格では要求されていない点に注"
10657 "意すること。 このような場合に、rename をとにかく実行してみるのは何の問題もな"
10658 "い。 ただし、そのような状況で、システムが他に返すエラーがない場合には "
10659 "B<EBUSY> を返すことが許されている。)"
10660
10661 #. type: Plain text
10662 #: build/C/man2/rename.2:143
10663 msgid ""
10664 "The new pathname contained a path prefix of the old, or, more generally, an "
10665 "attempt was made to make a directory a subdirectory of itself."
10666 msgstr ""
10667 "I<newpath> が I<oldpath> のパス部分を含んでいる。ディレクトリを自分自身のサブ"
10668 "ディレクトリに 変更しようとした場合がほとんどである。"
10669
10670 #. type: Plain text
10671 #: build/C/man2/rename.2:149
10672 msgid "I<newpath> is an existing directory, but I<oldpath> is not a directory."
10673 msgstr ""
10674 "I<newpath> は存在しているディレクトリであるが、 I<oldpath> はディレクトリでな"
10675 "い。"
10676
10677 #. type: Plain text
10678 #: build/C/man2/rename.2:160
10679 msgid ""
10680 "I<oldpath> already has the maximum number of links to it, or it was a "
10681 "directory and the directory containing I<newpath> has the maximum number of "
10682 "links."
10683 msgstr ""
10684 "I<oldpath> は既に最大数までのリンクを持っているか、それがディレクトリで "
10685 "I<newpath> を含んでいるディレクトリが最大数までのリンクを持っている。"
10686
10687 #. type: Plain text
10688 #: build/C/man2/rename.2:176
10689 msgid ""
10690 "The link named by I<oldpath> does not exist; or, a directory component in "
10691 "I<newpath> does not exist; or, I<oldpath> or I<newpath> is an empty string."
10692 msgstr ""
10693 "I<oldpath> という名前のリンクが存在しない。 または、 I<newpath> というディレ"
10694 "クトリが存在しない。 または、 I<oldpath> か I<newpath> が空の文字列である。"
10695
10696 #. type: Plain text
10697 #: build/C/man2/rename.2:193
10698 msgid ""
10699 "A component used as a directory in I<oldpath> or I<newpath> is not, in fact, "
10700 "a directory.  Or, I<oldpath> is a directory, and I<newpath> exists but is "
10701 "not a directory."
10702 msgstr ""
10703 "I<oldpath> か I<newpath> に含まれているディレクトリ部分が 実際にはディレクト"
10704 "リでない。 または I<oldpath> がディレクトリで、 I<newpath> が存在してディレク"
10705 "トリでない。"
10706
10707 #. type: TP
10708 #: build/C/man2/rename.2:193
10709 #, no-wrap
10710 msgid "B<ENOTEMPTY> or B<EEXIST>"
10711 msgstr "B<ENOTEMPTY  または  EEXIST>"
10712
10713 #. type: Plain text
10714 #: build/C/man2/rename.2:197
10715 msgid ""
10716 "I<newpath> is a nonempty directory, that is, contains entries other than \"."
10717 "\" and \"..\"."
10718 msgstr ""
10719 "I<newpath> が空でないディレクトリである。すなわち \".\" と \"..\" 以外を含ん"
10720 "でいる。"
10721
10722 #. type: TP
10723 #: build/C/man2/rename.2:197 build/C/man2/unlink.2:126
10724 #, no-wrap
10725 msgid "B<EPERM> or B<EACCES>"
10726 msgstr "B<EPERM> または B<EACCES>"
10727
10728 #. type: Plain text
10729 #: build/C/man2/rename.2:221
10730 msgid ""
10731 "The directory containing I<oldpath> has the sticky bit (B<S_ISVTX>)  set and "
10732 "the process's effective user ID is neither the user ID of the file to be "
10733 "deleted nor that of the directory containing it, and the process is not "
10734 "privileged (Linux: does not have the B<CAP_FOWNER> capability); or "
10735 "I<newpath> is an existing file and the directory containing it has the "
10736 "sticky bit set and the process's effective user ID is neither the user ID of "
10737 "the file to be replaced nor that of the directory containing it, and the "
10738 "process is not privileged (Linux: does not have the B<CAP_FOWNER> "
10739 "capability); or the file system containing I<pathname> does not support "
10740 "renaming of the type requested."
10741 msgstr ""
10742 "I<oldpath> のあるディレクトリにスティッキービット (sticky bit)  "
10743 "(B<S_ISVTX>)  が設定されており、 プロセスの実効ユーザー ID が 削除しようとす"
10744 "るファイルのユーザー ID と そのファイルを含むディレクトリのユーザー ID のいず"
10745 "れとも一致せず、かつ プロセスに特権がない (Linux では B<CAP_FOWNER> ケーパビ"
10746 "リティ (capability) がない)。 または、 I<newpath> がすでに存在するファイル"
10747 "で、親ディレクトリにスティッキービットが設定されており、 プロセスの実効ユー"
10748 "ザー ID が 置き換えようとするファイルのユーザー ID と そのファイルを含むディ"
10749 "レクトリのユーザー ID のいずれとも一致せず、かつ プロセスに特権がない (Linux "
10750 "では B<CAP_FOWNER> ケーパビリティがない)。 または I<oldpath> と I<newpath> が"
10751 "存在するファイルシステムが、要求された種類の名前の変更を サポートしていない。"
10752
10753 #. type: Plain text
10754 #: build/C/man2/rename.2:232
10755 msgid ""
10756 "I<oldpath> and I<newpath> are not on the same mounted file system.  (Linux "
10757 "permits a file system to be mounted at multiple points, but B<rename>()  "
10758 "does not work across different mount points, even if the same file system is "
10759 "mounted on both.)"
10760 msgstr ""
10761 "I<oldpath> と I<newpath> が同じマウントされたファイルシステムに存在しない。 "
10762 "(Linux は 1 つのファイルシステムを複数のマウント位置に マウントすることを許可"
10763 "している。 しかし B<rename>()  は、たとえ同じファイルシステムであっても、 "
10764 "別々のマウント位置を跨いでは動作しない。)"
10765
10766 #. type: Plain text
10767 #: build/C/man2/rename.2:234
10768 msgid "4.3BSD, C89, C99, POSIX.1-2001."
10769 msgstr "4.3BSD, C89, C99, POSIX.1-2001."
10770
10771 #. type: Plain text
10772 #: build/C/man2/rename.2:245
10773 msgid ""
10774 "On NFS file systems, you can not assume that if the operation failed the "
10775 "file was not renamed.  If the server does the rename operation and then "
10776 "crashes, the retransmitted RPC which will be processed when the server is up "
10777 "again causes a failure.  The application is expected to deal with this.  See "
10778 "B<link>(2)  for a similar problem."
10779 msgstr ""
10780 "NFS ファイルシステムでは、操作が失敗したからといって、 ファイルの名前が変更で"
10781 "きなかったと決めてかかることはできない。 サーバが rename 操作を終えてからク"
10782 "ラッシュした場合、 サーバが再び立ち上がったときに、 再送信された RPC が処理さ"
10783 "れるが、これは失敗となる。 アプリケーションはこの問題を正しく取り扱うことが期"
10784 "待されている。 同様の問題について B<link>(2)  にも書かれている。"
10785
10786 #. type: Plain text
10787 #: build/C/man2/rename.2:254
10788 msgid ""
10789 "B<mv>(1), B<chmod>(2), B<link>(2), B<renameat>(2), B<symlink>(2), B<unlink>"
10790 "(2), B<path_resolution>(7), B<symlink>(7)"
10791 msgstr ""
10792 "B<mv>(1), B<chmod>(2), B<link>(2), B<renameat>(2), B<symlink>(2), B<unlink>"
10793 "(2), B<path_resolution>(7), B<symlink>(7)"
10794
10795 #. type: TH
10796 #: build/C/man2/rmdir.2:30
10797 #, no-wrap
10798 msgid "RMDIR"
10799 msgstr "RMDIR"
10800
10801 #. type: TH
10802 #: build/C/man2/rmdir.2:30
10803 #, no-wrap
10804 msgid "2008-05-08"
10805 msgstr "2008-05-08"
10806
10807 #. type: Plain text
10808 #: build/C/man2/rmdir.2:33
10809 msgid "rmdir - delete a directory"
10810 msgstr "rmdir - ディレクトリを削除する"
10811
10812 #. type: Plain text
10813 #: build/C/man2/rmdir.2:37
10814 msgid "B<int rmdir(const char *>I<pathname>B<);>"
10815 msgstr "B<int rmdir(const char *>I<pathname>B<);>"
10816
10817 #. type: Plain text
10818 #: build/C/man2/rmdir.2:40
10819 msgid "B<rmdir>()  deletes a directory, which must be empty."
10820 msgstr ""
10821 "B<rmdir>()  はディレクトリを削除する。削除するディレクトリは空でなければなら"
10822 "ない。"
10823
10824 #. type: Plain text
10825 #: build/C/man2/rmdir.2:55
10826 msgid ""
10827 "Write access to the directory containing I<pathname> was not allowed, or one "
10828 "of the directories in the path prefix of I<pathname> did not allow search "
10829 "permission.  (See also B<path_resolution>(7)."
10830 msgstr ""
10831 "I<pathname> を含んでいるディレクトリへの書き込みアクセスが プロセスの実効 "
10832 "(effective) UID に対して許可されていないか、 I<pathname> に含まれているディレ"
10833 "クトリのどれかに検索 (実行) 許可がないか、 I<pathname> に至るまでのディレクト"
10834 "リのいずれかに対する検索許可がなかった。 (B<path_resolution>(7)  も参照のこ"
10835 "と)"
10836
10837 #. type: Plain text
10838 #: build/C/man2/rmdir.2:64
10839 msgid ""
10840 "I<pathname> is currently in use by the system or some process that prevents "
10841 "its removal.  On Linux this means I<pathname> is currently used as a mount "
10842 "point or is the root directory of the calling process."
10843 msgstr ""
10844 "I<pathname> がシステムや別のプロセスにより使用中で削除することができない。 "
10845 "Linux では、 I<pathname> がマウントポイントとして使用されているか、 呼び出し"
10846 "たプロセスのルートディレクトリであることを意味する。"
10847
10848 #. type: Plain text
10849 #: build/C/man2/rmdir.2:73
10850 msgid "I<pathname> has I<.> as last component."
10851 msgstr "I<pathname> の最後のディレクトリ部分が I<.> である。"
10852
10853 #. type: Plain text
10854 #: build/C/man2/rmdir.2:77
10855 msgid "Too many symbolic links were encountered in resolving I<pathname>."
10856 msgstr "I<pathname> を解決する際に遭遇したシンボリックリンクが多過ぎる。"
10857
10858 #. type: Plain text
10859 #: build/C/man2/rmdir.2:85
10860 msgid ""
10861 "A directory component in I<pathname> does not exist or is a dangling "
10862 "symbolic link."
10863 msgstr ""
10864 "I<pathname> の中のディレクトリ部分が存在しないか、壊れた (dangling)  シンボ"
10865 "リックリンク (symbolic link) である。"
10866
10867 #. type: Plain text
10868 #: build/C/man2/rmdir.2:94
10869 msgid ""
10870 "I<pathname>, or a component used as a directory in I<pathname>, is not, in "
10871 "fact, a directory."
10872 msgstr ""
10873 "I<pathname> か I<pathname> に含まれているディレクトリ部分が、実際には、ディレ"
10874 "クトリでない。"
10875
10876 #. type: TP
10877 #: build/C/man2/rmdir.2:94
10878 #, no-wrap
10879 msgid "B<ENOTEMPTY>"
10880 msgstr "B<ENOTEMPTY>"
10881
10882 #. type: Plain text
10883 #: build/C/man2/rmdir.2:107
10884 msgid ""
10885 "I<pathname> contains entries other than I<.> and I<..> ; or, I<pathname> has "
10886 "I<..> as its final component.  POSIX.1-2001 also allows B<EEXIST> for this "
10887 "condition."
10888 msgstr ""
10889 "ディレクトリ I<pathname> に I<.> と I<..> 以外のエントリがある。または、 "
10890 "I<pathname> を構成する最後の要素が I<..> である。 POSIX.1-2001 は、この状況"
10891 "で B<EEXIST> を返すことを認めている。"
10892
10893 #. type: Plain text
10894 #: build/C/man2/rmdir.2:118
10895 msgid ""
10896 "The directory containing I<pathname> has the sticky bit (B<S_ISVTX>)  set "
10897 "and the process's effective user ID is neither the user ID of the file to be "
10898 "deleted nor that of the directory containing it, and the process is not "
10899 "privileged (Linux: does not have the B<CAP_FOWNER> capability)."
10900 msgstr ""
10901 "I<pathname> を含んでいるディレクトリにスティッキービット(sticky-bit)  "
10902 "(B<S_ISVTX>)  が設定されていて、プロセスの実効ユーザーID が削除しようとする"
10903 "ファイルの ユーザID とそのファイルを含むディレクトリのユーザーID のどちらとも"
10904 "異なり、 プロセスも権限 (Linux では B<CAP_FOWNER> ケーパビリティ) がない。"
10905
10906 #. type: Plain text
10907 #: build/C/man2/rmdir.2:123
10908 msgid ""
10909 "The file system containing I<pathname> does not support the removal of "
10910 "directories."
10911 msgstr ""
10912 "I<pathname> を含んでいるファイルシステムがディレクトリの 削除をサポートしてい"
10913 "ない。"
10914
10915 #. type: Plain text
10916 #: build/C/man2/rmdir.2:127
10917 msgid "I<pathname> refers to a directory on a read-only file system."
10918 msgstr ""
10919 "I<pathname> が読み込み専用のファイルシステム上のディレクトリを参照している。"
10920
10921 #. type: Plain text
10922 #: build/C/man2/rmdir.2:132
10923 msgid ""
10924 "Infelicities in the protocol underlying NFS can cause the unexpected "
10925 "disappearance of directories which are still being used."
10926 msgstr ""
10927 "NFS プロトコルに潜在している欠陥によって、まだ使用中のディレクトリが 突然消滅"
10928 "する現象が引き起こされることがある。"
10929
10930 #. type: Plain text
10931 #: build/C/man2/rmdir.2:141
10932 msgid ""
10933 "B<rm>(1), B<rmdir>(1), B<chdir>(2), B<chmod>(2), B<mkdir>(2), B<rename>(2), "
10934 "B<unlink>(2), B<unlinkat>(2)"
10935 msgstr ""
10936 "B<rm>(1), B<rmdir>(1), B<chdir>(2), B<chmod>(2), B<mkdir>(2), B<rename>(2), "
10937 "B<unlink>(2), B<unlinkat>(2)"
10938
10939 #. type: TH
10940 #: build/C/man3/scanf.3:52
10941 #, no-wrap
10942 msgid "SCANF"
10943 msgstr "SCANF"
10944
10945 #. type: TH
10946 #: build/C/man3/scanf.3:52
10947 #, no-wrap
10948 msgid "2013-01-30"
10949 msgstr "2013-01-30"
10950
10951 #. type: Plain text
10952 #: build/C/man3/scanf.3:55
10953 msgid ""
10954 "scanf, fscanf, sscanf, vscanf, vsscanf, vfscanf - input format conversion"
10955 msgstr "scanf, fscanf, sscanf, vscanf, vsscanf, vfscanf - 書式付き入力変換"
10956
10957 #. type: Plain text
10958 #: build/C/man3/scanf.3:62
10959 #, no-wrap
10960 msgid ""
10961 "B<int scanf(const char *>I<format>B<, ...);>\n"
10962 "B<int fscanf(FILE *>I<stream>B<, const char *>I<format>B<, ...);>\n"
10963 "B<int sscanf(const char *>I<str>B<, const char *>I<format>B<, ...);>\n"
10964 msgstr ""
10965 "B<int scanf(const char *>I<format>B<, ...);>\n"
10966 "B<int fscanf(FILE *>I<stream>B<, const char *>I<format>B<, ...);>\n"
10967 "B<int sscanf(const char *>I<str>B<, const char *>I<format>B<, ...);>\n"
10968
10969 #. type: Plain text
10970 #: build/C/man3/scanf.3:64
10971 #, no-wrap
10972 msgid "B<#include E<lt>stdarg.hE<gt>>\n"
10973 msgstr "B<#include E<lt>stdarg.hE<gt>>\n"
10974
10975 #. type: Plain text
10976 #: build/C/man3/scanf.3:68
10977 #, no-wrap
10978 msgid ""
10979 "B<int vscanf(const char *>I<format>B<, va_list >I<ap>B<);>\n"
10980 "B<int vsscanf(const char *>I<str>B<, const char *>I<format>B<, va_list >I<ap>B<);>\n"
10981 "B<int vfscanf(FILE *>I<stream>B<, const char *>I<format>B<, va_list >I<ap>B<);>\n"
10982 msgstr ""
10983 "B<int vscanf(const char *>I<format>B<, va_list >I<ap>B<);>\n"
10984 "B<int vsscanf(const char *>I<str>B<, const char *>I<format>B<, va_list >I<ap>B<);>\n"
10985 "B<int vfscanf(FILE *>I<stream>B<, const char *>I<format>B<, va_list >I<ap>B<);>\n"
10986
10987 #. type: Plain text
10988 #: build/C/man3/scanf.3:79
10989 msgid "B<vscanf>(), B<vsscanf>(), B<vfscanf>():"
10990 msgstr "B<vscanf>(), B<vsscanf>(), B<vfscanf>():"
10991
10992 #. type: Plain text
10993 #: build/C/man3/scanf.3:82
10994 msgid ""
10995 "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _ISOC99_SOURCE || _POSIX_C_SOURCE\\ E<gt>=\\ "
10996 "200112L;"
10997 msgstr ""
10998 "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _ISOC99_SOURCE || _POSIX_C_SOURCE\\ E<gt>=\\ "
10999 "200112L;"
11000
11001 #. type: Plain text
11002 #: build/C/man3/scanf.3:104
11003 msgid ""
11004 "The B<scanf>()  family of functions scans input according to I<format> as "
11005 "described below.  This format may contain I<conversion specifications>; the "
11006 "results from such conversions, if any, are stored in the locations pointed "
11007 "to by the I<pointer> arguments that follow I<format>.  Each I<pointer> "
11008 "argument must be of a type that is appropriate for the value returned by the "
11009 "corresponding conversion specification."
11010 msgstr ""
11011 "B<scanf>()  関数グループは、以下に述べるように、 I<format> に従って入力を読み"
11012 "込むものである。 この書式には I<「変換指定」 (conversion specifications)> を"
11013 "含めることができ、変換指定があれば、その変換の結果は I<format> に続く "
11014 "I<pointer> 引き数が指す場所に格納される。 それぞれの I<pointer> 引き数の型"
11015 "は、対応する変換指定が返す値に 適合していなければならない。"
11016
11017 #. type: Plain text
11018 #: build/C/man3/scanf.3:115
11019 msgid ""
11020 "If the number of conversion specifications in I<format> exceeds the number "
11021 "of I<pointer> arguments, the results are undefined.  If the number of "
11022 "I<pointer> arguments exceeds the number of conversion specifications, then "
11023 "the excess I<pointer> arguments are evaluated, but are otherwise ignored."
11024 msgstr ""
11025 "I<format> 中の変換指定の個数が I<pointer> 引き数の数より多かった場合の結果は"
11026 "未定義である。 I<pointer> 引き数の数が変換指定の個数よりも多かった場合、 余分"
11027 "な I<pointer> 引き数の評価は行われるが、それ以外は行われず無視される。"
11028
11029 #. type: Plain text
11030 #: build/C/man3/scanf.3:127
11031 msgid ""
11032 "The B<scanf>()  function reads input from the standard input stream "
11033 "I<stdin>, B<fscanf>()  reads input from the stream pointer I<stream>, and "
11034 "B<sscanf>()  reads its input from the character string pointed to by I<str>."
11035 msgstr ""
11036 "B<scanf>()  関数は標準入力ストリーム I<stdin> からの入力を読み込む。 "
11037 "B<fscanf>()  はストリームポインタ I<stream> からの入力を読み込む。 B<sscanf>"
11038 "()  は文字列ポインタ I<str> で示された文字列からの入力を読み込む。"
11039
11040 #. type: Plain text
11041 #: build/C/man3/scanf.3:145
11042 msgid ""
11043 "The B<vfscanf>()  function is analogous to B<vfprintf>(3)  and reads input "
11044 "from the stream pointer I<stream> using a variable argument list of pointers "
11045 "(see B<stdarg>(3).  The B<vscanf>()  function scans a variable argument list "
11046 "from the standard input and the B<vsscanf>()  function scans it from a "
11047 "string; these are analogous to the B<vprintf>(3)  and B<vsprintf>(3)  "
11048 "functions respectively."
11049 msgstr ""
11050 "B<vfscanf>()  関数は B<vfprintf>(3)  と同様に、ストリームポインタ I<stream> "
11051 "からの入力をポインタの可変長引き数リストを用いて読み込む (B<stdarg>(3)  を参"
11052 "照)。 B<vscanf>()  関数は、可変長引き数のリストに基づき標準入力からの読み取り"
11053 "を行う。 B<vsscanf>()  関数はそのリストに基づき文字列から読み取る。 これらの"
11054 "関係は B<vprintf>(3)  と B<vsprintf>(3)  関数の関係と同様である。"
11055
11056 #. type: Plain text
11057 #: build/C/man3/scanf.3:159
11058 msgid ""
11059 "The I<format> string consists of a sequence of I<directives> which describe "
11060 "how to process the sequence of input characters.  If processing of a "
11061 "directive fails, no further input is read, and B<scanf>()  returns.  A "
11062 "\"failure\" can be either of the following: I<input failure>, meaning that "
11063 "input characters were unavailable, or I<matching failure>, meaning that the "
11064 "input was inappropriate (see below)."
11065 msgstr ""
11066 "I<format> 文字列は I<「命令」 (directive)> の列で構成される。命令は入力文字の"
11067 "系列をどのように処理するかを指示する ものである。ある命令の処理が失敗すると、"
11068 "入力はそれ以上読み込まれず、 B<scanf>()  は返る。「失敗」は I<「入力の失敗」 "
11069 "(input failure)> と I<「一致の失敗」 (matching failure)> のいずれかである。 "
11070 "入力の失敗は入力文字が使用できなかったことを意味し、 一致の失敗は入力が不適切"
11071 "であったこと (下記参照) を意味する。"
11072
11073 #. type: Plain text
11074 #: build/C/man3/scanf.3:161
11075 msgid "A directive is one of the following:"
11076 msgstr "命令は以下のいずれかである:"
11077
11078 #. type: TP
11079 #: build/C/man3/scanf.3:161 build/C/man3/scanf.3:167 build/C/man3/scanf.3:171
11080 #: build/C/man3/scanf.3:190 build/C/man3/scanf.3:201 build/C/man3/scanf.3:220
11081 #: build/C/man3/scanf.3:232 build/C/man3/scanf.3:246
11082 #, no-wrap
11083 msgid "\\(bu"
11084 msgstr "\\(bu"
11085
11086 #. type: Plain text
11087 #: build/C/man3/scanf.3:167
11088 msgid ""
11089 "A sequence of white-space characters (space, tab, newline, etc.; see "
11090 "B<isspace>(3)).  This directive matches any amount of white space, including "
11091 "none, in the input."
11092 msgstr ""
11093 "ホワイトスペース (スペース、タブ、改行など; B<isspace>(3)  参照) の列。 この"
11094 "命令は、入力中の任意の個数のホワイトスペースに一致する。 (「何もなし」にも一"
11095 "致する)。"
11096
11097 #. type: Plain text
11098 #: build/C/man3/scanf.3:171
11099 msgid ""
11100 "An ordinary character (i.e., one other than white space or \\(aq%\\(aq).  "
11101 "This character must exactly match the next character of input."
11102 msgstr ""
11103 "通常文字 (つまり、ホワイトスペースと \\(aq%\\(aq 以外の文字)。 この文字は入力"
11104 "の次の文字に正確に一致しなければならない。"
11105
11106 #. type: Plain text
11107 #: build/C/man3/scanf.3:182
11108 msgid ""
11109 "A conversion specification, which commences with a \\(aq%\\(aq (percent) "
11110 "character.  A sequence of characters from the input is converted according "
11111 "to this specification, and the result is placed in the corresponding "
11112 "I<pointer> argument.  If the next item of input does not match the "
11113 "conversion specification, the conversion fails\\(emthis is a I<matching "
11114 "failure>."
11115 msgstr ""
11116 "変換指定。変換指定は \\(aq%\\(aq (パーセント) 文字で始まる。 入力された文字の"
11117 "系列はこの指定にもとづいて変換され、 変換結果は対応する I<pointer> 引き数が指"
11118 "す場所に格納される。 入力の次の文字が変換指定と一致しない場合は、変換は失敗す"
11119 "る \\(emこれが I<「一致の失敗」 (matching failure)> である。"
11120
11121 #. type: Plain text
11122 #: build/C/man3/scanf.3:190
11123 msgid ""
11124 "Each I<conversion specification> in I<format> begins with either the "
11125 "character \\(aq%\\(aq or the character sequence \"B<%>I<n>B<$>\" (see below "
11126 "for the distinction) followed by:"
11127 msgstr ""
11128 "I<format> 中の各々の I<「変換指定」> は文字 \\(aq%\\(aq か文字系列 \"B<"
11129 "%>I<n>B<$>\" (違いについては後述) で始まり、以下の要素が続く。"
11130
11131 #. type: Plain text
11132 #: build/C/man3/scanf.3:201
11133 msgid ""
11134 "An optional \\(aq*\\(aq assignment-suppression character: B<scanf>()  reads "
11135 "input as directed by the conversion specification, but discards the input.  "
11136 "No corresponding I<pointer> argument is required, and this specification is "
11137 "not included in the count of successful assignments returned by B<scanf>()."
11138 msgstr ""
11139 "代入抑制文字 \\(aq*\\(aq (省略可能)。 B<scanf>()  は変換指定に指示された通り"
11140 "入力を読み込むが、その入力は捨てられる。 対応する I<pointer> 引き数は必要な"
11141 "く、 B<scanf>()  が返す代入が成功した数にこの指定は含まれない。"
11142
11143 #. type: Plain text
11144 #: build/C/man3/scanf.3:220
11145 #, fuzzy
11146 #| msgid ""
11147 #| "An optional \\(aqa\\(aq character.  This is used with string conversions, "
11148 #| "and relieves the caller of the need to allocate a corresponding buffer to "
11149 #| "hold the input: instead, B<scanf>()  allocates a buffer of sufficient "
11150 #| "size, and assigns the address of this buffer to the corresponding "
11151 #| "I<pointer> argument, which should be a pointer to a I<char *> variable "
11152 #| "(this variable does not need to be initialized before the call).  The "
11153 #| "caller should subsequently B<free>(3)  this buffer when it is no longer "
11154 #| "required.  This is a GNU extension; C99 employs the \\(aqa\\(aq character "
11155 #| "as a conversion specifier (and it can also be used as such in the GNU "
11156 #| "implementation)."
11157 msgid ""
11158 "An optional \\(aqm\\(aq character.  This is used with string conversions (I<"
11159 "%s>, I<%c>, I<%[>), and relieves the caller of the need to allocate a "
11160 "corresponding buffer to hold the input: instead, B<scanf>()  allocates a "
11161 "buffer of sufficient size, and assigns the address of this buffer to the "
11162 "corresponding I<pointer> argument, which should be a pointer to a I<char *> "
11163 "variable (this variable does not need to be initialized before the call).  "
11164 "The caller should subsequently B<free>(3)  this buffer when it is no longer "
11165 "required."
11166 msgstr ""
11167 "文字 \\(aqa\\(aq (省略可能)。これは文字列変換とともに使用され、これを使うと "
11168 "呼び出し元が入力を保持する対応するバッファを確保する必要がなくなる。 代わり"
11169 "に B<scanf>()  が必要な大きさのバッファを確保し、このバッファのアドレスを 対"
11170 "応する I<pointer> 引き数に代入する。 I<pointer> 引き数は I<char *> 型の変数へ"
11171 "のポインタでなければならない (変数自体は呼び出し前に初期化されている必要はな"
11172 "い)。 呼び出し元は、不要になった時点で、このバッファを B<free>(3)  すべきであ"
11173 "る。この機能は GNU による拡張である。 C99 は \\(aqa\\(aq 文字を変換指定として"
11174 "使用している (こちらも GNU の実装と同じように使用することができる)。"
11175
11176 #. type: Plain text
11177 #: build/C/man3/scanf.3:232
11178 msgid ""
11179 "An optional decimal integer which specifies the I<maximum field width>.  "
11180 "Reading of characters stops either when this maximum is reached or when a "
11181 "nonmatching character is found, whichever happens first.  Most conversions "
11182 "discard initial white space characters (the exceptions are noted below), and "
11183 "these discarded characters don't count toward the maximum field width.  "
11184 "String input conversions store a terminating null byte (\\(aq\\e0\\(aq)  to "
11185 "mark the end of the input; the maximum field width does not include this "
11186 "terminator."
11187 msgstr ""
11188 "I<「最大フィールド幅」> を指定する 10進数 (省略可能)。 この最大値に達するか、"
11189 "一致しない文字が見つかるか、のどちらかに なると、文字の読み込みを停止する。 "
11190 "ほとんどの変換では、先頭のホワイトスペース文字は捨てられ (例外については後述"
11191 "する)、 捨てられたこれらの文字は最大フィールド幅の計算には含まれない。 文字列"
11192 "の入力変換では、入力の末尾を示す終端の NULL バイト (\\(aq\\e0\\(aq)  も格納さ"
11193 "れるが、最大フィールド幅にはこの終端バイトは含まれない。"
11194
11195 #. type: Plain text
11196 #: build/C/man3/scanf.3:246
11197 msgid ""
11198 "An optional I<type modifier character>.  For example, the B<l> type modifier "
11199 "is used with integer conversions such as B<%d> to specify that the "
11200 "corresponding I<pointer> argument refers to a I<long int> rather than a "
11201 "pointer to an I<int>."
11202 msgstr ""
11203 "I<「型修飾子」 (type modifier characters)> (省略可能)。 例えば、型修飾子 "
11204 "B<l> を B<%d> などの整数変換と一緒に使うと、対応する I<pointer> 引き数が "
11205 "I<int> ではなく I<long int> を参照していることを指定できる。"
11206
11207 #. type: Plain text
11208 #: build/C/man3/scanf.3:251
11209 msgid ""
11210 "A I<conversion specifier> that specifies the type of input conversion to be "
11211 "performed."
11212 msgstr "I<「変換指定」> : 実行すべき入力変換の種類を指定する。"
11213
11214 #. type: Plain text
11215 #: build/C/man3/scanf.3:280
11216 msgid ""
11217 "The conversion specifications in I<format> are of two forms, either "
11218 "beginning with \\(aq%\\(aq or beginning with \"B<%>I<n>B<$>\".  The two "
11219 "forms should not be mixed in the same I<format> string, except that a string "
11220 "containing \"B<%>I<n>B<$>\" specifications can include B<%%> and B<%*>.  If "
11221 "I<format> contains \\(aq%\\(aq specifications then these correspond in order "
11222 "with successive I<pointer> arguments.  In the \"B<%>I<n>B<$>\" form (which "
11223 "is specified in POSIX.1-2001, but not C99), I<n> is a decimal integer that "
11224 "specifies that the converted input should be placed in the location referred "
11225 "to by the I<n>-th I<pointer> argument following I<format>."
11226 msgstr ""
11227 "I<format> 中の変換指定は、\\(aq%\\(aq で始まるか、 \"B<%>I<n>B<$>\" で始まる"
11228 "かの、いずれかの形式である。 これら 2つの形式を同じ I<format> 文字列に混ぜる"
11229 "ことはできない。但し、\"B<%>I<n>B<$>\" を 含む文字列に B<%%> と B<%*> を含め"
11230 "ることはできる。 I<format> に \\(aq%\\(aq 指定が含まれている場合、各々の "
11231 "\\(aq%\\(aq 指定と 後続の I<pointer> 引き数はその順番通りに対応する。 \"B<"
11232 "%>I<n>B<$>\" 形式 (POSIX.1-2001 では規定されているが、C99 にはない)  では、 "
11233 "I<n> は 10進数であり、変換後の入力を I<format> の後ろの I<n> 番目の "
11234 "I<pointer> 引き数が参照する場所に格納することを指定する。"
11235
11236 #. type: SS
11237 #: build/C/man3/scanf.3:280
11238 #, no-wrap
11239 msgid "Conversions"
11240 msgstr "変換"
11241
11242 #. type: Plain text
11243 #: build/C/man3/scanf.3:284
11244 msgid ""
11245 "The following I<type modifier characters> can appear in a conversion "
11246 "specification:"
11247 msgstr "変換指定には、以下の I<「型修飾子」> を入れることができる。"
11248
11249 #. type: Plain text
11250 #: build/C/man3/scanf.3:294
11251 msgid ""
11252 "Indicates that the conversion will be one of B<d>, B<i>, B<o>, B<u>, B<x>, "
11253 "B<X>, or B<n> and the next pointer is a pointer to a I<short int> or "
11254 "I<unsigned short int> (rather than I<int>)."
11255 msgstr ""
11256 "変換が B<d>, B<i>, B<o>, B<u>, B<x>, B<X>, B<n> のいずれかであり、次のポイン"
11257 "タが (I<int> ではなく)  I<short int> か I<unsigned short int> へのポインタで"
11258 "あることを示す。"
11259
11260 #. type: Plain text
11261 #: build/C/man3/scanf.3:302
11262 msgid ""
11263 "As for B<h>, but the next pointer is a pointer to a I<signed char> or "
11264 "I<unsigned char>."
11265 msgstr ""
11266 "B<h> と同じだが、次のポインタが I<signed char> か I<unsigned char> へのポイン"
11267 "タであることを示す。"
11268
11269 #. type: Plain text
11270 #: build/C/man3/scanf.3:311
11271 msgid ""
11272 "As for B<h>, but the next pointer is a pointer to an I<intmax_t> or a "
11273 "I<uintmax_t>.  This modifier was introduced in C99."
11274 msgstr ""
11275 "B<h> と同じだが、次のポインタが I<intmax_t> か I<uintmax_t> へのポインタであ"
11276 "ることを示す。 この修飾子は C99 で導入された。"
11277
11278 #.  This use of l was introduced in Amendment 1 to ISO C90.
11279 #. type: Plain text
11280 #: build/C/man3/scanf.3:338
11281 msgid ""
11282 "Indicates either that the conversion will be one of B<d>, B<i>, B<o>, B<u>, "
11283 "B<x>, B<X>, or B<n> and the next pointer is a pointer to a I<long int> or "
11284 "I<unsigned long int> (rather than I<int>), or that the conversion will be "
11285 "one of B<e>, B<f>, or B<g> and the next pointer is a pointer to I<double> "
11286 "(rather than I<float>).  Specifying two B<l> characters is equivalent to "
11287 "B<L>.  If used with B<%c> or B<%s> the corresponding parameter is considered "
11288 "as a pointer to a wide character or wide-character string respectively."
11289 msgstr ""
11290 "変換が B<d>, B<i>, B<o>, B<u>, B<x>, B<X>, B<n> か B<n> のいずれかであり次の"
11291 "ポインタが (I<int> ではなく)  I<long int> か I<unsigned long int> へのポイン"
11292 "タであること、または、変換が B<e>, B<f>, B<g> のうちのひとつであり次のポイン"
11293 "タが (I<float> ではなく)  I<double> へのポインタであることのいずれかであるこ"
11294 "とを示す。 B<l> 文字を二つ指定すると、 B<L> と同じ意味となる。 B<%c> や B<"
11295 "%s> とともに使用すると、 パラメータはそれぞれワイド文字やワイド文字列へのポイ"
11296 "ンタであると みなされる。"
11297
11298 #.  MTK, Jul 05: The following is no longer true for modern
11299 #.  ANSI C (i.e., C99):
11300 #.  (Note that long long is not an
11301 #.  ANSI C
11302 #.  type. Any program using this will not be portable to all
11303 #.  architectures).
11304 #. type: Plain text
11305 #: build/C/man3/scanf.3:354
11306 msgid ""
11307 "Indicates that the conversion will be either B<e>, B<f>, or B<g> and the "
11308 "next pointer is a pointer to I<long double> or the conversion will be B<d>, "
11309 "B<i>, B<o>, B<u>, or B<x> and the next pointer is a pointer to I<long long>."
11310 msgstr ""
11311 "B<e>, B<f>, B<g> 変換で、次のポインタが I<long double> へのポインタであること"
11312 "を示す。もしくは、 B<d>, B<i>, B<o>, B<u>, B<x> 変換で、次のポインタが "
11313 "I<long long> へのポインタであることのいずれかであることを示す。"
11314
11315 #. type: Plain text
11316 #: build/C/man3/scanf.3:359
11317 msgid "equivalent to B<L>.  This specifier does not exist in ANSI C."
11318 msgstr "B<L> と同一である。 この修飾子は ANSI C には存在しない。"
11319
11320 #. type: Plain text
11321 #: build/C/man3/scanf.3:366
11322 msgid ""
11323 "As for B<h>, but the next pointer is a pointer to a I<ptrdiff_t>.  This "
11324 "modifier was introduced in C99."
11325 msgstr ""
11326 "B<h> と同様だが、次のポインタが I<ptrdiff_t> へのポインタであることを示す。 "
11327 "この修飾子は C99 で導入された。"
11328
11329 #. type: Plain text
11330 #: build/C/man3/scanf.3:373
11331 msgid ""
11332 "As for B<h>, but the next pointer is a pointer to a I<size_t>.  This "
11333 "modifier was introduced in C99."
11334 msgstr ""
11335 "B<h> と同様だが、次のポインタが I<size_t> へのポインタであることを示す。 この"
11336 "修飾子は C99 で導入された。"
11337
11338 #. type: Plain text
11339 #: build/C/man3/scanf.3:377
11340 msgid "The following I<conversion specifiers> are available:"
11341 msgstr "以下の I<「変換指定子」> が利用可能である。"
11342
11343 #. type: Plain text
11344 #: build/C/man3/scanf.3:386
11345 msgid ""
11346 "Matches a literal \\(aq%\\(aq.  That is, B<%\\&%> in the format string "
11347 "matches a single input \\(aq%\\(aq character.  No conversion is done (but "
11348 "initial white space characters are discarded), and assignment does not occur."
11349 msgstr ""
11350 "文字 \\(aq%\\(aq に対応する。 書式文字列の中の B<%\\&%> は単一の文字 \\(aq%"
11351 "\\(aq に対応する。 変換は行われず (但し、先頭のホワイトスペース文字は捨てられ"
11352 "る)、 変数への代入は生じない。"
11353
11354 #. type: TP
11355 #: build/C/man3/scanf.3:386
11356 #, no-wrap
11357 msgid "B<d>"
11358 msgstr "B<d>"
11359
11360 #. type: Plain text
11361 #: build/C/man3/scanf.3:391
11362 msgid ""
11363 "Matches an optionally signed decimal integer; the next pointer must be a "
11364 "pointer to I<int>."
11365 msgstr ""
11366 "符号つきの 10進の整数に対応する。 次のポインタは I<int> へのポインタでなけれ"
11367 "ばならない。"
11368
11369 #. type: TP
11370 #: build/C/man3/scanf.3:391
11371 #, no-wrap
11372 msgid "B<D>"
11373 msgstr "B<D>"
11374
11375 #. type: Plain text
11376 #: build/C/man3/scanf.3:400
11377 msgid ""
11378 "Equivalent to I<ld>; this exists only for backward compatibility.  (Note: "
11379 "thus only in libc4.  In libc5 and glibc the B<%D> is silently ignored, "
11380 "causing old programs to fail mysteriously.)"
11381 msgstr ""
11382 "I<ld> と同一である。これは以前の仕様との互換性だけのためにある。 (注意: これ"
11383 "は libc4 の場合だけである。 libc5 や glibc では B<%D> は暗黙のうちに無視さ"
11384 "れ、古いプログラムにおいて謎に満ちた失敗の原因となる。)"
11385
11386 #. type: TP
11387 #: build/C/man3/scanf.3:400
11388 #, no-wrap
11389 msgid "B<i>"
11390 msgstr "B<i>"
11391
11392 #. type: Plain text
11393 #: build/C/man3/scanf.3:412
11394 msgid ""
11395 "Matches an optionally signed integer; the next pointer must be a pointer to "
11396 "I<int>.  The integer is read in base 16 if it begins with I<0x> or I<0X>, in "
11397 "base 8 if it begins with I<0>, and in base 10 otherwise.  Only characters "
11398 "that correspond to the base are used."
11399 msgstr ""
11400 "符号つき整数に対応する。 次のポインタは I<int> へのポインタでなければならな"
11401 "い。 この整数は I<0x> または I<0X> で開始する場合には 16 進数、 I<0> で開始す"
11402 "る場合には 8 進数、その他の場合には 10進数として読み込まれる。 この変換で使用"
11403 "される文字は、これらの基数に対応しているものだけである。"
11404
11405 #. type: TP
11406 #: build/C/man3/scanf.3:412
11407 #, no-wrap
11408 msgid "B<o>"
11409 msgstr "B<o>"
11410
11411 #. type: Plain text
11412 #: build/C/man3/scanf.3:416
11413 msgid ""
11414 "Matches an unsigned octal integer; the next pointer must be a pointer to "
11415 "I<unsigned int>."
11416 msgstr ""
11417 "符号なしの 8 進の整数に対応する。 次のポインタは I<unsigned int> でなければな"
11418 "らない。"
11419
11420 #. type: TP
11421 #: build/C/man3/scanf.3:416
11422 #, no-wrap
11423 msgid "B<u>"
11424 msgstr "B<u>"
11425
11426 #. type: Plain text
11427 #: build/C/man3/scanf.3:421
11428 msgid ""
11429 "Matches an unsigned decimal integer; the next pointer must be a pointer to "
11430 "I<unsigned int>."
11431 msgstr ""
11432 "符号なしの 10進の整数に対応する。 次のポインタは I<unsigned int> へのポインタ"
11433 "でなければならない。"
11434
11435 #. type: Plain text
11436 #: build/C/man3/scanf.3:426
11437 msgid ""
11438 "Matches an unsigned hexadecimal integer; the next pointer must be a pointer "
11439 "to I<unsigned int>."
11440 msgstr ""
11441 "符号なしの 16 進の整数に対応する。 次のポインタは I<unsigned int> へのポイン"
11442 "タでなければならない。"
11443
11444 #. type: TP
11445 #: build/C/man3/scanf.3:426
11446 #, no-wrap
11447 msgid "B<X>"
11448 msgstr "B<X>"
11449
11450 #. type: Plain text
11451 #: build/C/man3/scanf.3:430
11452 msgid "Equivalent to B<x>."
11453 msgstr "B<x> と同一である。"
11454
11455 #. type: TP
11456 #: build/C/man3/scanf.3:430
11457 #, no-wrap
11458 msgid "B<f>"
11459 msgstr "B<f>"
11460
11461 #. type: Plain text
11462 #: build/C/man3/scanf.3:435
11463 msgid ""
11464 "Matches an optionally signed floating-point number; the next pointer must be "
11465 "a pointer to I<float>."
11466 msgstr ""
11467 "符号つき浮動小数点実数に対応する。 次のポインタは I<float> へのポインタでなけ"
11468 "ればならない。"
11469
11470 #. type: TP
11471 #: build/C/man3/scanf.3:435
11472 #, no-wrap
11473 msgid "B<e>"
11474 msgstr "B<e>"
11475
11476 #. type: Plain text
11477 #: build/C/man3/scanf.3:439 build/C/man3/scanf.3:443 build/C/man3/scanf.3:447
11478 msgid "Equivalent to B<f>."
11479 msgstr "B<f> と同一である。"
11480
11481 #. type: TP
11482 #: build/C/man3/scanf.3:439
11483 #, no-wrap
11484 msgid "B<g>"
11485 msgstr "B<g>"
11486
11487 #. type: TP
11488 #: build/C/man3/scanf.3:443
11489 #, no-wrap
11490 msgid "B<E>"
11491 msgstr "B<E>"
11492
11493 #. type: Plain text
11494 #: build/C/man3/scanf.3:451
11495 msgid "(C99) Equivalent to B<f>."
11496 msgstr "(C99)  B<f> と同一である。"
11497
11498 #. type: Plain text
11499 #: build/C/man3/scanf.3:459
11500 msgid ""
11501 "Matches a sequence of non-white-space characters; the next pointer must be a "
11502 "pointer to character array that is long enough to hold the input sequence "
11503 "and the terminating null byte (\\(aq\\e0\\(aq), which is added "
11504 "automatically.  The input string stops at white space or at the maximum "
11505 "field width, whichever occurs first."
11506 msgstr ""
11507 "ホワイトスペースではない文字で構成された文字列に対応する。 次のポインタは文字"
11508 "の配列へのポインタでなければならず、 その文字配列は、入力された文字列と (自動"
11509 "的に追加される) 終端の NULL バイト (\\(aq\\e0\\(aq) を格納するのに十分な大き"
11510 "さでなければならない。 文字列の入力は、ホワイトスペースが入力されるか、最大"
11511 "フィールド幅に 達するか、のどちらかが起こると停止される。"
11512
11513 #. type: Plain text
11514 #: build/C/man3/scanf.3:470
11515 msgid ""
11516 "Matches a sequence of characters whose length is specified by the I<maximum "
11517 "field width> (default 1); the next pointer must be a pointer to I<char>, and "
11518 "there must be enough room for all the characters (no terminating null byte "
11519 "is added).  The usual skip of leading white space is suppressed.  To skip "
11520 "white space first, use an explicit space in the format."
11521 msgstr ""
11522 "I<「最大フィールド幅」> (デフォルトは 1) で指定された幅の文字の列に対応す"
11523 "る。 次のポインタは I<char> へのポインタで、すべての文字を格納するのに十分な"
11524 "領域が なければならない (終端の NULL バイトは追加されない)。 通常行われる先頭"
11525 "のホワイトスペースの読み飛ばしは行われない。 先頭のホワイトスペースを読み飛ば"
11526 "すためには、 フォーマット文の中で明示的にスペースを使用すれば良い。"
11527
11528 #. type: TP
11529 #: build/C/man3/scanf.3:470
11530 #, no-wrap
11531 msgid "B<\\&[>"
11532 msgstr "B<\\&[>"
11533
11534 #. type: Plain text
11535 #: build/C/man3/scanf.3:503
11536 msgid ""
11537 "Matches a nonempty sequence of characters from the specified set of accepted "
11538 "characters; the next pointer must be a pointer to I<char>, and there must be "
11539 "enough room for all the characters in the string, plus a terminating null "
11540 "byte.  The usual skip of leading white space is suppressed.  The string is "
11541 "to be made up of characters in (or not in) a particular set; the set is "
11542 "defined by the characters between the open bracket B<[> character and a "
11543 "close bracket B<]> character.  The set I<excludes> those characters if the "
11544 "first character after the open bracket is a circumflex (B<^>).  To include a "
11545 "close bracket in the set, make it the first character after the open bracket "
11546 "or the circumflex; any other position will end the set.  The hyphen "
11547 "character B<-> is also special; when placed between two other characters, it "
11548 "adds all intervening characters to the set.  To include a hyphen, make it "
11549 "the last character before the final close bracket.  For instance, B<[^]0-9-]"
11550 "> means the set \"everything except close bracket, zero through nine, and "
11551 "hyphen\".  The string ends with the appearance of a character not in the "
11552 "(or, with a circumflex, in) set or when the field width runs out."
11553 msgstr ""
11554 "格納された文字列のうちから取り出された、 指定された文字の集合で構成される空で"
11555 "はない文字の列に対応する。 次のポインタは I<char> へのポインタでなければなら"
11556 "ず、 そこには文字列中のすべての文字と終端の NULL バイト を格納するための十分"
11557 "な領域がなければならない。 通常行われる先頭のホワイトスペースの読み飛ばしは行"
11558 "われない。 この文字列は特別な集合の中の文字で構成されている。 この集合は 開き"
11559 "括弧 B<[> と閉じ括弧 B<]> の間の文字で定義される。 開き括弧のあとの最初の文字"
11560 "が曲アクセント記号 (B<^>)  の場合、集合はこれらの文字を含まないものとなる。 "
11561 "閉じ括弧を集合に含ませるためには、この文字を開き括弧または 曲アクセント記号の"
11562 "あとの最初の文字にすればよい。 つまり、他の位置に閉じ括弧を置くと文字の集合が"
11563 "終る。 ハイフン B<-> もまた特殊文字である。 二つの異なる文字の間に置かれた"
11564 "時、この文字は、 その間にある全ての文字を集合に加える。 ハイフン自体を含ませ"
11565 "るためには、 括弧が閉じる前の最後の一文字をハイフンにすればよい。 例えば、 B<"
11566 "[^]0-9-]> は「閉じ括弧、0 〜 9、ハイフンの 3 種類を除く全ての文字」の集合を意"
11567 "味する。 この文字列は 集合に含まれていない (曲アクセントの場合には含まれる) "
11568 "文字の 出現または確保された領域が使い切られた時に終了する。"
11569
11570 #. type: Plain text
11571 #: build/C/man3/scanf.3:511
11572 msgid ""
11573 "Matches a pointer value (as printed by B<%p> in B<printf>(3); the next "
11574 "pointer must be a pointer to a pointer to I<void>."
11575 msgstr ""
11576 "(B<printf>(3)  の B<%p> で印字されるような) ポインタ値に対応する。 次のポイン"
11577 "タは I<void> へのポインタへのポインタでなければならない。"
11578
11579 #. type: Plain text
11580 #: build/C/man3/scanf.3:531
11581 msgid ""
11582 "Nothing is expected; instead, the number of characters consumed thus far "
11583 "from the input is stored through the next pointer, which must be a pointer "
11584 "to I<int>.  This is I<not> a conversion, although it can be suppressed with "
11585 "the B<*> assignment-suppression character.  The C standard says: \"Execution "
11586 "of a B<%n> directive does not increment the assignment count returned at the "
11587 "completion of execution\" but the Corrigendum seems to contradict this.  "
11588 "Probably it is wise not to make any assumptions on the effect of B<%n> "
11589 "conversions on the return value."
11590 msgstr ""
11591 "どんな入力も必要としない。 そのかわりに、 入力からここまで消費された文字数が"
11592 "次のポインタで指定された場所に 格納される。 このポインタは I<int> へのポイン"
11593 "タでなければならない。 変換を抑制するのであれば B<*> 代入抑制文字を使って抑制"
11594 "することができるのだが、 この変換指定子は変換では「ない」。 C 言語の標準規格"
11595 "では「実行の完了時に返される代入の回数は B<%n> 命令の実行では増加しない」と"
11596 "なっているが、 正誤表の内容はこれと矛盾するようである。おそらく、 B<%n> 変換"
11597 "が返り値に与える影響についてはどのような仮定もしないのが 賢明であろう。"
11598
11599 #. type: Plain text
11600 #: build/C/man3/scanf.3:536
11601 msgid ""
11602 "These functions return the number of input items successfully matched and "
11603 "assigned, which can be fewer than provided for, or even zero in the event of "
11604 "an early matching failure."
11605 msgstr ""
11606 "これらの関数は、一致と代入が成功した入力要素の個数を返す。 返される値は渡され"
11607 "た変換の個数よりも少ないこともあり、 最初に一致の失敗があった場合には 0 にな"
11608 "ることもある。"
11609
11610 #. type: Plain text
11611 #: build/C/man3/scanf.3:548
11612 msgid ""
11613 "The value B<EOF> is returned if the end of input is reached before either "
11614 "the first successful conversion or a matching failure occurs.  B<EOF> is "
11615 "also returned if a read error occurs, in which case the error indicator for "
11616 "the stream (see B<ferror>(3))  is set, and I<errno> is set indicate the "
11617 "error."
11618 msgstr ""
11619 "最初の変換が成功する前に入力の最後に達して、一致の失敗が起こった場合には、 "
11620 "B<EOF> が返される。また、 読み込みエラーが発生した場合にも B<EOF> が返され"
11621 "る。読み込みエラーの場合には、そのストリームの エラー指示子がセットされ "
11622 "(B<ferror>(3)  参照)、 I<errno> にエラーを示す値がセットされる。"
11623
11624 #. type: Plain text
11625 #: build/C/man3/scanf.3:554
11626 msgid ""
11627 "The file descriptor underlying I<stream> is marked nonblocking, and the read "
11628 "operation would block."
11629 msgstr ""
11630 "I<stream> に対応するファイルディスクリプタが nonblocking となっており、 読み"
11631 "込み操作は停止 (block) することになる。"
11632
11633 #. type: Plain text
11634 #: build/C/man3/scanf.3:559
11635 msgid ""
11636 "The file descriptor underlying I<stream> is invalid, or not open for reading."
11637 msgstr ""
11638 "I<stream> に対応するファイルディスクリプタが無効であるが、 読み込み用にオープ"
11639 "ンされていない。"
11640
11641 #. type: Plain text
11642 #: build/C/man3/scanf.3:562
11643 msgid "Input byte sequence does not form a valid character."
11644 msgstr "入力されたバイト列が有効な文字を構成していない。"
11645
11646 #. type: Plain text
11647 #: build/C/man3/scanf.3:566
11648 msgid "The read operation was interrupted by a signal; see B<signal>(7)."
11649 msgstr "読み込み操作がシグナルにより割り込まれた。 B<signal>(7)  参照。"
11650
11651 #. type: Plain text
11652 #: build/C/man3/scanf.3:571
11653 msgid "Not enough arguments; or I<format> is NULL."
11654 msgstr "引き数が十分でない。または I<format> が NULL である。"
11655
11656 #. type: Plain text
11657 #: build/C/man3/scanf.3:574
11658 msgid "Out of memory."
11659 msgstr "メモリ不足。"
11660
11661 #. type: TP
11662 #: build/C/man3/scanf.3:574
11663 #, no-wrap
11664 msgid "B<ERANGE>"
11665 msgstr "B<ERANGE>"
11666
11667 #. type: Plain text
11668 #: build/C/man3/scanf.3:578
11669 msgid ""
11670 "The result of an integer conversion would exceed the size that can be stored "
11671 "in the corresponding integer type."
11672 msgstr "整数変換の結果が、対応する整数型に格納できるサイズを越えてしまう。"
11673
11674 #. type: Plain text
11675 #: build/C/man3/scanf.3:588
11676 msgid ""
11677 "The functions B<fscanf>(), B<scanf>(), and B<sscanf>()  conform to C89 and "
11678 "C99 and POSIX.1-2001.  These standards do not specify the B<ERANGE> error."
11679 msgstr ""
11680 "B<fscanf>(), B<scanf>(), B<sscanf>()  関数は C89, C99, POSIX.1-2001 に準拠し"
11681 "ている。 これらの標準では、エラー B<ERANGE> は規定されていない。"
11682
11683 #. type: Plain text
11684 #: build/C/man3/scanf.3:598
11685 msgid ""
11686 "The B<q> specifier is the 4.4BSD notation for I<long long>, while B<ll> or "
11687 "the usage of B<L> in integer conversions is the GNU notation."
11688 msgstr ""
11689 "B<q> 指定子は I<long long> の 4.4BSD での記述方法である。 一方、整数変換での "
11690 "B<ll> または B<L> の使用は GNU での拡張である。"
11691
11692 #. type: Plain text
11693 #: build/C/man3/scanf.3:609
11694 msgid ""
11695 "The Linux version of these functions is based on the I<GNU> I<libio> "
11696 "library.  Take a look at the I<info> documentation of I<GNU> I<libc "
11697 "(glibc-1.08)> for a more concise description."
11698 msgstr ""
11699 "これらの関数の Linux 版は I<GNU> I<libio> ライブラリーを元にしている。 より簡"
11700 "潔な説明には I<GNU> I<libc (glibc-1.08)> の I<info> 文書に目を通すこと。"
11701
11702 #. type: Plain text
11703 #: build/C/man3/scanf.3:615
11704 msgid ""
11705 "The GNU C library supported the dynamic allocation conversion specifier (as "
11706 "a nonstandard extension) via the B<a> character.  This feature seems to be "
11707 "present at least as far back as glibc 2.0."
11708 msgstr ""
11709
11710 #. type: Plain text
11711 #: build/C/man3/scanf.3:625
11712 msgid ""
11713 "It is not available if the program is compiled with I<gcc -std=c99> or I<gcc "
11714 "-D_ISOC99_SOURCE> (unless B<_GNU_SOURCE> is also specified), in which case "
11715 "the B<a> is interpreted as a specifier for floating-point numbers (see "
11716 "above)."
11717 msgstr ""
11718 "この修飾子は I<gcc -std=c99> や I<gcc -D_ISOC99_SOURCE> でコンパイルしたプロ"
11719 "グラムでは (B<_GNU_SOURCE> も同時に指定していない場合) 利用できない。この場"
11720 "合、 B<a> は (上述の通り) 浮動小数点数を示す変換指定子と解釈される。"
11721
11722 #. type: Plain text
11723 #: build/C/man3/scanf.3:634
11724 msgid ""
11725 "Since version 2.7, glibc also provides the B<m> modifier for the same "
11726 "purpose as the B<a> modifier.  The B<m> modifier has the following "
11727 "advantages:"
11728 msgstr ""
11729 "バージョン 2.7 以降では、glibc は B<a> 修飾子と同じ目的で B<m> 修飾子も提供し"
11730 "ている。 B<m> 修飾子は以下の利点がある。"
11731
11732 #. type: Plain text
11733 #: build/C/man3/scanf.3:639
11734 msgid "It may also be applied to B<%c> conversion specifiers (e.g., B<%3mc>)."
11735 msgstr "B<%c> 変換指定子にも適用できる (例えば B<%3mc>)。"
11736
11737 #. type: Plain text
11738 #: build/C/man3/scanf.3:645
11739 msgid ""
11740 "It avoids ambiguity with respect to the B<%a> floating-point conversion "
11741 "specifier (and is unaffected by I<gcc -std=c99> etc.)"
11742 msgstr ""
11743 "浮動小数点変換指定子としての B<%a> との紛らわしさが避けられる (また I<gcc -"
11744 "std=c99> などの影響も避けられる)。"
11745
11746 #. type: Plain text
11747 #: build/C/man3/scanf.3:647
11748 msgid "It is specified in the POSIX.1-2008 standard."
11749 msgstr "POSIX.1-2008 標準で規定されている。"
11750
11751 #. type: Plain text
11752 #: build/C/man3/scanf.3:660
11753 msgid ""
11754 "All functions are fully C89 conformant, but provide the additional "
11755 "specifiers B<q> and B<a> as well as an additional behavior of the B<L> and "
11756 "B<l> specifiers.  The latter may be considered to be a bug, as it changes "
11757 "the behavior of specifiers defined in C89."
11758 msgstr ""
11759 "全ての関数は、完全に C89 に準拠している。しかし 追加で B<q> と B<a> 指定子が"
11760 "提供されており、同様に B<L> と B<l> 指定子の付加的な振る舞いもある。後者は、 "
11761 "C89 で定義された指定子の振る舞いを変更するものなので、 バグとみなされるかもし"
11762 "れない。"
11763
11764 #. type: Plain text
11765 #: build/C/man3/scanf.3:676
11766 msgid ""
11767 "Some combinations of the type modifiers and conversion specifiers defined by "
11768 "ANSI C do not make sense (e.g., B<%Ld>).  While they may have a well-defined "
11769 "behavior on Linux, this need not to be so on other architectures.  Therefore "
11770 "it usually is better to use modifiers that are not defined by ANSI C at all, "
11771 "that is, use B<q> instead of B<L> in combination with B<d>, B<i>, B<o>, "
11772 "B<u>, B<x>, and B<X> conversions or B<ll>."
11773 msgstr ""
11774 "ANSI C で定義された型修飾子と変換指定子の組み合わせの中には 意味を\n"
11775 "なさないものがある (例えば、 B<%Ld>)。 これらが指定された場合、 \n"
11776 "Linux 上でははっきりと定義された振る舞いをするかもしれないが、\n"
11777 "他のアーキテクチャでも同様になっているとは限らない。\n"
11778 "それゆえに、ほとんどの場合、 ANSI C で定義されていない修飾子を使用した\n"
11779 "方が良い。すなわち、 B<d>, B<i>, B<o>, B<u>, B<x>, B<X> 変換や B<ll>\n"
11780 "と組み合わせる場合には、 B<L> の代わりに B<q> を使用した方が良い。"
11781
11782 #. type: Plain text
11783 #: build/C/man3/scanf.3:682
11784 msgid ""
11785 "The usage of B<q> is not the same as on 4.4BSD, as it may be used in float "
11786 "conversions equivalently to B<L>."
11787 msgstr ""
11788 "B<q> の使用方法は 4.4BSD と同じではない。 4.4BSD では B<q> は B<L> と同等に浮"
11789 "動小数の変換に使用される。"
11790
11791 #. type: Plain text
11792 #: build/C/man3/scanf.3:692
11793 #, fuzzy
11794 #| msgid ""
11795 #| "The GNU C library supports a nonstandard extension that causes the "
11796 #| "library to dynamically allocate a string of sufficient size for input "
11797 #| "strings for the B<%s> and B<%a[>I<range>B<]> conversion specifiers.  To "
11798 #| "make use of this feature, specify B<a> as a length modifier (thus B<%as> "
11799 #| "or B<%a[>I<range>B<]>).  The caller must B<free>(3)  the returned string, "
11800 #| "as in the following example:"
11801 msgid ""
11802 "To use the dynamic allocation conversion specifier, specify B<m> as a length "
11803 "modifier (thus B<%ms> or B<%m[>I<range>B<]>).  The caller must B<free>(3)  "
11804 "the returned string, as in the following example:"
11805 msgstr ""
11806 "GNU C ライブラリ (glibc) では非標準のオプションをサポートしており、 このオプ"
11807 "ションを使うと変換指定子 B<%s> や B<%a[>I<range>B<]> への入力文字列に対して十"
11808 "分な大きさの文字列をライブラリが動的に確保する ようになる。 この機能を使用す"
11809 "るには、長さ修飾子として B<a> を指定する (したがって、全体としては B<%as> や "
11810 "B<%a[>I<range>B<]> となる)。 以下の例にあるように、呼び出し側は返された文字列"
11811 "を B<free>(3)  しなければならない。"
11812
11813 #. type: Plain text
11814 #: build/C/man3/scanf.3:697
11815 #, no-wrap
11816 msgid ""
11817 "char *p;\n"
11818 "int n;\n"
11819 msgstr ""
11820 "char *p;\n"
11821 "int n;\n"
11822
11823 #. type: Plain text
11824 #: build/C/man3/scanf.3:708
11825 #, no-wrap
11826 msgid ""
11827 "errno = 0;\n"
11828 "n = scanf(\"%m[a-z]\", &p);\n"
11829 "if (n == 1) {\n"
11830 "    printf(\"read: %s\\en\", p);\n"
11831 "    free(p);\n"
11832 "} else if (errno != 0) {\n"
11833 "    perror(\"scanf\");\n"
11834 "} else {\n"
11835 "    fprintf(stderr, \"No matching characters\\en\");\n"
11836 "}\n"
11837 msgstr ""
11838 "errno = 0;\n"
11839 "n = scanf(\"%m[a-z]\", &p);\n"
11840 "if (n == 1) {\n"
11841 "    printf(\"read: %s\\en\", p);\n"
11842 "    free(p);\n"
11843 "} else if (errno != 0) {\n"
11844 "    perror(\"scanf\");\n"
11845 "} else {\n"
11846 "    fprintf(stderr, \"No matching characters\\en\");\n"
11847 "}\n"
11848
11849 #. type: Plain text
11850 #: build/C/man3/scanf.3:716
11851 #, fuzzy
11852 #| msgid ""
11853 #| "As shown in the above example, it is only necessary to call B<free>(3)  "
11854 #| "if the B<scanf>()  call successfully read a string."
11855 msgid ""
11856 "As shown in the above example, it is necessary to call B<free>(3)  only if "
11857 "the B<scanf>()  call successfully read a string."
11858 msgstr ""
11859 "上記の例にあるように、 B<scanf>()  が文字列の読み込みに成功した場合にだけ、 "
11860 "B<free>(3)  を呼び出す必要がある。"
11861
11862 #. type: Plain text
11863 #: build/C/man3/scanf.3:723
11864 msgid ""
11865 "B<getc>(3), B<printf>(3), B<setlocale>(3), B<strtod>(3), B<strtol>(3), "
11866 "B<strtoul>(3)"
11867 msgstr ""
11868 "B<getc>(3), B<printf>(3)  B<setlocale>(3), B<strtod>(3), B<strtol>(3), "
11869 "B<strtoul>(3),"
11870
11871 #. type: TH
11872 #: build/C/man3/setbuf.3:48
11873 #, no-wrap
11874 msgid "SETBUF"
11875 msgstr "SETBUF"
11876
11877 #. type: TH
11878 #: build/C/man3/setbuf.3:48
11879 #, no-wrap
11880 msgid "2012-08-03"
11881 msgstr "2012-08-03"
11882
11883 #. type: Plain text
11884 #: build/C/man3/setbuf.3:51
11885 msgid "setbuf, setbuffer, setlinebuf, setvbuf - stream buffering operations"
11886 msgstr ""
11887 "setbuf, setbuffer, setlinebuf, setvbuf - ストリームのバッファリングの操作"
11888
11889 #. type: Plain text
11890 #: build/C/man3/setbuf.3:56
11891 #, no-wrap
11892 msgid "B<void setbuf(FILE *>I<stream>B<, char *>I<buf>B<);>\n"
11893 msgstr "B<void setbuf(FILE *>I<stream>B<, char *>I<buf>B<);>\n"
11894
11895 #. type: Plain text
11896 #: build/C/man3/setbuf.3:58
11897 #, no-wrap
11898 msgid "B<void setbuffer(FILE *>I<stream>B<, char *>I<buf>B<, size_t >I<size>B<);>\n"
11899 msgstr "B<void setbuffer(FILE *>I<stream>B<, char *>I<buf>B<, size_t >I<size>B<);>\n"
11900
11901 #. type: Plain text
11902 #: build/C/man3/setbuf.3:60
11903 #, no-wrap
11904 msgid "B<void setlinebuf(FILE *>I<stream>B<);>\n"
11905 msgstr "B<void setlinebuf(FILE *>I<stream>B<);>\n"
11906
11907 #. type: Plain text
11908 #: build/C/man3/setbuf.3:63
11909 #, no-wrap
11910 msgid "B<int setvbuf(FILE *>I<stream>B<, char *>I<buf>B<, int >I<mode>B<, size_t >I<size>B<);>\n"
11911 msgstr "B<int setvbuf(FILE *>I<stream>B<, char *>I<buf>B<, int >I<mode>B<, size_t >I<size>B<);>\n"
11912
11913 #. type: Plain text
11914 #: build/C/man3/setbuf.3:73
11915 msgid "B<setbuffer>(), B<setlinebuf>(): _BSD_SOURCE"
11916 msgstr "B<setbuffer>(), B<setlinebuf>(): _BSD_SOURCE"
11917
11918 #. type: Plain text
11919 #: build/C/man3/setbuf.3:96
11920 msgid ""
11921 "The three types of buffering available are unbuffered, block buffered, and "
11922 "line buffered.  When an output stream is unbuffered, information appears on "
11923 "the destination file or terminal as soon as written; when it is block "
11924 "buffered many characters are saved up and written as a block; when it is "
11925 "line buffered characters are saved up until a newline is output or input is "
11926 "read from any stream attached to a terminal device (typically I<stdin>).  "
11927 "The function B<fflush>(3)  may be used to force the block out early.  (See "
11928 "B<fclose>(3).)  Normally all files are block buffered.  When the first I/O "
11929 "operation occurs on a file, B<malloc>(3)  is called, and a buffer is "
11930 "obtained.  If a stream refers to a terminal (as I<stdout> normally does) it "
11931 "is line buffered.  The standard error stream I<stderr> is always unbuffered "
11932 "by default."
11933 msgstr ""
11934 "バッファリングには unbuffered, block buffered, line buffered の3つのタイプが "
11935 "ある。出力ストリームのタイプが unbuffered の場合、データを書き込むとすぐに出 "
11936 "力先ファイルに書き込まれるかターミナルに表示される。block buffered の場合、"
11937 "文 字の読み書きはブロック単位でいっぺんに行われる。line buffered の場合、 新"
11938 "しい行が出力されるか、ターミナルデバイスに接続しているストリーム (通常、"
11939 "I<stdin>) から新しい行が入力されるまで文字がたくわえられる。 ブロックを強制的"
11940 "に出力するには B<fflush>(3)  関数を使う。 (B<fclose>(3)  を参照のこと) 通常、"
11941 "ファイルはすべて block buffered である。ファイルに対して 初めて入出力処理を行"
11942 "うと B<malloc>(3)  が呼び出されバッファが獲得される。もし ストリームが (通"
11943 "常、 I<stdout> がそうであるように) ターミナルを参照する場合には、ファイルは "
11944 "line buffered と なる。標準エラー出力 I<stderr> はデフォルトでは常に "
11945 "unbuffered である。"
11946
11947 #. type: Plain text
11948 #: build/C/man3/setbuf.3:103
11949 msgid ""
11950 "The B<setvbuf>()  function may be used on any open stream to change its "
11951 "buffer.  The I<mode> argument must be one of the following three macros:"
11952 msgstr ""
11953 "B<setvbuf>()  関数は、オープンしている任意のストリームに対してバッファを変更"
11954 "できる。 引き数 I<mode> は、次の 3 つのマクロのうちいずれかである:"
11955
11956 #. type: TP
11957 #: build/C/man3/setbuf.3:104
11958 #, no-wrap
11959 msgid "B<_IONBF>"
11960 msgstr "B<_IONBF>"
11961
11962 #. type: Plain text
11963 #: build/C/man3/setbuf.3:107
11964 msgid "unbuffered"
11965 msgstr "unbuffered"
11966
11967 #. type: TP
11968 #: build/C/man3/setbuf.3:107
11969 #, no-wrap
11970 msgid "B<_IOLBF>"
11971 msgstr "B<_IOLBF>"
11972
11973 #. type: Plain text
11974 #: build/C/man3/setbuf.3:110
11975 msgid "line buffered"
11976 msgstr "line buffered"
11977
11978 #. type: TP
11979 #: build/C/man3/setbuf.3:110
11980 #, no-wrap
11981 msgid "B<_IOFBF>"
11982 msgstr "B<_IOFBF>"
11983
11984 #. type: Plain text
11985 #: build/C/man3/setbuf.3:113
11986 msgid "fully buffered"
11987 msgstr "fully buffered"
11988
11989 #. type: Plain text
11990 #: build/C/man3/setbuf.3:129
11991 #, fuzzy
11992 #| msgid ""
11993 #| "Except for unbuffered files, the I<buf> argument should point to a buffer "
11994 #| "at least I<size> bytes long; this buffer will be used instead of the "
11995 #| "current buffer.  If the argument I<buf> is NULL, only the mode is "
11996 #| "affected; a new buffer will be allocated on the next read or write "
11997 #| "operation.  The B<setvbuf>()  function may only be used after opening a "
11998 #| "stream and before any other operations have been performed on it."
11999 msgid ""
12000 "Except for unbuffered files, the I<buf> argument should point to a buffer at "
12001 "least I<size> bytes long; this buffer will be used instead of the current "
12002 "buffer.  If the argument I<buf> is NULL, only the mode is affected; a new "
12003 "buffer will be allocated on the next read or write operation.  The B<setvbuf>"
12004 "()  function may be used only after opening a stream and before any other "
12005 "operations have been performed on it."
12006 msgstr ""
12007 "unbuffered のファイルを除き、 I<buf> 引数は I<size> バイト以上の大きさのバッ"
12008 "ファを指していなければならない。このバッファは現在の バッファの代わりに用いら"
12009 "れる。もし、引数 I<buf> が NULL ならば、モードだけが変更される。 新しいバッ"
12010 "ファは次に読み書きした際に割り当てられる。 B<setvbuf>()  関数は、ストリームを"
12011 "オープンした後、 そのストリームに対して何らかの操作をする前にのみ使用できる。"
12012
12013 #. type: Plain text
12014 #: build/C/man3/setbuf.3:135
12015 msgid ""
12016 "The other three calls are, in effect, simply aliases for calls to B<setvbuf>"
12017 "().  The B<setbuf>()  function is exactly equivalent to the call"
12018 msgstr ""
12019 "他の 3 つの関数は B<setvbuf>()  の呼び出しに単純に置き換えることができる。 "
12020 "B<setbuf>()  関数は、"
12021
12022 #. type: Plain text
12023 #: build/C/man3/setbuf.3:138
12024 msgid "setvbuf(stream, buf, buf ? _IOFBF : _IONBF, BUFSIZ);"
12025 msgstr "setvbuf(stream, buf, buf ? _IOFBF : _IONBF, BUFSIZ);"
12026
12027 #. type: Plain text
12028 #: build/C/man3/setbuf.3:148
12029 msgid ""
12030 "The B<setbuffer>()  function is the same, except that the size of the buffer "
12031 "is up to the caller, rather than being determined by the default B<BUFSIZ>.  "
12032 "The B<setlinebuf>()  function is exactly equivalent to the call:"
12033 msgstr ""
12034 "と全く同等だし、 B<setbuffer>()  関数は、バッファサイズがデフォルト値 "
12035 "B<BUFSIZ> ではなく引数で与えられる点以外は同じである。 B<setlinebuf>()  関数"
12036 "は以下と同じである。"
12037
12038 #. type: Plain text
12039 #: build/C/man3/setbuf.3:151
12040 msgid "setvbuf(stream, NULL, _IOLBF, 0);"
12041 msgstr "setvbuf(stream, NULL, _IOLBF, 0);"
12042
12043 #. type: Plain text
12044 #: build/C/man3/setbuf.3:162
12045 msgid ""
12046 "The function B<setvbuf>()  returns 0 on success.  It returns nonzero on "
12047 "failure (I<mode> is invalid or the request cannot be honored).  It may set "
12048 "I<errno> on failure."
12049 msgstr ""
12050 "B<setvbuf>()  関数は、成功した場合 0 を返す。 失敗した場合、0 以外の値を返す "
12051 "(失敗とは、 I<mode> が不正な場合またはリクエストが条件を満たさない場合であ"
12052 "る)。 B<setvbuf>()  関数が失敗した場合は I<errno> を設定することもある。"
12053
12054 #. type: Plain text
12055 #: build/C/man3/setbuf.3:164
12056 msgid "The other functions do not return a value."
12057 msgstr "その他の関数は値を返さない。"
12058
12059 #. type: Plain text
12060 #: build/C/man3/setbuf.3:170
12061 msgid "The B<setbuf>()  and B<setvbuf>()  functions conform to C89 and C99."
12062 msgstr ""
12063 "B<setbuf>()  関数および B<setvbuf>()  関数は C89 と C99 に準拠している。"
12064
12065 #. type: Plain text
12066 #: build/C/man3/setbuf.3:180
12067 msgid ""
12068 "The B<setbuffer>()  and B<setlinebuf>()  functions are not portable to "
12069 "versions of BSD before 4.2BSD, and are available under Linux since libc "
12070 "4.5.21.  On 4.2BSD and 4.3BSD systems, B<setbuf>()  always uses a suboptimal "
12071 "buffer size and should be avoided."
12072 msgstr ""
12073 "B<setbuffer>()  関数および B<setlinebuf>()  関数は 4.2BSD より前の BSD とは互"
12074 "換性がない。また Linux でも(古いバージョン では)利用できないかもしれない。"
12075 "4.2BSD および 4.3BSD のシステムでは B<setbuf>()  は必ず追加のバッファーのサイ"
12076 "ズを使用するので、これも使うべきでない。"
12077
12078 #. type: Plain text
12079 #: build/C/man3/setbuf.3:187
12080 msgid ""
12081 "You must make sure that the space that I<buf> points to still exists by the "
12082 "time I<stream> is closed, which also happens at program termination.  For "
12083 "example, the following is invalid:"
12084 msgstr ""
12085 "I<stream> を閉じる時 (プログラムを終了する際にもこれは起きる) には、 I<buf> "
12086 "が指し示す空間とが存在していることを保証しなければならない。 例えば、次のよう"
12087 "な使い方は許されない:"
12088
12089 #. type: Plain text
12090 #: build/C/man3/setbuf.3:190
12091 #, no-wrap
12092 msgid "#include E<lt>stdio.hE<gt>\n"
12093 msgstr "#include E<lt>stdio.hE<gt>\n"
12094
12095 #. type: Plain text
12096 #: build/C/man3/setbuf.3:199
12097 #, no-wrap
12098 msgid ""
12099 "int\n"
12100 "main(void)\n"
12101 "{\n"
12102 "    char buf[BUFSIZ];\n"
12103 "    setbuf(stdin, buf);\n"
12104 "    printf(\"Hello, world!\\en\");\n"
12105 "    return 0;\n"
12106 "}\n"
12107 msgstr ""
12108 "int\n"
12109 "main(void)\n"
12110 "{\n"
12111 "    char buf[BUFSIZ];\n"
12112 "    setbuf(stdin, buf);\n"
12113 "    printf(\"Hello, world!\\en\");\n"
12114 "    return 0;\n"
12115 "}\n"
12116
12117 #. type: Plain text
12118 #: build/C/man3/setbuf.3:208
12119 msgid ""
12120 "B<fclose>(3), B<fflush>(3), B<fopen>(3), B<fread>(3), B<malloc>(3), B<printf>"
12121 "(3), B<puts>(3)"
12122 msgstr ""
12123 "B<fclose>(3), B<fflush>(3), B<fopen>(3), B<fread>(3), B<malloc>(3), B<printf>"
12124 "(3), B<puts>(3)"
12125
12126 #. type: TH
12127 #: build/C/man3/stdin.3:13
12128 #, no-wrap
12129 msgid "STDIN"
12130 msgstr "STDIN"
12131
12132 #. type: TH
12133 #: build/C/man3/stdin.3:13 build/C/man3/tmpfile.3:31
12134 #, no-wrap
12135 msgid "2008-07-14"
12136 msgstr "2008-07-14"
12137
12138 #. type: Plain text
12139 #: build/C/man3/stdin.3:16
12140 msgid "stdin, stdout, stderr - standard I/O streams"
12141 msgstr "stdin, stdout, stderr - 標準入出力ストリーム"
12142
12143 #. type: Plain text
12144 #: build/C/man3/stdin.3:23
12145 #, no-wrap
12146 msgid ""
12147 "B<extern FILE *>I<stdin>B<;>\n"
12148 "B<extern FILE *>I<stdout>B<;>\n"
12149 "B<extern FILE *>I<stderr>B<;>\n"
12150 msgstr ""
12151 "B<extern FILE *>I<stdin>B<;>\n"
12152 "B<extern FILE *>I<stdout>B<;>\n"
12153 "B<extern FILE *>I<stderr>B<;>\n"
12154
12155 #. type: Plain text
12156 #: build/C/man3/stdin.3:35
12157 msgid ""
12158 "Under normal circumstances every UNIX program has three streams opened for "
12159 "it when it starts up, one for input, one for output, and one for printing "
12160 "diagnostic or error messages.  These are typically attached to the user's "
12161 "terminal (see B<tty>(4)  but might instead refer to files or other devices, "
12162 "depending on what the parent process chose to set up.  (See also the "
12163 "\"Redirection\" section of B<sh>(1).)"
12164 msgstr ""
12165 "標準の環境では、 UNIX プログラムは起動時に、オープンされているストリー ムを "
12166 "3 つ与えられる。それぞれ入力用、出力用、診断メッセージやエラーメッ セージの表"
12167 "示用のものである。これらは通常ユーザの端末 (B<tty>(4)  を見よ) に接続されてい"
12168 "るが、親プロセスでの選択・設定によってファイル や他のデバイスに関連づけられて"
12169 "いることもある (B<sh>(1)  の「リダイレクション」セクションも参照のこと)。"
12170
12171 #. type: Plain text
12172 #: build/C/man3/stdin.3:45
12173 msgid ""
12174 "The input stream is referred to as \"standard input\"; the output stream is "
12175 "referred to as \"standard output\"; and the error stream is referred to as "
12176 "\"standard error\".  These terms are abbreviated to form the symbols used to "
12177 "refer to these files, namely I<stdin>, I<stdout>, and I<stderr>."
12178 msgstr ""
12179 "入力ストリームは \"standard input\" と呼ばれる。出力ストリームは \"standard "
12180 "output\"、エラーストリームは \"standard error\" と呼ばれる。 これらの用語を短"
12181 "縮したものがそれぞれのファイルを示すシンボルとなる。つ まり I<stdin>, "
12182 "I<stdout>, I<stderr> である。"
12183
12184 #. type: Plain text
12185 #: build/C/man3/stdin.3:54
12186 msgid ""
12187 "Each of these symbols is a B<stdio>(3)  macro of type pointer to I<FILE>, "
12188 "and can be used with functions like B<fprintf>(3)  or B<fread>(3)."
12189 msgstr ""
12190 "これらのシンボルは B<stdio>(3)  のマクロで、 FILE へのポインタ型である。した"
12191 "がって B<fprintf>(3)  や B<fread>(3)  などの関数とともに用いることができる。"
12192
12193 #. type: Plain text
12194 #: build/C/man3/stdin.3:63
12195 msgid ""
12196 "Since I<FILE>s are a buffering wrapper around UNIX file descriptors, the "
12197 "same underlying files may also be accessed using the raw UNIX file "
12198 "interface, that is, the functions like B<read>(2)  and B<lseek>(2)."
12199 msgstr ""
12200 "I<FILE> は UNIX のファイルディスクリプタにバッファ機能を追加したラッパー であ"
12201 "るから、これらのマクロにも対応するファイルがあり、 UNIX の raw ファ イルイン"
12202 "タフェース (B<read>(2)  や B<lseek>(2)  など) によってアクセスすることもでき"
12203 "る。"
12204
12205 #. type: Plain text
12206 #: build/C/man3/stdin.3:82
12207 msgid ""
12208 "On program startup, the integer file descriptors associated with the streams "
12209 "I<stdin>, I<stdout>, and I<stderr> are 0, 1, and 2, respectively.  The "
12210 "preprocessor symbols B<STDIN_FILENO>, B<STDOUT_FILENO>, and B<STDERR_FILENO> "
12211 "are defined with these values in I<E<lt>unistd.hE<gt>>.  (Applying B<freopen>"
12212 "(3)  to one of these streams can change the file descriptor number "
12213 "associated with the stream.)"
12214 msgstr ""
12215 "プログラムの起動時には、 ストリーム I<stdin>, I<stdout>, I<stderr> に結びつけ"
12216 "られているファイルディスクリプタの番号は、 それぞれ 0, 1, 2 である。 プリプロ"
12217 "セッサシンボル B<STDIN_FILENO>, B<STDOUT_FILENO>, B<STDERR_FILENO> は "
12218 "I<E<lt>unistd.hE<gt>> 中でそれぞれこれらの値に定義されている。 (これらのスト"
12219 "リームに対して B<freopen>(3)  を適用することで、そのストリームに関連付けられ"
12220 "たファイルディスクリプタ の番号を変更することができる。)"
12221
12222 #. type: Plain text
12223 #: build/C/man3/stdin.3:95
12224 msgid ""
12225 "Note that mixing use of I<FILE>s and raw file descriptors can produce "
12226 "unexpected results and should generally be avoided.  (For the masochistic "
12227 "among you: POSIX.1, section 8.2.3, describes in detail how this interaction "
12228 "is supposed to work.)  A general rule is that file descriptors are handled "
12229 "in the kernel, while stdio is just a library.  This means for example, that "
12230 "after an B<exec>(3), the child inherits all open file descriptors, but all "
12231 "old streams have become inaccessible."
12232 msgstr ""
12233 "I<FILE> と raw なファイルディスクリプタの併用は、予期できない結果を生じ るこ"
12234 "とがあるので、通常は避けるべきである。 (マゾヒスティックな人に: POSIX.1 のセ"
12235 "クション 8.2.3 には、この混用で動作がどのようになりそう かが詳しく記述されて"
12236 "いる。)  一般的なルールは以下の通り: ファイルディスクリプタはカーネルによっ"
12237 "て 扱われ、 stdio は単にライブラリによって扱われるのである。すなわち例えば "
12238 "B<exec>(3)  の後には、子プロセスはオープンされているファイルディスクリプタ を"
12239 "すべて継承するが、親からのストリームはすべてアクセス不可となる。"
12240
12241 #. type: Plain text
12242 #: build/C/man3/stdin.3:113
12243 msgid ""
12244 "Since the symbols I<stdin>, I<stdout>, and I<stderr> are specified to be "
12245 "macros, assigning to them is nonportable.  The standard streams can be made "
12246 "to refer to different files with help of the library function B<freopen>(3), "
12247 "specially introduced to make it possible to reassign I<stdin>, I<stdout>, "
12248 "and I<stderr>.  The standard streams are closed by a call to B<exit>(3)  and "
12249 "by normal program termination."
12250 msgstr ""
12251 "シンボル I<stdin>, I<stdout>, I<stderr> はすべてマクロとして定義されているの"
12252 "で、これらへの代入 は移植性を保証されない。標準ストリームはライブラリ関数 "
12253 "B<freopen>(3)  を用いれば、別のファイルを示すように変更することもできる。 こ"
12254 "のライブラリ関数は I<stdin>, I<stdout>, I<stderr> の再割り当てが可能なように"
12255 "特別に導入されたものである。 標準ストリームは B<exit>(3)  の呼び出しと、プロ"
12256 "グラムの正常終了によってクローズされる。"
12257
12258 #. type: Plain text
12259 #: build/C/man3/stdin.3:122
12260 msgid ""
12261 "The I<stdin>, I<stdout>, and I<stderr> macros conform to C89 and this "
12262 "standard also stipulates that these three streams shall be open at program "
12263 "startup."
12264 msgstr ""
12265 "I<stdin>, I<stdout>, I<stderr> マクロは C89 に準拠している。 また C89 では、"
12266 "これら 3 つのストリームがプログラム の起動時にオープンされているべきであるこ"
12267 "とが規定されている。"
12268
12269 #. type: Plain text
12270 #: build/C/man3/stdin.3:154
12271 msgid ""
12272 "The stream I<stderr> is unbuffered.  The stream I<stdout> is line-buffered "
12273 "when it points to a terminal.  Partial lines will not appear until B<fflush>"
12274 "(3)  or B<exit>(3)  is called, or a newline is printed.  This can produce "
12275 "unexpected results, especially with debugging output.  The buffering mode of "
12276 "the standard streams (or any other stream)  can be changed using the "
12277 "B<setbuf>(3)  or B<setvbuf>(3)  call.  Note that in case I<stdin> is "
12278 "associated with a terminal, there may also be input buffering in the "
12279 "terminal driver, entirely unrelated to stdio buffering.  (Indeed, normally "
12280 "terminal input is line buffered in the kernel.)  This kernel input handling "
12281 "can be modified using calls like B<tcsetattr>(3); see also B<stty>(1), and "
12282 "B<termios>(3)."
12283 msgstr ""
12284 "I<stderr> ストリームはバッファリングされていない。 I<stdout> ストリームは、端"
12285 "末に接続されているときには行単位でバッファリング されている。一行に満たない内"
12286 "容は、 B<fflush>(3)  か B<exit>(3)  が呼び出されるか、改行文字が印字されるま"
12287 "で表示されない。これは、 特にデバッグ時において、予期しない結果を生じる原因と"
12288 "なるかもしれない。 標準ストリームの (あるいは他のすべてのストリームの)  バッ"
12289 "ファリングモードは、 B<setbuf>(3)  または B<setvbuf>(3)  を呼び出すことによっ"
12290 "て変更できる。 ただし、 I<stdin> が端末に接続されているときは、端末のドライバ"
12291 "でバッファリングされている 可能性がある点にも注意すること。これは stdio の"
12292 "バッファリングとは全く 関係なく存在しうる。 (実際、通常だと端末入力はカーネル"
12293 "によって行単位 でバッファリングされている。) このカーネルによる入力の扱いは "
12294 "B<tcsetattr>(3)  などの呼び出しによって変更することができる。 B<stty>(1)  と "
12295 "B<termios>(3)  も参照すること。"
12296
12297 #. type: Plain text
12298 #: build/C/man3/stdin.3:160
12299 msgid "B<csh>(1), B<sh>(1), B<open>(2), B<fopen>(3), B<stdio>(3)"
12300 msgstr "B<csh>(1), B<sh>(1), B<open>(2), B<fopen>(3), B<stdio>(3)"
12301
12302 #. type: TH
12303 #: build/C/man3/stdio.3:39
12304 #, no-wrap
12305 msgid "STDIO"
12306 msgstr "STDIO"
12307
12308 #. type: TH
12309 #: build/C/man3/stdio.3:39
12310 #, no-wrap
12311 msgid "2001-12-26"
12312 msgstr "2001-12-26"
12313
12314 #. type: Plain text
12315 #: build/C/man3/stdio.3:42
12316 msgid "stdio - standard input/output library functions"
12317 msgstr "stdio - 標準入出力ライブラリ関数"
12318
12319 #. type: Plain text
12320 #: build/C/man3/stdio.3:46
12321 msgid "B<FILE *>I<stdin>B<;>"
12322 msgstr "B<FILE *>I<stdin>B<;>"
12323
12324 #. type: Plain text
12325 #: build/C/man3/stdio.3:48
12326 msgid "B<FILE *>I<stdout>B<;>"
12327 msgstr "B<FILE *>I<stdout>B<;>"
12328
12329 #. type: Plain text
12330 #: build/C/man3/stdio.3:50
12331 msgid "B<FILE *>I<stderr>B<;>"
12332 msgstr "B<FILE *>I<stderr>B<;>"
12333
12334 #. type: Plain text
12335 #: build/C/man3/stdio.3:57
12336 msgid ""
12337 "The standard I/O library provides a simple and efficient buffered stream I/O "
12338 "interface.  Input and output is mapped into logical data streams and the "
12339 "physical I/O characteristics are concealed.  The functions and macros are "
12340 "listed below; more information is available from the individual man pages."
12341 msgstr ""
12342 "標準入出力ライブラリは、簡単かつ効果のよい、 バッファリングされたストリーム入"
12343 "出力インターフェースを提供する。 入力と出力は論理データストリームに割り付けら"
12344 "れ、 入出力の物理的な特徴は隠蔽される。 このライブラリに属する関数とマクロを"
12345 "以下に挙げる。 より詳しい情報は個々の man ページから得ることができる。"
12346
12347 #. type: Plain text
12348 #: build/C/man3/stdio.3:80
12349 msgid ""
12350 "A stream is associated with an external file (which may be a physical "
12351 "device) by I<opening> a file, which may involve creating a new file.  "
12352 "Creating an existing file causes its former contents to be discarded.  If a "
12353 "file can support positioning requests (such as a disk file, as opposed to a "
12354 "terminal) then a I<file position indicator> associated with the stream is "
12355 "positioned at the start of the file (byte zero), unless the file is opened "
12356 "with append mode.  If append mode is used, it is unspecified whether the "
12357 "position indicator will be placed at the start or the end of the file.  The "
12358 "position indicator is maintained by subsequent reads, writes and positioning "
12359 "requests.  All input occurs as if the characters were read by successive "
12360 "calls to the B<fgetc>(3)  function; all output takes place as if all "
12361 "characters were written by successive calls to the B<fputc>(3)  function."
12362 msgstr ""
12363 "ファイルを I<オープン (open) する> ことによって、 ストリームは外部ファイル "
12364 "(通常は物理デバイス) に連結される。 この操作には新しくファイルを作成すること"
12365 "も含まれる。 既存のファイルと同じ名前のファイルを新たに作ると、 もとのファイ"
12366 "ルの中身が捨てられてしまう。 ファイルが位置指定リクエストをサポートしている "
12367 "(ディスクファイルなどが相当する。逆の例としては端末が挙げられる) 場合、 その"
12368 "ストリームに連結された I<ファイル位置指示子 (file position indicator)> は、追"
12369 "加モードで開かれない限りファイルの先頭 (0 バイト目) に位置する。 追加モードを"
12370 "使用した場合、 位置指示子をファイルの先頭に置かれるか末尾に置かれるかは規定さ"
12371 "れていない。 位置指示子は、 以降の読み書きや位置指定リクエストによって変更さ"
12372 "れる。 すべての入力は、 B<fgetc>(3)  関数を次々に呼び出して文字を読み込んだか"
12373 "のように行われる。 一方すべての出力は、 B<fputc>(3)  関数を次々に呼び出して文"
12374 "字を書き込んだかのように行われる。"
12375
12376 #. type: Plain text
12377 #: build/C/man3/stdio.3:90
12378 msgid ""
12379 "A file is disassociated from a stream by I<closing> the file.  Output "
12380 "streams are flushed (any unwritten buffer contents are transferred to the "
12381 "host environment) before the stream is disassociated from the file.  The "
12382 "value of a pointer to a I<FILE> object is indeterminate after a file is "
12383 "closed (garbage)."
12384 msgstr ""
12385 "ファイルを I<クローズ (close) する> ことによって、そのファイルはストリームか"
12386 "ら切り離される。 出力ストリームは、そのストリームがファイルから切り離される前"
12387 "にフラッシュされる (書き込まれていないすべてのバッファの内容がホスト環境に転"
12388 "送される)。 I<FILE> オブジェクトへのポインタの値は、 ファイルを閉じた後では不"
12389 "確定になる (ゴミになってしまう)。"
12390
12391 #. type: Plain text
12392 #: build/C/man3/stdio.3:103
12393 msgid ""
12394 "A file may be subsequently reopened, by the same or another program "
12395 "execution, and its contents reclaimed or modified (if it can be repositioned "
12396 "at the start).  If the main function returns to its original caller, or the "
12397 "B<exit>(3)  function is called, all open files are closed (hence all output "
12398 "streams are flushed) before program termination.  Other methods of program "
12399 "termination, such as B<abort>(3)  do not bother about closing files properly."
12400 msgstr ""
12401 "ファイルはその後 (同じまたは別のプログラムによって)  再びオープンされることも"
12402 "あり、 その内容が修正されたり変更されたりする (そのファイルで先頭への位置移動"
12403 "が可能であれば)。 main 関数がもとの呼び出し側に返ったり、 B<exit>(3)  関数が"
12404 "呼ばれた場合、 プログラムの終了の前に 現在開いているすべてのファイルは閉じら"
12405 "れる (その結果、すべての出力ストリームはフラッシュされる)。 プログラムの停止"
12406 "に B<abort>(3)  のような他の方法を用いた場合には、 ファイルが正しく閉じられる"
12407 "保証はない。"
12408
12409 #. type: Plain text
12410 #: build/C/man3/stdio.3:119
12411 msgid ""
12412 "At program startup, three text streams are predefined and need not be opened "
12413 "explicitly: I<standard input> (for reading conventional input), I<standard "
12414 "output> (for writing conventional input), and I<standard error> (for writing "
12415 "diagnostic output).  These streams are abbreviated I<stdin>,I<stdout> and "
12416 "I<stderr>.  When opened, the standard error stream is not fully buffered; "
12417 "the standard input and output streams are fully buffered if and only if the "
12418 "streams do not refer to an interactive device."
12419 msgstr ""
12420 "プログラムの起動時に 3 個のテキストストリームが予め定義されており、 それらは"
12421 "明示的に開く必要がない。 I<標準入力 (standard input)> (通常の入力を読み取るの"
12422 "に使う)、 I<標準出力 (standard output)> (通常の出力を書き込むのに使う)、 I<標"
12423 "準エラー出力 (standard error)> (診断出力を書き込むのに使う) である。 これらの"
12424 "ストリームは I<stdin>, I<stdout>, I<stderr> と短縮して表現される。 オープンさ"
12425 "れたときには、 標準エラーストリームは 完全にはバッファリングされていない。 標"
12426 "準入力ストリームと標準出力ストリームは、 ストリームがインタラクティブなデバイ"
12427 "スを参照していなければ、 完全にバッファリングされている。"
12428
12429 #. type: Plain text
12430 #: build/C/man3/stdio.3:129
12431 msgid ""
12432 "Output streams that refer to terminal devices are always line buffered by "
12433 "default; pending output to such streams is written automatically whenever an "
12434 "input stream that refers to a terminal device is read.  In cases where a "
12435 "large amount of computation is done after printing part of a line on an "
12436 "output terminal, it is necessary to B<fflush>(3)  the standard output before "
12437 "going off and computing so that the output will appear."
12438 msgstr ""
12439 "端末デバイスを参照する出力ストリームは、 デフォルトでは常に行単位でバッファリ"
12440 "ングされている。 ただしそのようなストリームにおけるバッファ内の出力は、 端末"
12441 "デバイスを参照している入力ストリームからの読み込みがあるたびに、 自動的に書き"
12442 "込まれる。 出力端末に行の一部を書き込んだ後で大量の計算を行う場合、 出力が表"
12443 "示されるように、計算に取りかかる前に標準出力に対して B<fflush>(3)  を実行する"
12444 "必要がある。"
12445
12446 #. type: Plain text
12447 #: build/C/man3/stdio.3:143
12448 msgid ""
12449 "The I<stdio> library is a part of the library B<libc> and routines are "
12450 "automatically loaded as needed by the compilers B<cc>(1)  and B<pc>(1).  The "
12451 "SYNOPSIS sections of the following manual pages indicate which include files "
12452 "are to be used, what the compiler declaration for the function looks like "
12453 "and which external variables are of interest."
12454 msgstr ""
12455 "I<stdio> ライブラリは B<libc> ライブラリの一部であり、ルーチンは コンパイ"
12456 "ラー B<cc>(1)  と B<pc>(1)  によって必要な時に自動的に読み込まれる。 後述す"
12457 "る man ページ中の「書式」の節には、 どのインクルードファイルを使用しなければ"
12458 "ならないか、 その関数のコンパイラー宣言はどのようなものか、 どのような外部変"
12459 "数が関係するのかが示されている。"
12460
12461 #.  Not on Linux: .BR fropen ,
12462 #.  Not on Linux: .BR fwopen ,
12463 #. type: Plain text
12464 #: build/C/man3/stdio.3:183
12465 msgid ""
12466 "The following are defined as macros; these names may not be reused without "
12467 "first removing their current definitions with B<#undef>: B<BUFSIZ>, B<EOF>, "
12468 "B<FILENAME_MAX>, B<FOPEN_MAX>, B<L_cuserid>, B<L_ctermid>, B<L_tmpnam>, "
12469 "B<NULL>, B<SEEK_END>, B<SEEK_SET>, B<SEEK_CUR>, B<TMP_MAX>, B<clearerr>, "
12470 "B<feof>, B<ferror>, B<fileno>, B<getc>, B<getchar>, B<putc>, B<putchar>, "
12471 "B<stderr>, B<stdin>, B<stdout>.  Function versions of the macro functions "
12472 "B<feof>, B<ferror>, B<clearerr>, B<fileno>, B<getc>, B<getchar>, B<putc>, "
12473 "and B<putchar> exist and will be used if the macros definitions are "
12474 "explicitly removed."
12475 msgstr ""
12476 "B<BUFSIZ>, B<EOF>, B<FILENAME_MAX>, B<FOPEN_MAX>, B<L_cuserid>, "
12477 "B<L_ctermid>, B<L_tmpnam>, B<NULL>, B<SEEK_END>, B<SEEK_SET>, B<SEEK_CUR>, "
12478 "B<TMP_MAX>, B<clearerr>, B<feof>, B<ferror>, B<fileno>, B<getc>, B<getchar>, "
12479 "B<putc>, B<putchar>, B<stderr>, B<stdin>, B<stdout> はマクロとして定義されて"
12480 "いる。 これらの名前は、現在の定義を B<#undef> で削除しない限り、再利用するこ"
12481 "とはできない。 マクロ関数の関数版として、 B<feof>, B<ferror>, B<clearerr>, "
12482 "B<fileno>, B<getc>, B<getchar>, B<putc>, B<putchar> がある。 マクロの定義が明"
12483 "示的に消去されている場合には、 これらを使用することになるだろう。"
12484
12485 #. type: SS
12486 #: build/C/man3/stdio.3:183
12487 #, no-wrap
12488 msgid "List of functions"
12489 msgstr "関数のリスト"
12490
12491 #. type: tbl table
12492 #: build/C/man3/stdio.3:188
12493 #, no-wrap
12494 msgid "Function\tDescription\n"
12495 msgstr "関数\t説明\n"
12496
12497 #. type: tbl table
12498 #: build/C/man3/stdio.3:189
12499 #, no-wrap
12500 msgid "_\n"
12501 msgstr "_\n"
12502
12503 #. type: tbl table
12504 #: build/C/man3/stdio.3:190
12505 #, no-wrap
12506 msgid "clearerr\tcheck and reset stream status\n"
12507 msgstr "clearerr\tストリームの状態の確認とリセット\n"
12508
12509 #. type: tbl table
12510 #: build/C/man3/stdio.3:191
12511 #, no-wrap
12512 msgid "fclose\tclose a stream\n"
12513 msgstr "fclose\tストリームをクローズする\n"
12514
12515 #. type: tbl table
12516 #: build/C/man3/stdio.3:192
12517 #, no-wrap
12518 msgid "fdopen\tstream open functions\n"
12519 msgstr "fdopen\tストリームをオープンする\n"
12520
12521 #. type: tbl table
12522 #: build/C/man3/stdio.3:193
12523 #, no-wrap
12524 msgid "feof\tcheck and reset stream status\n"
12525 msgstr "feof\tストリームの状態の確認とリセット\n"
12526
12527 #. type: tbl table
12528 #: build/C/man3/stdio.3:194
12529 #, no-wrap
12530 msgid "ferror\tcheck and reset stream status\n"
12531 msgstr "ferror\tストリームの状態の確認とリセット\n"
12532
12533 #. type: tbl table
12534 #: build/C/man3/stdio.3:195
12535 #, no-wrap
12536 msgid "fflush\tflush a stream\n"
12537 msgstr "fflush\tストリームをフラッシュする\n"
12538
12539 #. type: tbl table
12540 #: build/C/man3/stdio.3:196
12541 #, no-wrap
12542 msgid "fgetc\tget next character or word from input stream\n"
12543 msgstr "fgetc\t次の文字または語を入力ストリームから獲得する\n"
12544
12545 #. type: tbl table
12546 #: build/C/man3/stdio.3:197
12547 #, no-wrap
12548 msgid "fgetpos\treposition a stream\n"
12549 msgstr "fgetpos\tストリームの位置を取得する\n"
12550
12551 #. type: tbl table
12552 #: build/C/man3/stdio.3:198
12553 #, no-wrap
12554 msgid "fgets\tget a line from a stream\n"
12555 msgstr "fgets\tストリームから行を取得する\n"
12556
12557 #. type: tbl table
12558 #: build/C/man3/stdio.3:199
12559 #, no-wrap
12560 msgid "fileno\treturn the integer descriptor of the argument stream\n"
12561 msgstr "fileno\t引き数であるストリームの整数値のディスクリプタを返す\n"
12562
12563 #. type: tbl table
12564 #: build/C/man3/stdio.3:200
12565 #, no-wrap
12566 msgid "fopen\tstream open functions\n"
12567 msgstr "fopen\tストリームをオープンする\n"
12568
12569 #. type: tbl table
12570 #: build/C/man3/stdio.3:201
12571 #, no-wrap
12572 msgid "fprintf\tformatted output conversion\n"
12573 msgstr "fprintf\t書式付き出力変換\n"
12574
12575 #. type: tbl table
12576 #: build/C/man3/stdio.3:202
12577 #, no-wrap
12578 msgid "fpurge\tflush a stream\n"
12579 msgstr "fpurge\tストリームをフラッシュする\n"
12580
12581 #. type: tbl table
12582 #: build/C/man3/stdio.3:203
12583 #, no-wrap
12584 msgid "fputc\toutput a character or word to a stream\n"
12585 msgstr "fputc\t文字または語をストリームに出力する\n"
12586
12587 #. type: tbl table
12588 #: build/C/man3/stdio.3:204
12589 #, no-wrap
12590 msgid "fputs\toutput a line to a stream\n"
12591 msgstr "fputs\t行をストリームに出力する\n"
12592
12593 #. type: tbl table
12594 #: build/C/man3/stdio.3:205
12595 #, no-wrap
12596 msgid "fread\tbinary stream input/output\n"
12597 msgstr "fread\tバイナリーストリーム入出力\n"
12598
12599 #. type: tbl table
12600 #: build/C/man3/stdio.3:206
12601 #, no-wrap
12602 msgid "freopen\tstream open functions\n"
12603 msgstr "freopen\tストリームをオープンする\n"
12604
12605 #. type: tbl table
12606 #: build/C/man3/stdio.3:207
12607 #, no-wrap
12608 msgid "fscanf\tinput format conversion\n"
12609 msgstr "fscanf\t書式付き入力変換\n"
12610
12611 #. type: tbl table
12612 #: build/C/man3/stdio.3:208
12613 #, no-wrap
12614 msgid "fseek\treposition a stream\n"
12615 msgstr "fseek\tストリームの位置指示子を移動する\n"
12616
12617 #. type: tbl table
12618 #: build/C/man3/stdio.3:209
12619 #, no-wrap
12620 msgid "fsetpos\treposition a stream\n"
12621 msgstr "fsetpos\tストリームの位置指示子を移動する\n"
12622
12623 #. type: tbl table
12624 #: build/C/man3/stdio.3:210
12625 #, no-wrap
12626 msgid "ftell\treposition a stream\n"
12627 msgstr "ftell\tストリームの位置を取得する\n"
12628
12629 #. type: tbl table
12630 #: build/C/man3/stdio.3:211
12631 #, no-wrap
12632 msgid "fwrite\tbinary stream input/output\n"
12633 msgstr "fwrite\tバイナリーストリーム入出力\n"
12634
12635 #. type: tbl table
12636 #: build/C/man3/stdio.3:212
12637 #, no-wrap
12638 msgid "getc\tget next character or word from input stream\n"
12639 msgstr "getc\t次の文字または語を入力ストリームから取得する\n"
12640
12641 #. type: tbl table
12642 #: build/C/man3/stdio.3:213
12643 #, no-wrap
12644 msgid "getchar\tget next character or word from input stream\n"
12645 msgstr "getchar\t次の文字または語を入力ストリームから取得する\n"
12646
12647 #. type: tbl table
12648 #: build/C/man3/stdio.3:214
12649 #, no-wrap
12650 msgid "gets\tget a line from a stream\n"
12651 msgstr "gets\t行を入力ストリームから取得する\n"
12652
12653 #. type: tbl table
12654 #: build/C/man3/stdio.3:215
12655 #, no-wrap
12656 msgid "getw\tget next character or word from input stream\n"
12657 msgstr "getw\t次の文字または語を入力ストリームから取得する\n"
12658
12659 #. type: tbl table
12660 #: build/C/man3/stdio.3:216
12661 #, no-wrap
12662 msgid "mktemp\tmake temporary filename (unique)\n"
12663 msgstr "mktemp\t他と重ならないテンポラリファイル名を作る\n"
12664
12665 #. type: tbl table
12666 #: build/C/man3/stdio.3:217
12667 #, no-wrap
12668 msgid "perror\tsystem error messages\n"
12669 msgstr "perror\tシステムエラーメッセージ\n"
12670
12671 #. type: tbl table
12672 #: build/C/man3/stdio.3:218
12673 #, no-wrap
12674 msgid "printf\tformatted output conversion\n"
12675 msgstr "printf\t書式付き出力変換\n"
12676
12677 #. type: tbl table
12678 #: build/C/man3/stdio.3:219
12679 #, no-wrap
12680 msgid "putc\toutput a character or word to a stream\n"
12681 msgstr "putc\t文字または語をストリームに出力する\n"
12682
12683 #. type: tbl table
12684 #: build/C/man3/stdio.3:220
12685 #, no-wrap
12686 msgid "putchar\toutput a character or word to a stream\n"
12687 msgstr "putchar\t文字または語をストリームに出力する\n"
12688
12689 #. type: tbl table
12690 #: build/C/man3/stdio.3:221
12691 #, no-wrap
12692 msgid "puts\toutput a line to a stream\n"
12693 msgstr "puts\t行をストリームに出力する\n"
12694
12695 #. type: tbl table
12696 #: build/C/man3/stdio.3:222
12697 #, no-wrap
12698 msgid "putw\toutput a character or word to a stream\n"
12699 msgstr "putw\t文字または語をストリームに出力する\n"
12700
12701 #. type: tbl table
12702 #: build/C/man3/stdio.3:223
12703 #, no-wrap
12704 msgid "remove\tremove directory entry\n"
12705 msgstr "remove\tディレクトリエントリを削除する\n"
12706
12707 #. type: tbl table
12708 #: build/C/man3/stdio.3:224
12709 #, no-wrap
12710 msgid "rewind\treposition a stream\n"
12711 msgstr "rewind\tストリームの位置指示子を移動する\n"
12712
12713 #. type: tbl table
12714 #: build/C/man3/stdio.3:225
12715 #, no-wrap
12716 msgid "scanf\tinput format conversion\n"
12717 msgstr "scanf\t書式付き入力変換\n"
12718
12719 #. type: tbl table
12720 #: build/C/man3/stdio.3:226
12721 #, no-wrap
12722 msgid "setbuf\tstream buffering operations\n"
12723 msgstr "setbuf\tストリームのバッファリングの操作\n"
12724
12725 #. type: tbl table
12726 #: build/C/man3/stdio.3:227
12727 #, no-wrap
12728 msgid "setbuffer\tstream buffering operations\n"
12729 msgstr "setbuffer\tストリームのバッファリングの操作\n"
12730
12731 #. type: tbl table
12732 #: build/C/man3/stdio.3:228
12733 #, no-wrap
12734 msgid "setlinebuf\tstream buffering operations\n"
12735 msgstr "setlinebuf\tストリームのバッファリングの操作\n"
12736
12737 #. type: tbl table
12738 #: build/C/man3/stdio.3:229
12739 #, no-wrap
12740 msgid "setvbuf\tstream buffering operations\n"
12741 msgstr "setvbuf\tストリームのバッファリングの操作\n"
12742
12743 #. type: tbl table
12744 #: build/C/man3/stdio.3:230
12745 #, no-wrap
12746 msgid "sprintf\tformatted output conversion\n"
12747 msgstr "sprintf\t書式付き出力変換\n"
12748
12749 #. type: tbl table
12750 #: build/C/man3/stdio.3:231
12751 #, no-wrap
12752 msgid "sscanf\tinput format conversion\n"
12753 msgstr "sscanf\t書式付き入力変換\n"
12754
12755 #. type: tbl table
12756 #: build/C/man3/stdio.3:232
12757 #, no-wrap
12758 msgid "strerror\tsystem error messages\n"
12759 msgstr "strerror\tシステムエラーメッセージ\n"
12760
12761 #. type: tbl table
12762 #: build/C/man3/stdio.3:233
12763 #, no-wrap
12764 msgid "sys_errlist\tsystem error messages\n"
12765 msgstr "sys_errlist\tシステムエラーメッセージ\n"
12766
12767 #. type: tbl table
12768 #: build/C/man3/stdio.3:234
12769 #, no-wrap
12770 msgid "sys_nerr\tsystem error messages\n"
12771 msgstr "sys_nerr\tシステムエラーメッセージ\n"
12772
12773 #. type: tbl table
12774 #: build/C/man3/stdio.3:235
12775 #, no-wrap
12776 msgid "tempnam\ttemporary file routines\n"
12777 msgstr "tempnam\tテンポラリファイルの操作\n"
12778
12779 #. type: tbl table
12780 #: build/C/man3/stdio.3:236
12781 #, no-wrap
12782 msgid "tmpfile\ttemporary file routines\n"
12783 msgstr "tmpfile\tテンポラリファイルの操作\n"
12784
12785 #. type: tbl table
12786 #: build/C/man3/stdio.3:237
12787 #, no-wrap
12788 msgid "tmpnam\ttemporary file routines\n"
12789 msgstr "tmpnam\tテンポラリファイルの操作\n"
12790
12791 #. type: tbl table
12792 #: build/C/man3/stdio.3:238
12793 #, no-wrap
12794 msgid "ungetc\tun-get character from input stream\n"
12795 msgstr "ungetc\t入力ストリームへ 1 文字戻す。\n"
12796
12797 #. type: tbl table
12798 #: build/C/man3/stdio.3:239
12799 #, no-wrap
12800 msgid "vfprintf\tformatted output conversion\n"
12801 msgstr "vfprintf\t書式付き出力変換\n"
12802
12803 #. type: tbl table
12804 #: build/C/man3/stdio.3:240
12805 #, no-wrap
12806 msgid "vfscanf\tinput format conversion\n"
12807 msgstr "vfscanf\t書式付き入力変換\n"
12808
12809 #. type: tbl table
12810 #: build/C/man3/stdio.3:241
12811 #, no-wrap
12812 msgid "vprintf\tformatted output conversion\n"
12813 msgstr "vprintf\t書式付き出力変換\n"
12814
12815 #. type: tbl table
12816 #: build/C/man3/stdio.3:242
12817 #, no-wrap
12818 msgid "vscanf\tinput format conversion\n"
12819 msgstr "vscanf\t書式付き入力変換\n"
12820
12821 #. type: tbl table
12822 #: build/C/man3/stdio.3:243
12823 #, no-wrap
12824 msgid "vsprintf\tformatted output conversion\n"
12825 msgstr "vsprintf\t書式付き出力変換\n"
12826
12827 #. type: tbl table
12828 #: build/C/man3/stdio.3:244
12829 #, no-wrap
12830 msgid "vsscanf\tinput format conversion\n"
12831 msgstr "vsscanf\t書式付き入力変換\n"
12832
12833 #. type: Plain text
12834 #: build/C/man3/stdio.3:250
12835 msgid "The I<stdio> library conforms to C89."
12836 msgstr "I<stdio> ライブラリは C89 に準拠している。"
12837
12838 #. type: Plain text
12839 #: build/C/man3/stdio.3:257
12840 msgid ""
12841 "B<close>(2), B<open>(2), B<read>(2), B<write>(2), B<stdout>(3), "
12842 "B<unlocked_stdio>(3)"
12843 msgstr ""
12844 "B<close>(2), B<open>(2), B<read>(2), B<write>(2), B<stdout>(3), "
12845 "B<unlocked_stdio>(3)"
12846
12847 #. type: TH
12848 #: build/C/man3/stdio_ext.3:25
12849 #, no-wrap
12850 msgid "STDIO_EXT"
12851 msgstr "STDIO_EXT"
12852
12853 #. type: TH
12854 #: build/C/man3/stdio_ext.3:25
12855 #, no-wrap
12856 msgid "2001-12-16"
12857 msgstr "2001-12-16"
12858
12859 #. type: Plain text
12860 #: build/C/man3/stdio_ext.3:30
12861 msgid ""
12862 "__fbufsize, __flbf, __fpending, __fpurge, __freadable, __freading, "
12863 "__fsetlocking, __fwritable, __fwriting, _flushlbf - interfaces to stdio FILE "
12864 "structure"
12865 msgstr ""
12866 "__fbufsize, __flbf, __fpending, __fpurge, __freadable, __freading, "
12867 "__fsetlocking, __fwritable, __fwriting, _flushlbf - 標準入出力ファイル構造体"
12868 "へのインタフェース"
12869
12870 #. type: Plain text
12871 #: build/C/man3/stdio_ext.3:34
12872 msgid "B<#include E<lt>stdio_ext.hE<gt>>"
12873 msgstr "B<#include E<lt>stdio_ext.hE<gt>>"
12874
12875 #. type: Plain text
12876 #: build/C/man3/stdio_ext.3:36
12877 msgid "B<size_t __fbufsize(FILE *>I<stream>B<);>"
12878 msgstr "B<size_t __fbufsize(FILE *>I<stream>B<);>"
12879
12880 #. type: Plain text
12881 #: build/C/man3/stdio_ext.3:38
12882 msgid "B<size_t __fpending(FILE *>I<stream>B<);>"
12883 msgstr "B<size_t __fpending(FILE *>I<stream>B<);>"
12884
12885 #. type: Plain text
12886 #: build/C/man3/stdio_ext.3:40
12887 msgid "B<int __flbf(FILE *>I<stream>B<);>"
12888 msgstr "B<int __flbf(FILE *>I<stream>B<);>"
12889
12890 #. type: Plain text
12891 #: build/C/man3/stdio_ext.3:42
12892 msgid "B<int __freadable(FILE *>I<stream>B<);>"
12893 msgstr "B<int __freadable(FILE *>I<stream>B<);>"
12894
12895 #. type: Plain text
12896 #: build/C/man3/stdio_ext.3:44
12897 msgid "B<int __fwritable(FILE *>I<stream>B<);>"
12898 msgstr "B<int __fwritable(FILE *>I<stream>B<);>"
12899
12900 #. type: Plain text
12901 #: build/C/man3/stdio_ext.3:46
12902 msgid "B<int __freading(FILE *>I<stream>B<);>"
12903 msgstr "B<int __freading(FILE *>I<stream>B<);>"
12904
12905 #. type: Plain text
12906 #: build/C/man3/stdio_ext.3:48
12907 msgid "B<int __fwriting(FILE *>I<stream>B<);>"
12908 msgstr "B<int __fwriting(FILE *>I<stream>B<);>"
12909
12910 #. type: Plain text
12911 #: build/C/man3/stdio_ext.3:50
12912 msgid "B<int __fsetlocking(FILE *>I<stream>B<, int >I<type>B<);>"
12913 msgstr "B<int __fsetlocking(FILE *>I<stream>B<, int >I<type>B<);>"
12914
12915 #. type: Plain text
12916 #: build/C/man3/stdio_ext.3:52
12917 msgid "B<void _flushlbf(void);>"
12918 msgstr "B<void _flushlbf(void);>"
12919
12920 #. type: Plain text
12921 #: build/C/man3/stdio_ext.3:54
12922 msgid "B<void __fpurge(FILE *>I<stream>B<);>"
12923 msgstr "B<void __fpurge(FILE *>I<stream>B<);>"
12924
12925 #. type: Plain text
12926 #: build/C/man3/stdio_ext.3:59
12927 msgid ""
12928 "Solaris introduced routines to allow portable access to the internals of the "
12929 "I<FILE> structure, and glibc also implemented these."
12930 msgstr ""
12931 "Solaris では、 I<FILE> 構造体の内部へポータブルなかたちで アクセスできる手段"
12932 "が導入されており、これらは glibc でも実装されている。"
12933
12934 #. type: Plain text
12935 #: build/C/man3/stdio_ext.3:64
12936 msgid ""
12937 "The B<__fbufsize>()  function returns the size of the buffer currently used "
12938 "by the given stream."
12939 msgstr ""
12940 "B<__fbufsize>()  関数は、指定されたストリームが使用しているバッファサイズを返"
12941 "す。"
12942
12943 #. type: Plain text
12944 #: build/C/man3/stdio_ext.3:71
12945 msgid ""
12946 "The B<__fpending>()  function returns the number of bytes in the output "
12947 "buffer.  For wide-oriented streams the unit is wide characters.  This "
12948 "function is undefined on buffers in reading mode, or opened read-only."
12949 msgstr ""
12950 "B<__fpending>()  関数は、出力バッファに入っているデータのバイト数を返す。 ワ"
12951 "イドキャラクタを扱うストリームの場合、ワイドキャラクタ単位で計算される。 バッ"
12952 "ファが読み出しモードの場合や読み出し専用で開かれている場合の この関数の振舞い"
12953 "は未定義である。"
12954
12955 #. type: Plain text
12956 #: build/C/man3/stdio_ext.3:76
12957 msgid ""
12958 "The B<__flbf>()  function returns a nonzero value if the stream is line-"
12959 "buffered, and zero otherwise."
12960 msgstr ""
12961 "B<__flbf>()  関数は、ストリームがラインバッファの場合は 0 以外を、 それ以外の"
12962 "場合は 0 を返す。"
12963
12964 #. type: Plain text
12965 #: build/C/man3/stdio_ext.3:81
12966 msgid ""
12967 "The B<__freadable>()  function returns a nonzero value if the stream allows "
12968 "reading, and zero otherwise."
12969 msgstr ""
12970 "B<__freadable>()  関数は、ストリームが読み出し可能な場合は 0 以外を、 それ以"
12971 "外の場合は 0 を返す。"
12972
12973 #. type: Plain text
12974 #: build/C/man3/stdio_ext.3:86
12975 msgid ""
12976 "The B<__fwritable>()  function returns a nonzero value if the stream allows "
12977 "writing, and zero otherwise."
12978 msgstr ""
12979 "B<__fwritable>()  関数は、ストリームが書き込み可能な場合は 0 以外を、 それ以"
12980 "外の場合は 0 を返す。"
12981
12982 #. type: Plain text
12983 #: build/C/man3/stdio_ext.3:92
12984 msgid ""
12985 "The B<__freading>()  function returns a nonzero value if the stream is read-"
12986 "only, or if the last operation on the stream was a read operation, and zero "
12987 "otherwise."
12988 msgstr ""
12989 "B<__freading>()  関数は、ストリームが読み出し専用の場合、またはストリームに対"
12990 "する直前の操作が 読み出し操作であった場合は 0 以外を返し、それ以外の場合は 0 "
12991 "を返す。"
12992
12993 #. type: Plain text
12994 #: build/C/man3/stdio_ext.3:98
12995 msgid ""
12996 "The B<__fwriting>()  function returns a nonzero value if the stream is write-"
12997 "only (or append-only), or if the last operation on the stream was a write "
12998 "operation, and zero otherwise."
12999 msgstr ""
13000 "B<__fwriting>()  関数は、ストリームが書き込み専用(もしくは追加専用)の場合、 "
13001 "またはストリームに対する直前の操作が書き込み操作であった場合は 0 以外を返"
13002 "し、 それ以外の場合は 0 を返す。"
13003
13004 #. type: Plain text
13005 #: build/C/man3/stdio_ext.3:106
13006 msgid ""
13007 "The B<__fsetlocking>()  function can be used to select the desired type of "
13008 "locking on the stream.  It returns the current type.  The I<type> argument "
13009 "can take the following three values:"
13010 msgstr ""
13011 "B<__fsetlocking>()  関数は、ストリームのロック形式を選択するために使用でき"
13012 "る。 返り値は、現在のロック形式である。 I<type> 引き数は以下の 3 種類の値をと"
13013 "ることができる :"
13014
13015 #. type: TP
13016 #: build/C/man3/stdio_ext.3:106
13017 #, no-wrap
13018 msgid "B<FSETLOCKING_INTERNAL>"
13019 msgstr "B<FSETLOCKING_INTERNAL>"
13020
13021 #. type: Plain text
13022 #: build/C/man3/stdio_ext.3:111
13023 msgid ""
13024 "Perform implicit locking around every operation on the given stream (except "
13025 "for the *_unlocked ones).  This is the default."
13026 msgstr ""
13027 "指定されたストリームに対して操作が行われる度に、操作の前後で 明示的に指示しな"
13028 "くてもストリームのロック処理を行う (但し、*_unlocked 関数を使用した場合は例外"
13029 "である)。 これがデフォルトのロック形式である。"
13030
13031 #. type: TP
13032 #: build/C/man3/stdio_ext.3:111
13033 #, no-wrap
13034 msgid "B<FSETLOCKING_BYCALLER>"
13035 msgstr "B<FSETLOCKING_BYCALLER>"
13036
13037 #. type: Plain text
13038 #: build/C/man3/stdio_ext.3:118
13039 msgid ""
13040 "The caller will take care of the locking (possibly using B<flockfile>(3)  in "
13041 "case there is more than one thread), and the stdio routines will not do "
13042 "locking until the state is reset to B<FSETLOCKING_INTERNAL>."
13043 msgstr ""
13044 "関数の呼び出し元でロックの面倒をみる。 (おそらく、複数のスレッドが存在する状"
13045 "況では B<flockfile>(3)  を使うことになるだろう)  ロック形式が "
13046 "B<FSETLOCKING_INTERNAL> にリセットされるまでは標準入出力関連の関数はロック処"
13047 "理を行わない。"
13048
13049 #. type: TP
13050 #: build/C/man3/stdio_ext.3:118
13051 #, no-wrap
13052 msgid "B<FSETLOCKING_QUERY>"
13053 msgstr "B<FSETLOCKING_QUERY>"
13054
13055 #. type: Plain text
13056 #: build/C/man3/stdio_ext.3:122
13057 msgid "Don't change the type of locking.  (Only return it.)"
13058 msgstr "ロック形式の変更を行わない。(現在の形式を返すだけである)"
13059
13060 #. type: Plain text
13061 #: build/C/man3/stdio_ext.3:128
13062 msgid ""
13063 "The B<_flushlbf>()  function flushes all line-buffered streams.  (Presumably "
13064 "so that output to a terminal is forced out, say before reading keyboard "
13065 "input.)"
13066 msgstr ""
13067 "B<_flushlbf>()  関数は、すべてのラインバッファ (line-buffered) タイプのスト"
13068 "リームの 内容を出力(フラッシュ)する。 (当然ながら、端末への出力が強制的に行わ"
13069 "れることになるので、 キーボードからの入力を読みこむ前にこの関数を呼んだ方がい"
13070 "いだろう)"
13071
13072 #. type: Plain text
13073 #: build/C/man3/stdio_ext.3:132
13074 msgid ""
13075 "The B<__fpurge>()  function discards the contents of the stream's buffer."
13076 msgstr "B<__fpurge>()  関数は、ストリームのバッファの内容を廃棄する。"
13077
13078 #. type: Plain text
13079 #: build/C/man3/stdio_ext.3:135
13080 msgid "B<flockfile>(3), B<fpurge>(3)"
13081 msgstr "B<flockfile>(3), B<fpurge>(3)"
13082
13083 #. type: TH
13084 #: build/C/man2/symlink.2:32 build/C/man7/symlink.7:36
13085 #, no-wrap
13086 msgid "SYMLINK"
13087 msgstr "SYMLINK"
13088
13089 #. type: Plain text
13090 #: build/C/man2/symlink.2:35
13091 msgid "symlink - make a new name for a file"
13092 msgstr "symlink - ファイルに新しい名前を付ける"
13093
13094 #. type: Plain text
13095 #: build/C/man2/symlink.2:39
13096 msgid "B<int symlink(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
13097 msgstr "B<int symlink(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
13098
13099 #. type: Plain text
13100 #: build/C/man2/symlink.2:47
13101 msgid "B<symlink>():"
13102 msgstr "B<symlink>():"
13103
13104 #. type: Plain text
13105 #: build/C/man2/symlink.2:58
13106 msgid ""
13107 "B<symlink>()  creates a symbolic link named I<newpath> which contains the "
13108 "string I<oldpath>."
13109 msgstr ""
13110 "B<symlink>()  は I<oldpath> という文字列をファイルの内容として持つ "
13111 "I<newpath> というシンボリックリンク (symbolic link) を作成する。"
13112
13113 #. type: Plain text
13114 #: build/C/man2/symlink.2:62
13115 msgid ""
13116 "Symbolic links are interpreted at run time as if the contents of the link "
13117 "had been substituted into the path being followed to find a file or "
13118 "directory."
13119 msgstr ""
13120 "シンボリックリンクは実行時に解釈され、 リンクの内容でパスを置き換えて、そのパ"
13121 "スを辿ることで、 ファイルやディレクトリに到達する。"
13122
13123 #. type: Plain text
13124 #: build/C/man2/symlink.2:67
13125 msgid ""
13126 "Symbolic links may contain I<..> path components, which (if used at the "
13127 "start of the link) refer to the parent directories of that in which the link "
13128 "resides."
13129 msgstr ""
13130 "シンボリックリンクはパスの部分に I<..> を含むかもしれない。これは (もしリンク"
13131 "の最初に使用された場合は) リンクの 存在するディレクトリの親ディレクトリが参照"
13132 "される。"
13133
13134 #. type: Plain text
13135 #: build/C/man2/symlink.2:71
13136 msgid ""
13137 "A symbolic link (also known as a soft link) may point to an existing file or "
13138 "to a nonexistent one; the latter case is known as a dangling link."
13139 msgstr ""
13140 "シンボリックリンクは (ソフトリンク (soft link) とも呼ばれ)  存在するファイル"
13141 "を指しているかもしれないし、 存在しないファイルを指しているかもしれない; 後者"
13142 "の場合は壊れたリンク (dangling link) とも呼ばれる。"
13143
13144 #. type: Plain text
13145 #: build/C/man2/symlink.2:78
13146 msgid ""
13147 "The permissions of a symbolic link are irrelevant; the ownership is ignored "
13148 "when following the link, but is checked when removal or renaming of the link "
13149 "is requested and the link is in a directory with the sticky bit "
13150 "(B<S_ISVTX>)  set."
13151 msgstr ""
13152 "シンボリックリンクの許可 (permission) は無意味である; リンクを追跡する場合に"
13153 "は所有権 (ownership) は無視される。 ただし、リンクの削除や名前の変更が要求さ"
13154 "れ、かつリンクが存在する ディレクトリにスティッキービット (sticky bit)  "
13155 "(B<S_ISVTX>)  が設定されている場合には、所有権のチェックが行われる。"
13156
13157 #. type: Plain text
13158 #: build/C/man2/symlink.2:99
13159 msgid ""
13160 "Write access to the directory containing I<newpath> is denied, or one of the "
13161 "directories in the path prefix of I<newpath> did not allow search "
13162 "permission.  (See also B<path_resolution>(7).)"
13163 msgstr ""
13164 "I<newpath> を含んでいるディレクトリへの書き込みが拒否されたか、 I<newpath> に"
13165 "含まれているディレクトリのどれかに検索許可が与えられていない "
13166 "(B<path_resolution>(7)  も参照すること)。"
13167
13168 #. type: Plain text
13169 #: build/C/man2/symlink.2:104
13170 msgid ""
13171 "The user's quota of resources on the file system has been exhausted.  The "
13172 "resources could be inodes or disk blocks, depending on the file system "
13173 "implementation."
13174 msgstr ""
13175
13176 #. type: Plain text
13177 #: build/C/man2/symlink.2:118
13178 msgid "Too many symbolic links were encountered in resolving I<newpath>."
13179 msgstr "I<newpath> を解決する際に遭遇したシンボリックリンクが多過ぎる。"
13180
13181 #. type: Plain text
13182 #: build/C/man2/symlink.2:128
13183 msgid ""
13184 "A directory component in I<newpath> does not exist or is a dangling symbolic "
13185 "link, or I<oldpath> is the empty string."
13186 msgstr ""
13187 "I<newpath> に含まれるディレクトリ部分が存在しないか、壊れたリンクであるか、 "
13188 "I<oldpath> が空文字列である。"
13189
13190 #. type: Plain text
13191 #: build/C/man2/symlink.2:140
13192 msgid ""
13193 "A component used as a directory in I<newpath> is not, in fact, a directory."
13194 msgstr ""
13195 "I<newpath> に含まれるディレクトリ部分が、実際には、ディレクトリではない。"
13196
13197 #. type: Plain text
13198 #: build/C/man2/symlink.2:145
13199 msgid ""
13200 "The file system containing I<newpath> does not support the creation of "
13201 "symbolic links."
13202 msgstr ""
13203 "I<newpath> を含んでいるファイルシステム (file system) が シンボリックリンクの"
13204 "作成をサポートしていない。"
13205
13206 #. type: Plain text
13207 #: build/C/man2/symlink.2:149
13208 msgid "I<newpath> is on a read-only file system."
13209 msgstr "I<newpath> が読み込み専用のファイルシステムに存在している。"
13210
13211 #. type: Plain text
13212 #: build/C/man2/symlink.2:159
13213 msgid "No checking of I<oldpath> is done."
13214 msgstr "I<oldpath> についてのチェックは行なわれない。"
13215
13216 #. type: Plain text
13217 #: build/C/man2/symlink.2:164
13218 msgid ""
13219 "Deleting the name referred to by a symlink will actually delete the file "
13220 "(unless it also has other hard links).  If this behavior is not desired, use "
13221 "B<link>(2)."
13222 msgstr ""
13223 "symlink によって参照される名前を削除すると (それが他にハードリンク (hard "
13224 "link) を持たなければ) 実際にファイルが削除される。 この動作が望んだものでない"
13225 "場合は、 B<link>(2)  を使用すること。"
13226
13227 #. type: Plain text
13228 #: build/C/man2/symlink.2:176
13229 msgid ""
13230 "B<ln>(1), B<lchown>(2), B<link>(2), B<lstat>(2), B<open>(2), B<readlink>(2), "
13231 "B<rename>(2), B<symlinkat>(2), B<unlink>(2), B<path_resolution>(7), "
13232 "B<symlink>(7)"
13233 msgstr ""
13234 "B<ln>(1), B<lchown>(2), B<link>(2), B<lstat>(2), B<open>(2), B<readlink>(2), "
13235 "B<rename>(2), B<symlinkat>(2), B<unlink>(2), B<path_resolution>(7), "
13236 "B<symlink>(7)"
13237
13238 #. type: TH
13239 #: build/C/man7/symlink.7:36
13240 #, no-wrap
13241 msgid "2008-06-18"
13242 msgstr "2008-06-18"
13243
13244 #. type: Plain text
13245 #: build/C/man7/symlink.7:39
13246 msgid "symlink - symbolic link handling"
13247 msgstr ""
13248
13249 #. type: SH
13250 #: build/C/man7/symlink.7:39
13251 #, no-wrap
13252 msgid "SYMBOLIC LINK HANDLING"
13253 msgstr ""
13254
13255 #. type: Plain text
13256 #: build/C/man7/symlink.7:43
13257 msgid ""
13258 "Symbolic links are files that act as pointers to other files.  To understand "
13259 "their behavior, you must first understand how hard links work."
13260 msgstr ""
13261
13262 #. type: Plain text
13263 #: build/C/man7/symlink.7:59
13264 msgid ""
13265 "A hard link to a file is indistinguishable from the original file because it "
13266 "is a reference to the object underlying the original filename.  (To be "
13267 "precise: each of the hard links to a file is a reference to the same I<i-"
13268 "node number>, where an i-node number is an index into the i-node table, "
13269 "which contains metadata about all files on a file system.  See B<stat>(2).)  "
13270 "Changes to a file are independent of the name used to reference the file.  "
13271 "Hard links may not refer to directories (to prevent the possibility of loops "
13272 "within the file system tree, which would confuse many programs)  and may not "
13273 "refer to files on different file systems (because i-node numbers are not "
13274 "unique across file systems)."
13275 msgstr ""
13276
13277 #. type: Plain text
13278 #: build/C/man7/symlink.7:66
13279 msgid ""
13280 "A symbolic link is a special type of file whose contents are a string that "
13281 "is the pathname another file, the file to which the link refers.  In other "
13282 "words, a symbolic link is a pointer to another name, and not to an "
13283 "underlying object.  For this reason, symbolic links may refer to directories "
13284 "and may cross file system boundaries."
13285 msgstr ""
13286
13287 #. type: Plain text
13288 #: build/C/man7/symlink.7:72
13289 msgid ""
13290 "There is no requirement that the pathname referred to by a symbolic link "
13291 "should exist.  A symbolic link that refers to a pathname that does not exist "
13292 "is said to be a I<dangling link>."
13293 msgstr ""
13294
13295 #. type: Plain text
13296 #: build/C/man7/symlink.7:84
13297 msgid ""
13298 "Because a symbolic link and its referenced object coexist in the file system "
13299 "name space, confusion can arise in distinguishing between the link itself "
13300 "and the referenced object.  On historical systems, commands and system calls "
13301 "adopted their own link-following conventions in a somewhat ad-hoc fashion.  "
13302 "Rules for a more uniform approach, as they are implemented on Linux and "
13303 "other systems, are outlined here.  It is important that site-local "
13304 "applications also conform to these rules, so that the user interface can be "
13305 "as consistent as possible."
13306 msgstr ""
13307
13308 #. type: SS
13309 #: build/C/man7/symlink.7:84
13310 #, no-wrap
13311 msgid "Symbolic link ownership, permissions, and timestamps"
13312 msgstr ""
13313
13314 #. type: Plain text
13315 #: build/C/man7/symlink.7:92
13316 msgid ""
13317 "The owner and group of an existing symbolic link can be changed using "
13318 "B<lchown>(2).  The only time that the ownership of a symbolic link matters "
13319 "is when the link is being removed or renamed in a directory that has the "
13320 "sticky bit set (see B<stat>(2))."
13321 msgstr ""
13322
13323 #. type: Plain text
13324 #: build/C/man7/symlink.7:98
13325 msgid ""
13326 "The last access and last modification timestamps of a symbolic link can be "
13327 "changed using B<utimensat>(2)  or B<lutimes>(3)."
13328 msgstr ""
13329
13330 #.  Linux does not currently implement an lchmod(2).
13331 #.  The
13332 #.  4.4BSD
13333 #.  system differs from historical
13334 #.  4BSD
13335 #.  systems in that the system call
13336 #.  .BR chown (2)
13337 #.  has been changed to follow symbolic links.
13338 #.  The
13339 #.  .BR lchown (2)
13340 #.  system call was added later when the limitations of the new
13341 #.  .BR chown (2)
13342 #.  became apparent.
13343 #. type: Plain text
13344 #: build/C/man7/symlink.7:117
13345 msgid ""
13346 "On Linux, the permissions of a symbolic link are not used in any operations; "
13347 "the permissions are always 0777 (read, write, and execute for all user "
13348 "categories), and can't be changed."
13349 msgstr ""
13350
13351 #. type: SS
13352 #: build/C/man7/symlink.7:117
13353 #, no-wrap
13354 msgid "Handling of symbolic links by system calls and commands"
13355 msgstr ""
13356
13357 #. type: Plain text
13358 #: build/C/man7/symlink.7:132
13359 msgid ""
13360 "Symbolic links are handled either by operating on the link itself, or by "
13361 "operating on the object referred to by the link.  In the latter case, an "
13362 "application or system call is said to I<follow> the link.  Symbolic links "
13363 "may refer to other symbolic links, in which case the links are dereferenced "
13364 "until an object that is not a symbolic link is found, a symbolic link that "
13365 "refers to a file which does not exist is found, or a loop is detected.  "
13366 "(Loop detection is done by placing an upper limit on the number of links "
13367 "that may be followed, and an error results if this limit is exceeded.)"
13368 msgstr ""
13369
13370 #. type: Plain text
13371 #: build/C/man7/symlink.7:135
13372 msgid ""
13373 "There are three separate areas that need to be discussed.  They are as "
13374 "follows:"
13375 msgstr ""
13376
13377 #. type: IP
13378 #: build/C/man7/symlink.7:135
13379 #, no-wrap
13380 msgid "1."
13381 msgstr "1."
13382
13383 #. type: Plain text
13384 #: build/C/man7/symlink.7:137
13385 msgid "Symbolic links used as filename arguments for system calls."
13386 msgstr ""
13387
13388 #. type: IP
13389 #: build/C/man7/symlink.7:137
13390 #, no-wrap
13391 msgid "2."
13392 msgstr "2."
13393
13394 #. type: Plain text
13395 #: build/C/man7/symlink.7:140
13396 msgid ""
13397 "Symbolic links specified as command-line arguments to utilities that are not "
13398 "traversing a file tree."
13399 msgstr ""
13400
13401 #. type: IP
13402 #: build/C/man7/symlink.7:140
13403 #, no-wrap
13404 msgid "3."
13405 msgstr "3."
13406
13407 #. type: Plain text
13408 #: build/C/man7/symlink.7:144
13409 msgid ""
13410 "Symbolic links encountered by utilities that are traversing a file tree "
13411 "(either specified on the command line or encountered as part of the file "
13412 "hierarchy walk)."
13413 msgstr ""
13414
13415 #. type: SS
13416 #: build/C/man7/symlink.7:144
13417 #, no-wrap
13418 msgid "System calls"
13419 msgstr ""
13420
13421 #. type: Plain text
13422 #: build/C/man7/symlink.7:147
13423 msgid ""
13424 "The first area is symbolic links used as filename arguments for system calls."
13425 msgstr ""
13426
13427 #. type: Plain text
13428 #: build/C/man7/symlink.7:157
13429 msgid ""
13430 "Except as noted below, all system calls follow symbolic links.  For example, "
13431 "if there were a symbolic link I<slink> which pointed to a file named "
13432 "I<afile>, the system call I<open(\"slink\" ...\\&)> would return a file "
13433 "descriptor referring to the file I<afile>."
13434 msgstr ""
13435
13436 #.  Maybe one day: .BR fchownat (2)
13437 #. type: Plain text
13438 #: build/C/man7/symlink.7:207
13439 msgid ""
13440 "Various system calls do not follow links, and operate on the symbolic link "
13441 "itself.  They are: B<lchown>(2), B<lgetxattr>(2), B<llistxattr>(2), "
13442 "B<lremovexattr>(2), B<lsetxattr>(2), B<lstat>(2), B<readlink>(2), B<rename>"
13443 "(2), B<rmdir>(2), and B<unlink>(2).  Certain other system calls optionally "
13444 "follow symbolic links.  They are: B<faccessat>(2), B<fchownat>(2), B<fstatat>"
13445 "(2), B<linkat>(2), B<open>(2), B<openat>(2), and B<utimensat>(2); see their "
13446 "manual pages for details.  Because B<remove>(3)  is an alias for B<unlink>"
13447 "(2), that library function also does not follow symbolic links.  When "
13448 "B<rmdir>(2)  is applied to a symbolic link, it fails with the error "
13449 "B<ENOTDIR>.  The B<link>(2)  warrants special discussion.  POSIX.1-2001 "
13450 "specifies that B<link>(2)  should dereference I<oldpath> if it is a symbolic "
13451 "link.  However, Linux does not do this.  (By default Solaris is the same, "
13452 "but the POSIX.1-2001 specified behavior can be obtained with suitable "
13453 "compiler options.)  The upcoming POSIX.1 revision changes the specification "
13454 "to allow either behavior in an implementation."
13455 msgstr ""
13456
13457 #. type: SS
13458 #: build/C/man7/symlink.7:207
13459 #, no-wrap
13460 msgid "Commands not traversing a file tree"
13461 msgstr ""
13462
13463 #. type: Plain text
13464 #: build/C/man7/symlink.7:210
13465 msgid ""
13466 "The second area is symbolic links, specified as command-line filename "
13467 "arguments, to commands which are not traversing a file tree."
13468 msgstr ""
13469
13470 #. type: Plain text
13471 #: build/C/man7/symlink.7:221
13472 msgid ""
13473 "Except as noted below, commands follow symbolic links named as command-line "
13474 "arguments.  For example, if there were a symbolic link I<slink> which "
13475 "pointed to a file named I<afile>, the command I<cat slink> would display the "
13476 "contents of the file I<afile>."
13477 msgstr ""
13478
13479 #. type: Plain text
13480 #: build/C/man7/symlink.7:229
13481 msgid ""
13482 "It is important to realize that this rule includes commands which may "
13483 "optionally traverse file trees, e.g., the command I<chown file> is included "
13484 "in this rule, while the command I<chown\\ -R file>, which performs a tree "
13485 "traversal, is not.  (The latter is described in the third area, below.)"
13486 msgstr ""
13487
13488 #. type: Plain text
13489 #: build/C/man7/symlink.7:247
13490 msgid ""
13491 "If it is explicitly intended that the command operate on the symbolic link "
13492 "instead of following the symbolic link, e.g., it is desired that I<chown "
13493 "slink> change the ownership of the file that I<slink> is, whether it is a "
13494 "symbolic link or not, the I<-h> option should be used.  In the above "
13495 "example, I<chown root slink> would change the ownership of the file referred "
13496 "to by I<slink>, while I<chown\\ -h root slink> would change the ownership of "
13497 "I<slink> itself."
13498 msgstr ""
13499
13500 #. type: Plain text
13501 #: build/C/man7/symlink.7:249
13502 msgid "There are some exceptions to this rule:"
13503 msgstr ""
13504
13505 #. type: Plain text
13506 #: build/C/man7/symlink.7:259
13507 msgid ""
13508 "The B<mv>(1)  and B<rm>(1)  commands do not follow symbolic links named as "
13509 "arguments, but respectively attempt to rename and delete them.  (Note, if "
13510 "the symbolic link references a file via a relative path, moving it to "
13511 "another directory may very well cause it to stop working, since the path may "
13512 "no longer be correct.)"
13513 msgstr ""
13514
13515 #. type: Plain text
13516 #: build/C/man7/symlink.7:289
13517 msgid ""
13518 "The B<ls>(1)  command is also an exception to this rule.  For compatibility "
13519 "with historic systems (when B<ls>(1)  is not doing a tree walk, i.e., the I<-"
13520 "R> option is not specified), the B<ls>(1)  command follows symbolic links "
13521 "named as arguments if the I<-H> or I<-L> option is specified, or if the I<-"
13522 "F>, I<-d>, or I<-l> options are not specified.  (The B<ls>(1)  command is "
13523 "the only command where the I<-H> and I<-L> options affect its behavior even "
13524 "though it is not doing a walk of a file tree.)"
13525 msgstr ""
13526
13527 #. The 4.4BSD system differs from historical 4BSD systems in that the
13528 #. .BR chown (1)
13529 #. and
13530 #. .BR chgrp (1)
13531 #. commands follow symbolic links specified on the command line.
13532 #. type: Plain text
13533 #: build/C/man7/symlink.7:307
13534 msgid ""
13535 "The B<file>(1)  command is also an exception to this rule.  The B<file>(1)  "
13536 "command does not follow symbolic links named as argument by default.  The "
13537 "B<file>(1)  command does follow symbolic links named as argument if the I<-"
13538 "L> option is specified."
13539 msgstr ""
13540
13541 #. type: SS
13542 #: build/C/man7/symlink.7:307
13543 #, no-wrap
13544 msgid "Commands traversing a file tree"
13545 msgstr ""
13546
13547 #. type: Plain text
13548 #: build/C/man7/symlink.7:320
13549 msgid ""
13550 "The following commands either optionally or always traverse file trees: "
13551 "B<chgrp>(1), B<chmod>(1), B<chown>(1), B<cp>(1), B<du>(1), B<find>(1), B<ls>"
13552 "(1), B<pax>(1), B<rm>(1), and B<tar>(1)."
13553 msgstr ""
13554
13555 #. type: Plain text
13556 #: build/C/man7/symlink.7:324
13557 msgid ""
13558 "It is important to realize that the following rules apply equally to "
13559 "symbolic links encountered during the file tree traversal and symbolic links "
13560 "listed as command-line arguments."
13561 msgstr ""
13562
13563 #. type: Plain text
13564 #: build/C/man7/symlink.7:329
13565 msgid ""
13566 "The I<first rule> applies to symbolic links that reference files other than "
13567 "directories.  Operations that apply to symbolic links are performed on the "
13568 "links themselves, but otherwise the links are ignored."
13569 msgstr ""
13570
13571 #. type: Plain text
13572 #: build/C/man7/symlink.7:341
13573 msgid ""
13574 "The command I<rm\\ -r slink directory> will remove I<slink>, as well as any "
13575 "symbolic links encountered in the tree traversal of I<directory>, because "
13576 "symbolic links may be removed.  In no case will B<rm>(1)  affect the file "
13577 "referred to by I<slink>."
13578 msgstr ""
13579
13580 #. type: Plain text
13581 #: build/C/man7/symlink.7:346
13582 msgid ""
13583 "The I<second rule> applies to symbolic links that refer to directories.  "
13584 "Symbolic links that refer to directories are never followed by default.  "
13585 "This is often referred to as a \"physical\" walk, as opposed to a \"logical"
13586 "\" walk (where symbolic links the refer to directories are followed)."
13587 msgstr ""
13588
13589 #. type: Plain text
13590 #: build/C/man7/symlink.7:349
13591 msgid ""
13592 "Certain conventions are (should be) followed as consistently as possible by "
13593 "commands that perform file tree walks:"
13594 msgstr ""
13595
13596 #. type: Plain text
13597 #: build/C/man7/symlink.7:362
13598 msgid ""
13599 "A command can be made to follow any symbolic links named on the command "
13600 "line, regardless of the type of file they reference, by specifying the I<-H> "
13601 "(for \"half-logical\") flag.  This flag is intended to make the command-line "
13602 "name space look like the logical name space.  (Note, for commands that do "
13603 "not always do file tree traversals, the I<-H> flag will be ignored if the I<-"
13604 "R> flag is not also specified.)"
13605 msgstr ""
13606
13607 #. type: Plain text
13608 #: build/C/man7/symlink.7:378
13609 msgid ""
13610 "For example, the command I<chown\\ -HR user slink> will traverse the file "
13611 "hierarchy rooted in the file pointed to by I<slink>.  Note, the I<-H> is not "
13612 "the same as the previously discussed I<-h> flag.  The I<-H> flag causes "
13613 "symbolic links specified on the command line to be dereferenced for the "
13614 "purposes of both the action to be performed and the tree walk, and it is as "
13615 "if the user had specified the name of the file to which the symbolic link "
13616 "pointed."
13617 msgstr ""
13618
13619 #. type: Plain text
13620 #: build/C/man7/symlink.7:392
13621 msgid ""
13622 "A command can be made to follow any symbolic links named on the command "
13623 "line, as well as any symbolic links encountered during the traversal, "
13624 "regardless of the type of file they reference, by specifying the I<-L> (for "
13625 "\"logical\") flag.  This flag is intended to make the entire name space look "
13626 "like the logical name space.  (Note, for commands that do not always do file "
13627 "tree traversals, the I<-L> flag will be ignored if the I<-R> flag is not "
13628 "also specified.)"
13629 msgstr ""
13630
13631 #. type: Plain text
13632 #: build/C/man7/symlink.7:407
13633 msgid ""
13634 "For example, the command I<chown\\ -LR user slink> will change the owner of "
13635 "the file referred to by I<slink>.  If I<slink> refers to a directory, "
13636 "B<chown> will traverse the file hierarchy rooted in the directory that it "
13637 "references.  In addition, if any symbolic links are encountered in any file "
13638 "tree that B<chown> traverses, they will be treated in the same fashion as "
13639 "I<slink>."
13640 msgstr ""
13641
13642 #. type: Plain text
13643 #: build/C/man7/symlink.7:414
13644 msgid ""
13645 "A command can be made to provide the default behavior by specifying the I<-"
13646 "P> (for \"physical\") flag.  This flag is intended to make the entire name "
13647 "space look like the physical name space."
13648 msgstr ""
13649
13650 #. type: Plain text
13651 #: build/C/man7/symlink.7:432
13652 msgid ""
13653 "For commands that do not by default do file tree traversals, the I<-H>, I<-"
13654 "L>, and I<-P> flags are ignored if the I<-R> flag is not also specified.  In "
13655 "addition, you may specify the I<-H>, I<-L>, and I<-P> options more than "
13656 "once; the last one specified determines the command's behavior.  This is "
13657 "intended to permit you to alias commands to behave one way or the other, and "
13658 "then override that behavior on the command line."
13659 msgstr ""
13660
13661 #. type: Plain text
13662 #: build/C/man7/symlink.7:438
13663 msgid "The B<ls>(1)  and B<rm>(1)  commands have exceptions to these rules:"
13664 msgstr ""
13665
13666 #. type: Plain text
13667 #: build/C/man7/symlink.7:451
13668 msgid ""
13669 "The B<rm>(1)  command operates on the symbolic link, and not the file it "
13670 "references, and therefore never follows a symbolic link.  The B<rm>(1)  "
13671 "command does not support the I<-H>, I<-L>, or I<-P> options."
13672 msgstr ""
13673
13674 #. type: Plain text
13675 #: build/C/man7/symlink.7:471
13676 msgid ""
13677 "To maintain compatibility with historic systems, the B<ls>(1)  command acts "
13678 "a little differently.  If you do not specify the I<-F>, I<-d> or I<-l> "
13679 "options, B<ls>(1)  will follow symbolic links specified on the command "
13680 "line.  If the I<-L> flag is specified, B<ls>(1)  follows all symbolic links, "
13681 "regardless of their type, whether specified on the command line or "
13682 "encountered in the tree walk."
13683 msgstr ""
13684
13685 #. type: Plain text
13686 #: build/C/man7/symlink.7:489
13687 msgid ""
13688 "B<chgrp>(1), B<chmod>(1), B<find>(1), B<ln>(1), B<ls>(1), B<mv>(1), B<rm>"
13689 "(1), B<lchown>(2), B<link>(2), B<lstat>(2), B<readlink>(2), B<rename>(2), "
13690 "B<symlink>(2), B<unlink>(2), B<utimensat>(2), B<lutimes>(3), "
13691 "B<path_resolution>(7)"
13692 msgstr ""
13693 "B<chgrp>(1), B<chmod>(1), B<find>(1), B<ln>(1), B<ls>(1), B<mv>(1),\n"
13694 "B<rm>(1), B<lchown>(2), B<link>(2), B<lstat>(2), B<readlink>(2),\n"
13695 "B<rename>(2), B<symlink>(2), B<unlink>(2), B<utimensat>(2),\n"
13696 "B<lutimes>(3), B<path_resolution>(7)"
13697
13698 #. type: TH
13699 #: build/C/man3/tempnam.3:25
13700 #, no-wrap
13701 msgid "TEMPNAM"
13702 msgstr "TEMPNAM"
13703
13704 #. type: TH
13705 #: build/C/man3/tempnam.3:25
13706 #, no-wrap
13707 msgid "2008-08-06"
13708 msgstr "2008-08-06"
13709
13710 #. type: Plain text
13711 #: build/C/man3/tempnam.3:28
13712 msgid "tempnam - create a name for a temporary file"
13713 msgstr "tempnam - テンポラリファイルの名前を作成する"
13714
13715 #. type: Plain text
13716 #: build/C/man3/tempnam.3:33
13717 #, no-wrap
13718 msgid "B<char *tempnam(const char *>I<dir>B<, const char *>I<pfx>B<);>\n"
13719 msgstr "B<char *tempnam(const char *>I<dir>B<, const char *>I<pfx>B<);>\n"
13720
13721 #. type: Plain text
13722 #: build/C/man3/tempnam.3:42
13723 msgid "B<tempnam>(): _BSD_SOURCE || _SVID_SOURCE"
13724 msgstr "B<tempnam>(): _BSD_SOURCE || _SVID_SOURCE"
13725
13726 #. type: Plain text
13727 #: build/C/man3/tempnam.3:56
13728 msgid ""
13729 "The B<tempnam>()  function returns a pointer to a string that is a valid "
13730 "filename, and such that a file with this name did not exist when B<tempnam>"
13731 "()  checked.  The filename suffix of the pathname generated will start with "
13732 "I<pfx> in case I<pfx> is a non-NULL string of at most five bytes.  The "
13733 "directory prefix part of the pathname generated is required to be "
13734 "\"appropriate\" (often that at least implies writable)."
13735 msgstr ""
13736 "B<tempnam>()  関数はファイル名として正しい文字列へのポインタを返す。 このファ"
13737 "イル名を持つファイルは、 B<tempnam>()  がチェックした時点においては存在しな"
13738 "い (しなかった)。 I<pfx> が NULL でない 5 バイト以内の文字列であれば、 生成さ"
13739 "れるパス名のうちのファイル名の部分は I<pfx> から始まるものになる。 生成される"
13740 "ディレクトリの部分は、「適切」でなければならない (大抵の場合、「適切」である"
13741 "ためにはまず少なくとも 書き込み可能でなければならない)。"
13742
13743 #. type: Plain text
13744 #: build/C/man3/tempnam.3:59
13745 msgid ""
13746 "Attempts to find an appropriate directory go through the following steps:"
13747 msgstr "適切なディレクトリの探索は、以下の手順にしたがって行われる。"
13748
13749 #. type: TP
13750 #: build/C/man3/tempnam.3:59
13751 #, no-wrap
13752 msgid "a)"
13753 msgstr "a)"
13754
13755 #. type: Plain text
13756 #: build/C/man3/tempnam.3:65
13757 msgid ""
13758 "In case the environment variable B<TMPDIR> exists and contains the name of "
13759 "an appropriate directory, that is used."
13760 msgstr ""
13761 "環境変数 B<TMPDIR> が設定されていて、 その内容が適切なディレクトリの名前な"
13762 "ら、それを用いる。"
13763
13764 #. type: TP
13765 #: build/C/man3/tempnam.3:65
13766 #, no-wrap
13767 msgid "b)"
13768 msgstr "b)"
13769
13770 #. type: Plain text
13771 #: build/C/man3/tempnam.3:70
13772 msgid ""
13773 "Otherwise, if the I<dir> argument is non-NULL and appropriate, it is used."
13774 msgstr ""
13775 "それ以外の場合、 I<dir> 引き数が NULL でない文字列でかつ適切なら、それを用い"
13776 "る。"
13777
13778 #. type: TP
13779 #: build/C/man3/tempnam.3:70
13780 #, no-wrap
13781 msgid "c)"
13782 msgstr "c)"
13783
13784 #. type: Plain text
13785 #: build/C/man3/tempnam.3:77
13786 msgid ""
13787 "Otherwise, I<P_tmpdir> (as defined in I<E<lt>stdio.hE<gt>>)  is used when "
13788 "appropriate."
13789 msgstr ""
13790 "それ以外の場合、 (I<E<lt>stdio.hE<gt>> で定義されている)  I<P_tmpdir> が適切"
13791 "なら、それを用いる。"
13792
13793 #. type: TP
13794 #: build/C/man3/tempnam.3:77
13795 #, no-wrap
13796 msgid "d)"
13797 msgstr "d)"
13798
13799 #. type: Plain text
13800 #: build/C/man3/tempnam.3:80
13801 msgid "Finally an implementation-defined directory may be used."
13802 msgstr "最後に実装で定義されたディレクトリが用いられることになる。"
13803
13804 #. type: Plain text
13805 #: build/C/man3/tempnam.3:87
13806 msgid ""
13807 "The string returned by B<tempnam>()  is allocated using B<malloc>(3)  and "
13808 "hence should be freed by B<free>(3)."
13809 msgstr ""
13810 "B<tempnam>()  が返す文字列は B<malloc>(3)  を使って確保される。そのため、 "
13811 "B<free>(3)  で解放すべきである。"
13812
13813 #. type: Plain text
13814 #: build/C/man3/tempnam.3:92
13815 msgid ""
13816 "The B<tempnam>()  function returns a pointer to a unique temporary filename, "
13817 "or NULL if a unique name cannot be generated."
13818 msgstr ""
13819 "B<tempnam>()  関数は他と重ならないテンポラリファイル名へのポインタを返す。 他"
13820 "と重ならない名前が生成できなければ NULL を返す。"
13821
13822 #. type: Plain text
13823 #: build/C/man3/tempnam.3:96
13824 msgid "Allocation of storage failed."
13825 msgstr "保存領域の割り当てに失敗した。"
13826
13827 #. type: Plain text
13828 #: build/C/man3/tempnam.3:101
13829 msgid ""
13830 "SVr4, 4.3BSD, POSIX.1-2001.  POSIX.1-2008 marks B<tempnam>()  as obsolete."
13831 msgstr ""
13832 "SVr4, 4.3BSD, POSIX.1-2001.  POSIX.1-2008 は B<tempnam>()  を廃止予定としてい"
13833 "る。"
13834
13835 #. type: Plain text
13836 #: build/C/man3/tempnam.3:120
13837 msgid ""
13838 "Although B<tempnam>()  generates names that are difficult to guess, it is "
13839 "nevertheless possible that between the time that B<tempnam>()  returns a "
13840 "pathname, and the time that the program opens it, another program might "
13841 "create that pathname using B<open>(2), or create it as a symbolic link.  "
13842 "This can lead to security holes.  To avoid such possibilities, use the "
13843 "B<open>(2)  B<O_EXCL> flag to open the pathname.  Or better yet, use "
13844 "B<mkstemp>(3)  or B<tmpfile>(3)."
13845 msgstr ""
13846 "B<tempnam>()  は推測が難しい名前を生成するが、それにもかかわらず、 B<tempnam>"
13847 "()  がパス名を返してから、プログラムがそのファイルをオープンする までの間に、"
13848 "別のプログラムが同じパス名で、ファイルを B<open>(2)  で作成したり、シンボリッ"
13849 "クリンクを作成したりする可能性がある。 これはセキュリティホールにつながる可能"
13850 "性がある。 そのような可能性を回避するためには、 B<open>(2)  の B<O_EXCL> フラ"
13851 "グを使ってパス名をオープンすればよい。 もっといいのは、 B<mkstemp>(3)  や "
13852 "B<tmpfile>(3)  を使うことである。"
13853
13854 #. type: Plain text
13855 #: build/C/man3/tempnam.3:128
13856 msgid ""
13857 "SUSv2 does not mention the use of B<TMPDIR>; glibc will use it only when the "
13858 "program is not set-user-ID.  On SVr4, the directory used under B<d)> is I</"
13859 "tmp> (and this is what glibc does)."
13860 msgstr ""
13861 "SUSv2 では B<TMPDIR> に付いて言及されていない。 glibc は、プログラムが set-"
13862 "user-ID されていない場合に限ってこれを用いる。 SVr4 では B<d)> で使用される"
13863 "ディレクトリを I</tmp> と定めている (glibc もこの通りである)。"
13864
13865 #. type: Plain text
13866 #: build/C/man3/tempnam.3:133
13867 msgid ""
13868 "Because it dynamically allocates memory used to return the pathname, "
13869 "B<tempnam>()  is reentrant, and thus thread safe, unlike B<tmpnam>(3)."
13870 msgstr ""
13871 "パス名を返すのに使用するメモリを動的に確保するので、 B<tmpnam>(3)  と違い、 "
13872 "B<tempnam>()  はリエントラントであり、スレッドセーフである。"
13873
13874 #. type: Plain text
13875 #: build/C/man3/tempnam.3:146
13876 msgid ""
13877 "The B<tempnam>()  function generates a different string each time it is "
13878 "called, up to B<TMP_MAX> (defined in I<E<lt>stdio.hE<gt>>)  times.  If it is "
13879 "called more than B<TMP_MAX> times, the behavior is implementation defined."
13880 msgstr ""
13881 "B<tempnam>()  関数は最大 B<TMP_MAX> 回まで、呼び出される度に異なる文字列を作"
13882 "成する (B<TMP_MAX> は I<E<lt>stdio.hE<gt>> で定義されている)。 もし "
13883 "B<TMP_MAX> 回以上呼び出された場合、動作は実装依存である。"
13884
13885 #. type: Plain text
13886 #: build/C/man3/tempnam.3:150
13887 msgid "B<tempnam>()  uses at most the first five bytes from I<pfx>."
13888 msgstr "B<tempnam>()  は最大で I<pfx> の先頭 5 バイトを使用する。"
13889
13890 #. type: Plain text
13891 #: build/C/man3/tempnam.3:156
13892 msgid ""
13893 "The glibc implementation of B<tempnam>()  will fail with the error B<EEXIST> "
13894 "upon failure to find a unique name."
13895 msgstr ""
13896 "他と重ならない名前が見つけられなかった場合、glibc の B<tempnam>()  の実装はエ"
13897 "ラー B<EEXIST> で失敗する。"
13898
13899 #. type: Plain text
13900 #: build/C/man3/tempnam.3:159
13901 msgid ""
13902 "The precise meaning of \"appropriate\" is undefined; it is unspecified how "
13903 "accessibility of a directory is determined."
13904 msgstr ""
13905 "「適切」という言葉の正確な意味は定義されていない。 ディレクトリに対してどの程"
13906 "度のアクセス権限が必要なのかは指定されていない。"
13907
13908 #. type: Plain text
13909 #: build/C/man3/tempnam.3:166 build/C/man3/tmpnam.3:153
13910 msgid "Never use this function.  Use B<mkstemp>(3)  or B<tmpfile>(3)  instead."
13911 msgstr ""
13912 "決してこの関数を使ってはならない。代わりに B<mkstemp>(3)  か B<tmpfile>(3)  "
13913 "を使うこと。"
13914
13915 #. type: Plain text
13916 #: build/C/man3/tempnam.3:171
13917 msgid "B<mkstemp>(3), B<mktemp>(3), B<tmpfile>(3), B<tmpnam>(3)"
13918 msgstr "B<mkstemp>(3), B<mktemp>(3), B<tmpfile>(3), B<tmpnam>(3)"
13919
13920 #. type: TH
13921 #: build/C/man3/tmpfile.3:31
13922 #, no-wrap
13923 msgid "TMPFILE"
13924 msgstr "TMPFILE"
13925
13926 #. type: Plain text
13927 #: build/C/man3/tmpfile.3:34
13928 msgid "tmpfile - create a temporary file"
13929 msgstr "tmpfile - テンポラリファイルを作成する"
13930
13931 #. type: Plain text
13932 #: build/C/man3/tmpfile.3:39
13933 #, no-wrap
13934 msgid "B<FILE *tmpfile(void);>\n"
13935 msgstr "B<FILE *tmpfile(void);>\n"
13936
13937 #. type: Plain text
13938 #: build/C/man3/tmpfile.3:47
13939 msgid ""
13940 "The B<tmpfile>()  function opens a unique temporary file in binary read/"
13941 "write (w+b) mode.  The file will be automatically deleted when it is closed "
13942 "or the program terminates."
13943 msgstr ""
13944 "B<tmpfile>()  関数はユニークなテンポラリファイルを バイナリリードライトモー"
13945 "ド (w+b) でオープンする。 このファイルはクローズ時またはプログラムの終了時に"
13946 "自動的に削除される。"
13947
13948 #. type: Plain text
13949 #: build/C/man3/tmpfile.3:54
13950 msgid ""
13951 "The B<tmpfile>()  function returns a stream descriptor, or NULL if a unique "
13952 "filename cannot be generated or the unique file cannot be opened.  In the "
13953 "latter case, I<errno> is set to indicate the error."
13954 msgstr ""
13955 "B<tmpfile>()  関数はファイルポインタを返すか、 ユニークなファイルが作れなかっ"
13956 "たかオープンできなかった場合は NULL を返す。 後者の場合、エラーを表す "
13957 "I<errno> を設定する。"
13958
13959 #. type: Plain text
13960 #: build/C/man3/tmpfile.3:58
13961 msgid "Search permission denied for directory in file's path prefix."
13962 msgstr ""
13963 "ファイルのあるディレクトリにサーチのアクセス権 (search permission) がない。"
13964
13965 #. type: Plain text
13966 #: build/C/man3/tmpfile.3:61
13967 msgid "Unable to generate a unique filename."
13968 msgstr "ユニークなファイル名が作成できなかった。"
13969
13970 #. type: Plain text
13971 #: build/C/man3/tmpfile.3:64
13972 msgid "The call was interrupted by a signal."
13973 msgstr "呼び出しがシグナルによって中断された。"
13974
13975 #. type: Plain text
13976 #: build/C/man3/tmpfile.3:67
13977 msgid "Too many file descriptors in use by the process."
13978 msgstr "1 つのプロセスで使用可能なファイルディスクリプタ数を超過した。"
13979
13980 #. type: Plain text
13981 #: build/C/man3/tmpfile.3:70
13982 msgid "Too many files open in the system."
13983 msgstr "システム全体でオープン可能なファイル数を超過した。"
13984
13985 #. type: Plain text
13986 #: build/C/man3/tmpfile.3:73
13987 msgid "There was no room in the directory to add the new filename."
13988 msgstr "ディレクトリに新しいファイルを追加するための空き領域がない。"
13989
13990 #. type: Plain text
13991 #: build/C/man3/tmpfile.3:76
13992 msgid "Read-only file system."
13993 msgstr "読みだし専用ファイルシステムである。"
13994
13995 #. type: Plain text
13996 #: build/C/man3/tmpfile.3:78
13997 msgid "SVr4, 4.3BSD, C89, C99, SUSv2, POSIX.1-2001."
13998 msgstr "SVr4, 4.3BSD, C89, C99, SUSv2, POSIX.1-2001."
13999
14000 #. type: Plain text
14001 #: build/C/man3/tmpfile.3:82
14002 msgid ""
14003 "POSIX.1-2001 specifies: an error message may be written to I<stdout> if the "
14004 "stream cannot be opened."
14005 msgstr ""
14006 "POSIX.1-2001 では、 ストリームをオープンできなかった場合、 I<stdout> にエラー"
14007 "メッセージが書き出される、と規定されている。"
14008
14009 #. type: Plain text
14010 #: build/C/man3/tmpfile.3:88
14011 msgid ""
14012 "The standard does not specify the directory that B<tmpfile>()  will use.  "
14013 "Glibc will try the path prefix I<P_tmpdir> defined in I<E<lt>stdio.hE<gt>>, "
14014 "and if that fails the directory I</tmp>."
14015 msgstr ""
14016 "規格では B<tmpfile>()  が使うディレクトリは指定されていない。 glibc では "
14017 "I<E<lt>stdio.hE<gt>> で定義されている I<P_tmpdir> をパスの先頭に使おうとす"
14018 "る。 これが失敗した場合は、ディレクトリ I</tmp> を使う。"
14019
14020 #. type: Plain text
14021 #: build/C/man3/tmpfile.3:94
14022 msgid "B<exit>(3), B<mkstemp>(3), B<mktemp>(3), B<tempnam>(3), B<tmpnam>(3)"
14023 msgstr "B<exit>(3), B<mkstemp>(3), B<mktemp>(3), B<tempnam>(3), B<tmpnam>(3)"
14024
14025 #. type: TH
14026 #: build/C/man3/tmpnam.3:27
14027 #, no-wrap
14028 msgid "TMPNAM"
14029 msgstr "TMPNAM"
14030
14031 #. type: TH
14032 #: build/C/man3/tmpnam.3:27
14033 #, no-wrap
14034 msgid "2010-09-10"
14035 msgstr "2010-09-10"
14036
14037 #. type: Plain text
14038 #: build/C/man3/tmpnam.3:30
14039 msgid "tmpnam, tmpnam_r - create a name for a temporary file"
14040 msgstr "tmpnam, tmpnam_r - 一時ファイルの名前を作成する"
14041
14042 #. type: Plain text
14043 #: build/C/man3/tmpnam.3:35
14044 #, no-wrap
14045 msgid "B<char *tmpnam(char *>I<s>B<);>\n"
14046 msgstr "B<char *tmpnam(char *>I<s>B<);>\n"
14047
14048 #. type: Plain text
14049 #: build/C/man3/tmpnam.3:58
14050 msgid ""
14051 "The B<tmpnam>()  function returns a pointer to a string that is a valid "
14052 "filename, and such that a file with this name did not exist at some point in "
14053 "time, so that naive programmers may think it a suitable name for a temporary "
14054 "file.  If the argument I<s> is NULL this name is generated in an internal "
14055 "static buffer and may be overwritten by the next call to B<tmpnam>().  If "
14056 "I<s> is not NULL, the name is copied to the character array (of length at "
14057 "least I<L_tmpnam>)  pointed to by I<s> and the value I<s> is returned in "
14058 "case of success."
14059 msgstr ""
14060 "B<tmpnam>()  関数は、ファイル名に使える文字列へのポインタを返す。 ある時点で"
14061 "は同じ名前を持つファイルが存在しないファイル名が返されるので、 幼稚なプログラ"
14062 "マはこの文字列が一時ファイルのファイル名として 適していると考えるかもしれな"
14063 "い。 引き数 I<s> が NULL なら、この名前は内部の静的バッファに作成され、 次に "
14064 "B<tmpnam>()  関数が呼び出された時に上書きされる。 I<s> が NULL でなければ、"
14065 "ファイル名は I<s> が指す (少なくとも I<L_tmpnam> の長さを持つ) 文字配列にコ"
14066 "ピーされ、 成功した場合は I<s> が返される。"
14067
14068 #. type: Plain text
14069 #: build/C/man3/tmpnam.3:70
14070 msgid ""
14071 "The pathname that is created, has a directory prefix I<P_tmpdir>.  (Both "
14072 "I<L_tmpnam> and I<P_tmpdir> are defined in I<E<lt>stdio.hE<gt>>, just like "
14073 "the B<TMP_MAX> mentioned below.)"
14074 msgstr ""
14075 "作成されるパス名は、ディレクトリの部分に I<P_tmpdir> が使われる。 "
14076 "(I<L_tmpnam> と I<P_tmpdir> は、以下で説明する B<TMP_MAX> 同様 I<E<lt>stdio."
14077 "hE<gt>> で定義されている。)"
14078
14079 #. type: Plain text
14080 #: build/C/man3/tmpnam.3:75
14081 msgid ""
14082 "The B<tmpnam>()  function returns a pointer to a unique temporary filename, "
14083 "or NULL if a unique name cannot be generated."
14084 msgstr ""
14085 "B<tmpnam>()  関数は一意な一時ファイル名へのポインタを返す。 一意なファイル名"
14086 "が作成できなかった場合は NULL を返す。"
14087
14088 #. type: Plain text
14089 #: build/C/man3/tmpnam.3:77
14090 msgid "No errors are defined."
14091 msgstr "エラーは定義されていない。"
14092
14093 #. type: Plain text
14094 #: build/C/man3/tmpnam.3:82
14095 msgid ""
14096 "SVr4, 4.3BSD, C89, C99, POSIX.1-2001.  POSIX.1-2008 marks B<tmpnam>()  as "
14097 "obsolete."
14098 msgstr ""
14099 "SVr4, 4.3BSD, C89, C99, POSIX.1-2001.  POSIX.1-2008 は B<tmpnam>()  を廃止予"
14100 "定としている。"
14101
14102 #. type: Plain text
14103 #: build/C/man3/tmpnam.3:93
14104 msgid ""
14105 "The B<tmpnam>()  function generates a different string each time it is "
14106 "called, up to B<TMP_MAX> times.  If it is called more than B<TMP_MAX> times, "
14107 "the behavior is implementation defined."
14108 msgstr ""
14109 "B<tmpnam>()  関数は最大 B<TMP_MAX> 回まで、呼び出される度に異なる文字列を作成"
14110 "する。 B<TMP_MAX> 回以上呼び出された場合、その動作は実装依存である。"
14111
14112 #. type: Plain text
14113 #: build/C/man3/tmpnam.3:112
14114 msgid ""
14115 "Although B<tmpnam>()  generates names that are difficult to guess, it is "
14116 "nevertheless possible that between the time that B<tmpnam>()  returns a "
14117 "pathname, and the time that the program opens it, another program might "
14118 "create that pathname using B<open>(2), or create it as a symbolic link.  "
14119 "This can lead to security holes.  To avoid such possibilities, use the "
14120 "B<open>(2)  B<O_EXCL> flag to open the pathname.  Or better yet, use "
14121 "B<mkstemp>(3)  or B<tmpfile>(3)."
14122 msgstr ""
14123 "B<tmpnam>()  は推測が難しい名前を生成するが、それにもかかわらず、 B<tmpnam>"
14124 "()  がパス名を返してから、プログラムがそのファイルをオープンする までの間に、"
14125 "別のプログラムが同じパス名で、ファイルを B<open>(2)  で作成したり、シンボリッ"
14126 "クリンクを作成したりする可能性がある。 これはセキュリティホールにつながる可能"
14127 "性がある。 そのような可能性を回避するためには、 B<open>(2)  の B<O_EXCL> フラ"
14128 "グを使ってパス名をオープンすればよい。 もっといいのは、 B<mkstemp>(3)  や "
14129 "B<tmpfile>(3)  を使うことである。"
14130
14131 #. type: Plain text
14132 #: build/C/man3/tmpnam.3:120
14133 msgid ""
14134 "Portable applications that use threads cannot call B<tmpnam>()  with a NULL "
14135 "argument if either B<_POSIX_THREADS> or B<_POSIX_THREAD_SAFE_FUNCTIONS> is "
14136 "defined."
14137 msgstr ""
14138 "移植性が必要な、スレッドを使ったアプリケーションでは、 B<_POSIX_THREADS> か "
14139 "B<_POSIX_THREAD_SAFE_FUNCTIONS> が定義されている場合に、 B<tmpnam>()  関数を "
14140 "NULL 引き数で呼び出してはならない。"
14141
14142 #. type: Plain text
14143 #: build/C/man3/tmpnam.3:124
14144 msgid "A POSIX draft proposed to use a function B<tmpnam_r>()  defined by"
14145 msgstr ""
14146 "POSIX 草案では、関数 B<tmpnam_r>()  を使うことを提案している。 この関数は、以"
14147 "下のように定義されており、 NULL を使わないようにという警告の意味で NULL を別"
14148 "扱いしている。"
14149
14150 #. type: Plain text
14151 #: build/C/man3/tmpnam.3:132
14152 #, no-wrap
14153 msgid ""
14154 "char *\n"
14155 "tmpnam_r(char *s)\n"
14156 "{\n"
14157 "    return s ? tmpnam(s) : NULL;\n"
14158 "}\n"
14159 msgstr ""
14160 "char *\n"
14161 "tmpnam_r(char *s)\n"
14162 "{\n"
14163 "    return s ? tmpnam(s) : NULL;\n"
14164 "}\n"
14165
14166 #. type: Plain text
14167 #: build/C/man3/tmpnam.3:146
14168 msgid ""
14169 "apparently as a warning not to use NULL.  A few systems implement it.  To "
14170 "get a glibc prototype for this function from I<E<lt>stdio.hE<gt>>, define "
14171 "B<_SVID_SOURCE> or B<_BSD_SOURCE> (before including I<any> header file)."
14172 msgstr ""
14173 "数は少ないが、この関数を実装しているシステムもある。 この関数の glibc のプロ"
14174 "トタイプを I<E<lt>stdio.hE<gt>> から得るには、 (「どの」ヘッダファイルをイン"
14175 "クルードするよりも前に)  B<_SVID_SOURCE> か B<_BSD_SOURCE> を定義しておく必要"
14176 "がある。"
14177
14178 #. type: Plain text
14179 #: build/C/man3/tmpnam.3:158
14180 msgid "B<mkstemp>(3), B<mktemp>(3), B<tempnam>(3), B<tmpfile>(3)"
14181 msgstr "B<mkstemp>(3), B<mktemp>(3), B<tempnam>(3), B<tmpfile>(3)"
14182
14183 #. type: TH
14184 #: build/C/man2/unlink.2:32
14185 #, no-wrap
14186 msgid "UNLINK"
14187 msgstr "UNLINK"
14188
14189 #. type: TH
14190 #: build/C/man2/unlink.2:32
14191 #, no-wrap
14192 msgid "2011-09-15"
14193 msgstr "2011-09-15"
14194
14195 #. type: Plain text
14196 #: build/C/man2/unlink.2:35
14197 msgid "unlink - delete a name and possibly the file it refers to"
14198 msgstr ""
14199 "unlink - 名前を削除し、場合によってはそれが参照しているファイルも削除する"
14200
14201 #. type: Plain text
14202 #: build/C/man2/unlink.2:39
14203 msgid "B<int unlink(const char *>I<pathname>B<);>"
14204 msgstr "B<int unlink(const char *>I<pathname>B<);>"
14205
14206 #. type: Plain text
14207 #: build/C/man2/unlink.2:45
14208 msgid ""
14209 "B<unlink>()  deletes a name from the file system.  If that name was the last "
14210 "link to a file and no processes have the file open the file is deleted and "
14211 "the space it was using is made available for reuse."
14212 msgstr ""
14213 "B<unlink>()  はファイルシステム上の名前を削除する。 もしその名前がファイルへ"
14214 "の最後のリンク (link) であり、 どのプロセスもそのファイルをオープン (open) し"
14215 "ていなければ、 ファイルは削除される。 ファイルが使用していたディスク上の領域"
14216 "は再利用が可能になる。"
14217
14218 #. type: Plain text
14219 #: build/C/man2/unlink.2:49
14220 msgid ""
14221 "If the name was the last link to a file but any processes still have the "
14222 "file open the file will remain in existence until the last file descriptor "
14223 "referring to it is closed."
14224 msgstr ""
14225 "もし削除する名前がファイルへの最後のリンクだが、どれかのプロセスが そのファイ"
14226 "ルをまだオープンしている場合は、 そのファイルを参照している最後のファイルディ"
14227 "スクリプタ (file descriptor)  がクローズ (close) されるまでファイルは存在し続"
14228 "ける。"
14229
14230 #. type: Plain text
14231 #: build/C/man2/unlink.2:51
14232 msgid "If the name referred to a symbolic link the link is removed."
14233 msgstr ""
14234 "もしその名前がシンボリックリンク (symbolic link) を参照していれば、 リンクは"
14235 "削除される。"
14236
14237 #. type: Plain text
14238 #: build/C/man2/unlink.2:55
14239 msgid ""
14240 "If the name referred to a socket, fifo or device the name for it is removed "
14241 "but processes which have the object open may continue to use it."
14242 msgstr ""
14243 "もし名前がソケット (socket) や fifo やデバイス (device) を参照していれば 名前"
14244 "は削除されるがそのオブジェクトをオープンしていたプロセスは それを使い続けるこ"
14245 "とができる。"
14246
14247 #. type: Plain text
14248 #: build/C/man2/unlink.2:71
14249 msgid ""
14250 "Write access to the directory containing I<pathname> is not allowed for the "
14251 "process's effective UID, or one of the directories in I<pathname> did not "
14252 "allow search permission.  (See also B<path_resolution>(7).)"
14253 msgstr ""
14254 "I<pathname> を含んでいるディレクトリの書き込み許可がプロセスの実効 "
14255 "(effective)  ユーザー ID に与えられていないか、 I<pathname> の中のディレクト"
14256 "リのどれかに検索許可が与えられていない (B<path_resolution>(7)  も参照するこ"
14257 "と)。"
14258
14259 #. type: Plain text
14260 #: build/C/man2/unlink.2:80
14261 msgid ""
14262 "The file I<pathname> cannot be unlinked because it is being used by the "
14263 "system or another process; for example, it is a mount point or the NFS "
14264 "client software created it to represent an active but otherwise nameless "
14265 "inode (\"NFS silly renamed\")."
14266 msgstr ""
14267 "システムか別のプロセスがそのファイルを使用中のため、\n"
14268 "ファイル I<pathname> を unlink できない。\n"
14269 "例えば、そのファイルがマウントポイントの場合や、\n"
14270 "NFS クライアントソフトウェアがそのファイルがアクティブであるが\n"
14271 "名前なし inode (nameless inode) であることを示すために作成した\n"
14272 "場合 (\"NFS silly renamed\") などがある。"
14273
14274 #. type: Plain text
14275 #: build/C/man2/unlink.2:92
14276 msgid ""
14277 "I<pathname> refers to a directory.  (This is the non-POSIX value returned by "
14278 "Linux since 2.1.132.)"
14279 msgstr ""
14280 "I<pathname> がディレクトリを参照している。 (これは POSIX で規定されていない値"
14281 "で、Linux 2.1.132 以降で返される。)"
14282
14283 #. type: Plain text
14284 #: build/C/man2/unlink.2:96
14285 msgid "Too many symbolic links were encountered in translating I<pathname>."
14286 msgstr "I<pathname> を解決する際に遭遇したシンボリックリンクが多過ぎる。"
14287
14288 #. type: Plain text
14289 #: build/C/man2/unlink.2:106
14290 msgid ""
14291 "A component in I<pathname> does not exist or is a dangling symbolic link, or "
14292 "I<pathname> is empty."
14293 msgstr ""
14294 "I<pathname> に対応するものが存在しないか、壊れたシンボリックリンクであるか、 "
14295 "I<pathname> が空である。"
14296
14297 #. type: Plain text
14298 #: build/C/man2/unlink.2:114
14299 msgid ""
14300 "A component used as a directory in I<pathname> is not, in fact, a directory."
14301 msgstr "I<pathname> のディレクトリ部分が、実際には、ディレクトリでない。"
14302
14303 #. type: Plain text
14304 #: build/C/man2/unlink.2:123
14305 msgid ""
14306 "The system does not allow unlinking of directories, or unlinking of "
14307 "directories requires privileges that the calling process doesn't have.  "
14308 "(This is the POSIX prescribed error return; as noted above, Linux returns "
14309 "B<EISDIR> for this case.)"
14310 msgstr ""
14311 "システムがディレクトリに対する unlink 操作を許可していない。 またはディレクト"
14312 "リに対する unlink 操作のために必要な特権を 呼び出し元のプロセスが持っていな"
14313 "い。 (これは POSIX で規定されているエラーの返し方である。 上述の通り、この場"
14314 "合には Linux は B<EISDIR> を返す。)"
14315
14316 #. type: TP
14317 #: build/C/man2/unlink.2:123
14318 #, no-wrap
14319 msgid "B<EPERM> (Linux only)"
14320 msgstr "B<EPERM> (Linux のみ)"
14321
14322 #. type: Plain text
14323 #: build/C/man2/unlink.2:126
14324 msgid "The file system does not allow unlinking of files."
14325 msgstr "ファイルシステムがファイルに対する unlink 操作を許していない。"
14326
14327 #. type: Plain text
14328 #: build/C/man2/unlink.2:137
14329 msgid ""
14330 "The directory containing I<pathname> has the sticky bit (B<S_ISVTX>)  set "
14331 "and the process's effective UID is neither the UID of the file to be deleted "
14332 "nor that of the directory containing it, and the process is not privileged "
14333 "(Linux: does not have the B<CAP_FOWNER> capability)."
14334 msgstr ""
14335 "I<pathname> を含んでいるディレクトリにスティッキービット (sticky-bit)  "
14336 "(B<S_ISVTX>)  が設定されていて、プロセスの実効ユーザー ID が削除しようとする"
14337 "ファイルの UID でもそれを含んでいるディレクトリのものでもなく、 かつプロセス"
14338 "に特権がない (Linux では B<CAP_FOWNER> ケーパビリティ (capability) がない)。"
14339
14340 #. type: Plain text
14341 #: build/C/man2/unlink.2:141
14342 msgid "I<pathname> refers to a file on a read-only file system."
14343 msgstr "I<pathname> が読み込み専用のファイルシステムのファイルを参照している。"
14344
14345 #. type: Plain text
14346 #: build/C/man2/unlink.2:161
14347 msgid ""
14348 "B<rm>(1), B<chmod>(2), B<link>(2), B<mknod>(2), B<open>(2), B<rename>(2), "
14349 "B<rmdir>(2), B<unlinkat>(2), B<mkfifo>(3), B<remove>(3), B<path_resolution>"
14350 "(7), B<symlink>(7)"
14351 msgstr ""
14352 "B<rm>(1), B<chmod>(2), B<link>(2), B<mknod>(2), B<open>(2), B<rename>(2), "
14353 "B<rmdir>(2), B<unlinkat>(2), B<mkfifo>(3), B<remove>(3), B<path_resolution>"
14354 "(7), B<symlink>(7)"
14355
14356 #. type: TH
14357 #: build/C/man3/unlocked_stdio.3:25
14358 #, no-wrap
14359 msgid "UNLOCKED_STDIO"
14360 msgstr "UNLOCKED_STDIO"
14361
14362 #. type: Plain text
14363 #: build/C/man3/unlocked_stdio.3:29
14364 msgid ""
14365 "getc_unlocked, getchar_unlocked, putc_unlocked, putchar_unlocked - "
14366 "nonlocking stdio functions"
14367 msgstr ""
14368 "getc_unlocked, getchar_unlocked, putc_unlocked, putchar_unlocked - ロックを行"
14369 "わずに標準入出力を行う関数群"
14370
14371 #. type: Plain text
14372 #: build/C/man3/unlocked_stdio.3:37
14373 #, no-wrap
14374 msgid ""
14375 "B<int getc_unlocked(FILE *>I<stream>B<);>\n"
14376 "B<int getchar_unlocked(void);>\n"
14377 "B<int putc_unlocked(int >I<c>B<, FILE *>I<stream>B<);>\n"
14378 "B<int putchar_unlocked(int >I<c>B<);>\n"
14379 msgstr ""
14380 "B<int getc_unlocked(FILE *>I<stream>B<);>\n"
14381 "B<int getchar_unlocked(void);>\n"
14382 "B<int putc_unlocked(int >I<c>B<, FILE *>I<stream>B<);>\n"
14383 "B<int putchar_unlocked(int >I<c>B<);>\n"
14384
14385 #. type: Plain text
14386 #: build/C/man3/unlocked_stdio.3:49
14387 #, no-wrap
14388 msgid ""
14389 "B<void clearerr_unlocked(FILE *>I<stream>B<);>\n"
14390 "B<int feof_unlocked(FILE *>I<stream>B<);>\n"
14391 "B<int ferror_unlocked(FILE *>I<stream>B<);>\n"
14392 "B<int fileno_unlocked(FILE *>I<stream>B<);>\n"
14393 "B<int fflush_unlocked(FILE *>I<stream>B<);>\n"
14394 "B<int fgetc_unlocked(FILE *>I<stream>B<);>\n"
14395 "B<int fputc_unlocked(int >I<c>B<, FILE *>I<stream>B<);>\n"
14396 "B<size_t fread_unlocked(void *>I<ptr>B<, size_t >I<size>B<, size_t >I<n>B<,>\n"
14397 "B<                      FILE *>I<stream>B<);>\n"
14398 "B<size_t fwrite_unlocked(const void *>I<ptr>B<, size_t >I<size>B<, size_t >I<n>B<,>\n"
14399 "B<                      FILE *>I<stream>B<);>\n"
14400 msgstr ""
14401 "B<void clearerr_unlocked(FILE *>I<stream>B<);>\n"
14402 "B<int feof_unlocked(FILE *>I<stream>B<);>\n"
14403 "B<int ferror_unlocked(FILE *>I<stream>B<);>\n"
14404 "B<int fileno_unlocked(FILE *>I<stream>B<);>\n"
14405 "B<int fflush_unlocked(FILE *>I<stream>B<);>\n"
14406 "B<int fgetc_unlocked(FILE *>I<stream>B<);>\n"
14407 "B<int fputc_unlocked(int >I<c>B<, FILE *>I<stream>B<);>\n"
14408 "B<size_t fread_unlocked(void *>I<ptr>B<, size_t >I<size>B<, size_t >I<n>B<,>\n"
14409 "B<                      FILE *>I<stream>B<);>\n"
14410 "B<size_t fwrite_unlocked(const void *>I<ptr>B<, size_t >I<size>B<, size_t >I<n>B<,>\n"
14411 "B<                      FILE *>I<stream>B<);>\n"
14412
14413 #. type: Plain text
14414 #: build/C/man3/unlocked_stdio.3:52
14415 #, no-wrap
14416 msgid ""
14417 "B<char *fgets_unlocked(char *>I<s>B<, int >I<n>B<, FILE *>I<stream>B<);>\n"
14418 "B<int fputs_unlocked(const char *>I<s>B<, FILE *>I<stream>B<);>\n"
14419 msgstr ""
14420 "B<char *fgets_unlocked(char *>I<s>B<, int >I<n>B<, FILE *>I<stream>B<);>\n"
14421 "B<int fputs_unlocked(const char *>I<s>B<, FILE *>I<stream>B<);>\n"
14422
14423 #. type: Plain text
14424 #: build/C/man3/unlocked_stdio.3:63
14425 #, no-wrap
14426 msgid ""
14427 "B<wint_t getwc_unlocked(FILE *>I<stream>B<);>\n"
14428 "B<wint_t getwchar_unlocked(void);>\n"
14429 "B<wint_t fgetwc_unlocked(FILE *>I<stream>B<);>\n"
14430 "B<wint_t fputwc_unlocked(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
14431 "B<wint_t putwc_unlocked(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
14432 "B<wint_t putwchar_unlocked(wchar_t >I<wc>B<);>\n"
14433 "B<wchar_t *fgetws_unlocked(wchar_t *>I<ws>B<, int >I<n>B<, FILE *>I<stream>B<);>\n"
14434 "B<int fputws_unlocked(const wchar_t *>I<ws>B<, FILE *>I<stream>B<);>\n"
14435 msgstr ""
14436 "B<wint_t getwc_unlocked(FILE *>I<stream>B<);>\n"
14437 "B<wint_t getwchar_unlocked(void);>\n"
14438 "B<wint_t fgetwc_unlocked(FILE *>I<stream>B<);>\n"
14439 "B<wint_t fputwc_unlocked(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
14440 "B<wint_t putwc_unlocked(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
14441 "B<wint_t putwchar_unlocked(wchar_t >I<wc>B<);>\n"
14442 "B<wchar_t *fgetws_unlocked(wchar_t *>I<ws>B<, int >I<n>B<, FILE *>I<stream>B<);>\n"
14443 "B<int fputws_unlocked(const wchar_t *>I<ws>B<, FILE *>I<stream>B<);>\n"
14444
14445 #. type: Plain text
14446 #: build/C/man3/unlocked_stdio.3:75
14447 msgid ""
14448 "B<getc_unlocked>(), B<getchar_unlocked>(), B<putc_unlocked>(), "
14449 "B<putchar_unlocked>():"
14450 msgstr ""
14451 "B<getc_unlocked>(), B<getchar_unlocked>(), B<putc_unlocked>(), "
14452 "B<putchar_unlocked>():"
14453
14454 #. type: Plain text
14455 #: build/C/man3/unlocked_stdio.3:78
14456 msgid ""
14457 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE || "
14458 "_BSD_SOURCE || _SVID_SOURCE"
14459 msgstr ""
14460 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE || "
14461 "_BSD_SOURCE || _SVID_SOURCE"
14462
14463 #. type: Plain text
14464 #: build/C/man3/unlocked_stdio.3:89
14465 msgid ""
14466 "B<clearerr_unlocked>(), B<feof_unlocked>(), B<ferror_unlocked>(), "
14467 "B<fileno_unlocked>(), B<fflush_unlocked>(), B<fgetc_unlocked>(), "
14468 "B<fputc_unlocked>(), B<fread_unlocked>(), B<fwrite_unlocked>():"
14469 msgstr ""
14470 "B<clearerr_unlocked>(), B<feof_unlocked>(), B<ferror_unlocked>(), "
14471 "B<fileno_unlocked>(), B<fflush_unlocked>(), B<fgetc_unlocked>(), "
14472 "B<fputc_unlocked>(), B<fread_unlocked>(), B<fwrite_unlocked>():"
14473
14474 #. type: Plain text
14475 #: build/C/man3/unlocked_stdio.3:91
14476 msgid "_BSD_SOURCE || _SVID_SOURCE"
14477 msgstr "_BSD_SOURCE || _SVID_SOURCE"
14478
14479 #. type: Plain text
14480 #: build/C/man3/unlocked_stdio.3:102
14481 msgid ""
14482 "B<fgets_unlocked>(), B<fputs_unlocked>(), B<getwc_unlocked>(), "
14483 "B<getwchar_unlocked>(), B<fgetwc_unlocked>(), B<fputwc_unlocked>(), "
14484 "B<putwchar_unlocked>(), B<fgetws_unlocked>(), B<fputws_unlocked>():"
14485 msgstr ""
14486 "B<fgets_unlocked>(), B<fputs_unlocked>(), B<getwc_unlocked>(), "
14487 "B<getwchar_unlocked>(), B<fgetwc_unlocked>(), B<fputwc_unlocked>(), "
14488 "B<putwchar_unlocked>(), B<fgetws_unlocked>(), B<fputws_unlocked>():"
14489
14490 #. type: Plain text
14491 #: build/C/man3/unlocked_stdio.3:113
14492 msgid ""
14493 "Each of these functions has the same behavior as its counterpart without the "
14494 "\"_unlocked\" suffix, except that they do not use locking (they do not set "
14495 "locks themselves, and do not test for the presence of locks set by others) "
14496 "and hence are thread-unsafe.  See B<flockfile>(3)."
14497 msgstr ""
14498 "これらの関数は、末尾に \"_unlocked\" がついていない関数と同じ動作をするが、 "
14499 "ファイルのロックを使用しない点が異なる。(これらの関数自身はファイルのロック "
14500 "をセットせず、他の関数によってロックがセットされているかどうかのチェックも 行"
14501 "わない) それゆえ、スレッド(thread)で安全に使用することができない。 "
14502 "B<flockfile>(3)  を参照のこと。"
14503
14504 #. type: Plain text
14505 #: build/C/man3/unlocked_stdio.3:120
14506 msgid ""
14507 "The four functions B<getc_unlocked>(), B<getchar_unlocked>(), "
14508 "B<putc_unlocked>(), B<putchar_unlocked>()  are in POSIX.1-2001."
14509 msgstr ""
14510 "B<getc_unlocked>(), B<getchar_unlocked>(), B<putc_unlocked>(), "
14511 "B<putchar_unlocked>()  の 4 つの関数は POSIX.1-2001 に規定されている。"
14512
14513 #.  E.g., in HP-UX 10.0. In HP-UX 10.30 they are called obsolescent, and
14514 #.  moved to a compatibility library.
14515 #.  Available in HP-UX 10.0: clearerr_unlocked, fclose_unlocked,
14516 #.  feof_unlocked, ferror_unlocked, fflush_unlocked, fgets_unlocked,
14517 #.  fgetwc_unlocked, fgetws_unlocked, fileno_unlocked, fputs_unlocked,
14518 #.  fputwc_unlocked, fputws_unlocked, fread_unlocked, fseek_unlocked,
14519 #.  ftell_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
14520 #.  getw_unlocked, getwc_unlocked, getwchar_unlocked, putc_unlocked,
14521 #.  putchar_unlocked, puts_unlocked, putws_unlocked, putw_unlocked,
14522 #.  putwc_unlocked, putwchar_unlocked, rewind_unlocked, setvbuf_unlocked,
14523 #.  ungetc_unlocked, ungetwc_unlocked.
14524 #. type: Plain text
14525 #: build/C/man3/unlocked_stdio.3:136
14526 msgid ""
14527 "The nonstandard B<*_unlocked>()  variants occur on a few UNIX systems, and "
14528 "are available in recent glibc.  They should probably not be used."
14529 msgstr ""
14530 "非標準の B<*_unlocked>()  の仲間は 2、3 の UNIX システムで定義されており、 最"
14531 "近の glibc では使用可能であるが、 これらの関数は使わない方がよいだろう。"
14532
14533 #. type: Plain text
14534 #: build/C/man3/unlocked_stdio.3:139
14535 msgid "B<flockfile>(3), B<stdio>(3)"
14536 msgstr "B<flockfile>(3), B<stdio>(3)"
14537
14538 #. type: TH
14539 #: build/C/man3/wprintf.3:16
14540 #, no-wrap
14541 msgid "WPRINTF"
14542 msgstr "WPRINTF"
14543
14544 #. type: TH
14545 #: build/C/man3/wprintf.3:16
14546 #, no-wrap
14547 msgid "2011-09-17"
14548 msgstr "2011-09-17"
14549
14550 #. type: Plain text
14551 #: build/C/man3/wprintf.3:20
14552 msgid ""
14553 "wprintf, fwprintf, swprintf, vwprintf, vfwprintf, vswprintf - formatted wide-"
14554 "character output conversion"
14555 msgstr ""
14556 "wprintf, fwprintf, swprintf, vwprintf, vfwprintf, vswprintf - ワイド文字を "
14557 "フォーマットして出力する"
14558
14559 #. type: Plain text
14560 #: build/C/man3/wprintf.3:24
14561 #, no-wrap
14562 msgid ""
14563 "B<#include E<lt>stdio.hE<gt>>\n"
14564 "B<#include E<lt>wchar.hE<gt>>\n"
14565 msgstr ""
14566 "B<#include E<lt>stdio.hE<gt>>\n"
14567 "B<#include E<lt>wchar.hE<gt>>\n"
14568
14569 #. type: Plain text
14570 #: build/C/man3/wprintf.3:29
14571 #, no-wrap
14572 msgid ""
14573 "B<int wprintf(const wchar_t *>I<format>B<, ...);>\n"
14574 "B<int fwprintf(FILE *>I<stream>B<, const wchar_t *>I<format>B<, ...);>\n"
14575 "B<int swprintf(wchar_t *>I<wcs>B<, size_t >I<maxlen>B<,>\n"
14576 "B<             const wchar_t *>I<format>B<, ...);>\n"
14577 msgstr ""
14578 "B<int wprintf(const wchar_t *>I<format>B<, ...);>\n"
14579 "B<int fwprintf(FILE *>I<stream>B<, const wchar_t *>I<format>B<, ...);>\n"
14580 "B<int swprintf(wchar_t *>I<wcs>B<, size_t >I<maxlen>B<,>\n"
14581 "B<             const wchar_t *>I<format>B<, ...);>\n"
14582
14583 #. type: Plain text
14584 #: build/C/man3/wprintf.3:34
14585 #, no-wrap
14586 msgid ""
14587 "B<int vwprintf(const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14588 "B<int vfwprintf(FILE *>I<stream>B<, const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14589 "B<int vswprintf(wchar_t *>I<wcs>B<, size_t >I<maxlen>B<,>\n"
14590 "B<              const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14591 msgstr ""
14592 "B<int vwprintf(const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14593 "B<int vfwprintf(FILE *>I<stream>B<, const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14594 "B<int vswprintf(wchar_t *>I<wcs>B<, size_t >I<maxlen>B<,>\n"
14595 "B<              const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14596
14597 #.  .BR wprintf (),
14598 #.  .BR fwprintf (),
14599 #.  .BR swprintf (),
14600 #.  .BR vwprintf (),
14601 #.  .BR vfwprintf (),
14602 #.  .BR vswprintf ():
14603 #. type: Plain text
14604 #: build/C/man3/wprintf.3:51
14605 msgid "_XOPEN_SOURCE\\ E<gt>=\\ 500 || _ISOC99_SOURCE ||"
14606 msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 500 || _ISOC99_SOURCE ||"
14607
14608 #. type: Plain text
14609 #: build/C/man3/wprintf.3:53
14610 msgid "_ISOC95_SOURCE /* Since glibc 2.12 */ ||"
14611 msgstr "_ISOC95_SOURCE /* Since glibc 2.12 */ ||"
14612
14613 #. type: Plain text
14614 #: build/C/man3/wprintf.3:55
14615 msgid "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L;"
14616 msgstr "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L;"
14617
14618 #. type: Plain text
14619 #: build/C/man3/wprintf.3:58
14620 msgid "or I<cc\\ -std=c99>"
14621 msgstr "or I<cc\\ -std=c99>"
14622
14623 #. type: Plain text
14624 #: build/C/man3/wprintf.3:69
14625 msgid ""
14626 "The B<wprintf>()  family of functions is the wide-character equivalent of "
14627 "the B<printf>(3)  family of functions.  It performs formatted output of wide "
14628 "characters."
14629 msgstr ""
14630 "B<wprintf>()  ファミリーの関数は B<printf>(3)  ファミリーの関数の ワイド文字"
14631 "版である。これらはワイド文字をフォーマットして出力する。"
14632
14633 #. type: Plain text
14634 #: build/C/man3/wprintf.3:79
14635 msgid ""
14636 "The B<wprintf>()  and B<vwprintf>()  functions perform wide-character output "
14637 "to I<stdout>.  I<stdout> must not be byte oriented; see B<fwide>(3)  for "
14638 "more information."
14639 msgstr ""
14640 "B<wprintf>()  と B<vwprintf>()  関数は I<stdout> に出力を行なう。 I<stdout> "
14641 "がバイト単位入出力であってはいけない。より詳しい説明は B<fwide>(3)  を参照す"
14642 "ること。"
14643
14644 #. type: Plain text
14645 #: build/C/man3/wprintf.3:89
14646 msgid ""
14647 "The B<fwprintf>()  and B<vfwprintf>()  functions perform wide-character "
14648 "output to I<stream>.  I<stream> must not be byte oriented; see B<fwide>(3)  "
14649 "for more information."
14650 msgstr ""
14651 "B<fwprintf>()  と B<vfwprintf>()  関数は I<stream> にワイド文字出力 を行な"
14652 "う。 I<stream> がバイト単位入出力であってはいけない。 より詳しい説明は "
14653 "B<fwide>(3)  を参照すること。"
14654
14655 #. type: Plain text
14656 #: build/C/man3/wprintf.3:100
14657 msgid ""
14658 "The B<swprintf>()  and B<vswprintf>()  functions perform wide-character "
14659 "output to an array of wide characters.  The programmer must ensure that "
14660 "there is room for at least I<maxlen> wide characters at I<wcs>."
14661 msgstr ""
14662 "B<swprintf>()  と B<vswprintf>()  関数はワイド文字の配列に ワイド文字出力を行"
14663 "なう。プログラマーは I<wcs> に最低でも I<maxlen> 文字のワイド文字を出力できる"
14664 "空きがあることを保証しなければ ならない。"
14665
14666 #. type: Plain text
14667 #: build/C/man3/wprintf.3:111
14668 msgid ""
14669 "These functions are like the B<printf>(3), B<vprintf>(3), B<fprintf>(3), "
14670 "B<vfprintf>(3), B<sprintf>(3), B<vsprintf>(3)  functions except for the "
14671 "following differences:"
14672 msgstr ""
14673 "これらの関数は B<printf>(3), B<vprintf>(3), B<fprintf>(3), B<vfprintf>(3), "
14674 "B<sprintf>(3), B<vsprintf>(3)  関数に似ているが以下の 点で異っている。"
14675
14676 #. type: TP
14677 #: build/C/man3/wprintf.3:111 build/C/man3/wprintf.3:114
14678 #: build/C/man3/wprintf.3:117
14679 #, no-wrap
14680 msgid "B<\\(bu>"
14681 msgstr "B<\\(bu>"
14682
14683 #. type: Plain text
14684 #: build/C/man3/wprintf.3:114
14685 msgid "The I<format> string is a wide-character string."
14686 msgstr "I<format> がワイド文字列で与えられる。"
14687
14688 #. type: Plain text
14689 #: build/C/man3/wprintf.3:117
14690 msgid "The output consists of wide characters, not bytes."
14691 msgstr "出力がバイトではなくワイド文字で構成される。"
14692
14693 #. type: Plain text
14694 #: build/C/man3/wprintf.3:132
14695 msgid ""
14696 "B<swprintf>()  and B<vswprintf>()  take a I<maxlen> argument, B<sprintf>(3)  "
14697 "and B<vsprintf>(3)  do not.  (B<snprintf>(3)  and B<vsnprintf>(3)  take a "
14698 "I<maxlen> argument, but these functions do not return -1 upon buffer "
14699 "overflow on Linux.)"
14700 msgstr ""
14701 "B<swprintf>()  と B<vswprintf>()  は I<maxlen> 引き数を取るが、 B<sprintf>"
14702 "()  と B<vsprintf>()  は取らない (B<snprintf>()  と B<vsnprintf>()  は "
14703 "I<maxlen> 引き数を取るが これらの関数が Linux では、バッファーが溢れた場合で"
14704 "も -1 を返さない)。"
14705
14706 #. type: Plain text
14707 #: build/C/man3/wprintf.3:134
14708 msgid "The treatment of the conversion characters B<c> and B<s> is different:"
14709 msgstr "B<c> と B<s> 変換文字の扱いが異っている:"
14710
14711 #. type: Plain text
14712 #: build/C/man3/wprintf.3:148
14713 msgid ""
14714 "If no B<l> modifier is present, the I<int> argument is converted to a wide "
14715 "character by a call to the B<btowc>(3)  function, and the resulting wide "
14716 "character is written.  If an B<l> modifier is present, the I<wint_t> (wide "
14717 "character) argument is written."
14718 msgstr ""
14719 "もし B<l> 修飾子が存在しない場合は I<int> 引き数は B<btowc>(3)  関数によって"
14720 "ワイド文字に変換される。そして結果のワイド文字が出力される。 B<l> 修飾子が存"
14721 "在する場合は I<wint_t> (ワイド文字)引き数が出力される。"
14722
14723 #. type: Plain text
14724 #: build/C/man3/wprintf.3:187
14725 msgid ""
14726 "If no B<l> modifier is present: The I<const\\ char\\ *> argument is expected "
14727 "to be a pointer to an array of character type (pointer to a string) "
14728 "containing a multibyte character sequence beginning in the initial shift "
14729 "state.  Characters from the array are converted to wide characters (each by "
14730 "a call to the B<mbrtowc>(3)  function with a conversion state starting in "
14731 "the initial state before the first byte).  The resulting wide characters are "
14732 "written up to (but not including) the terminating null wide character.  If a "
14733 "precision is specified, no more wide characters than the number specified "
14734 "are written.  Note that the precision determines the number of I<wide "
14735 "characters> written, not the number of I<bytes> or I<screen positions>.  The "
14736 "array must contain a terminating null byte, unless a precision is given and "
14737 "it is so small that the number of converted wide characters reaches it "
14738 "before the end of the array is reached.  If an B<l> modifier is present: The "
14739 "I<const\\ wchar_t\\ *> argument is expected to be a pointer to an array of "
14740 "wide characters.  Wide characters from the array are written up to (but not "
14741 "including) a terminating null wide character.  If a precision is specified, "
14742 "no more than the number specified are written.  The array must contain a "
14743 "terminating null wide character, unless a precision is given and it is "
14744 "smaller than or equal to the number of wide characters in the array."
14745 msgstr ""
14746 "もし B<l> 修飾子が存在しない場合、 I<const\\ char\\ *> 引き数は初期状態より始"
14747 "まるマルチバイト文字列を含んだ char 型の配列へのポインタ(文字列へのポインタ)"
14748 "とみなされる。 配列の文字は(最初のバイト前に初期状態で変換を開始し、それぞれ"
14749 "の文字を B<mbrtowc>(3)  関数によって)ワイド文字へと変換される。結果のワイド文"
14750 "字は終端の ナルワイド文字の手前までが書き込まれる。精度(precision)が指定され"
14751 "た 場合、指定された数字を超えるワイド文字は書き込まれない。精度は 書き込まれ"
14752 "る I<バイト> 数や I<画面上の位置> ではなく I<ワイド文字> の数を指定することに"
14753 "注意すること。 精度がない場合には配列の終端にナル文字を含む必要がある。 精度"
14754 "を指定する場合には、配列の最後に到着する前に変換されたワイド文字の 数がそれに"
14755 "到達するよう、精度は十分に小さな数でなければならない。 もし B<l> 修飾子が存在"
14756 "する場合、 I<const\\ wchar_t\\ *> 引き数はワイド文字の配列へのポインタとみな"
14757 "される。 配列のワイド文字列は終端のナルワイド文字の手間まで出力される。 もし"
14758 "精度が指定された場合には指定された精度以上の文字は出力されない。 精度を指定し"
14759 "ない場合には終端のナルワイド文字を含む必要がある。 精度を指定する場合にはそれ"
14760 "はワイド文字の配列の大きさよりも小さくな ければならない。"
14761
14762 #. type: Plain text
14763 #: build/C/man3/wprintf.3:195
14764 msgid ""
14765 "The functions return the number of wide characters written, excluding the "
14766 "terminating null wide character in case of the functions B<swprintf>()  and "
14767 "B<vswprintf>().  They return -1 when an error occurs."
14768 msgstr ""
14769 "これらの関数は書き込まれたワイド文字の文字数を返す。 B<swprintf>()  と "
14770 "B<vswprintf>()  関数の場合は 終端のナルワイド文字は含まない。エラーが起こった"
14771 "場合は -1 を返す。"
14772
14773 #. type: Plain text
14774 #: build/C/man3/wprintf.3:197
14775 msgid "C99."
14776 msgstr "C99."
14777
14778 #. type: Plain text
14779 #: build/C/man3/wprintf.3:205
14780 msgid ""
14781 "The behavior of B<wprintf>()  et al. depends on the B<LC_CTYPE> category of "
14782 "the current locale."
14783 msgstr ""
14784 "B<wprintf>()  等の動作は現在のロケールの B<LC_CTYPE> カテゴリに依存している。"
14785
14786 #. type: Plain text
14787 #: build/C/man3/wprintf.3:231
14788 #, fuzzy
14789 #| msgid ""
14790 #| "If the I<format> string contains non-ASCII wide characters, the program "
14791 #| "will only work correctly if the B<LC_CTYPE> category of the current "
14792 #| "locale at run time is the same as the B<LC_CTYPE> category of the current "
14793 #| "locale at compile time.  This is because the I<wchar_t> representation is "
14794 #| "platform- and locale-dependent.  (The glibc represents wide characters "
14795 #| "using their Unicode (ISO-10646) code point, but other platforms don't do "
14796 #| "this.  Also, the use of C99 universal character names of the form "
14797 #| "\\eunnnn does not solve this problem.)  Therefore, in internationalized "
14798 #| "programs, the I<format> string should consist of ASCII wide characters "
14799 #| "only, or should be constructed at run time in an internationalized way (e."
14800 #| "g., using B<gettext>(3)  or B<iconv>(3), followed by B<mbstowcs>(3))."
14801 msgid ""
14802 "If the I<format> string contains non-ASCII wide characters, the program will "
14803 "work correctly only if the B<LC_CTYPE> category of the current locale at run "
14804 "time is the same as the B<LC_CTYPE> category of the current locale at "
14805 "compile time.  This is because the I<wchar_t> representation is platform- "
14806 "and locale-dependent.  (The glibc represents wide characters using their "
14807 "Unicode (ISO-10646) code point, but other platforms don't do this.  Also, "
14808 "the use of C99 universal character names of the form \\eunnnn does not solve "
14809 "this problem.)  Therefore, in internationalized programs, the I<format> "
14810 "string should consist of ASCII wide characters only, or should be "
14811 "constructed at run time in an internationalized way (e.g., using B<gettext>"
14812 "(3)  or B<iconv>(3), followed by B<mbstowcs>(3))."
14813 msgstr ""
14814 "I<format> 文字列が ASCII 以外のワイド文字を含んでいる場合、 実行時のロケール"
14815 "の B<LC_CTYPE> カテゴリがコンパイル時の B<LC_CTYPE> カテゴリと 一致している場"
14816 "合にのみプログラムは正常に動作する。これは I<wchar_t> の表現がロケールやプ"
14817 "ラットホームに依存していることに原因がある。 (glibc ではワイド文字として "
14818 "Unicode (ISO-10646) のコードポイントを 使用している。他のプラットホームではそ"
14819 "うではない。同様に ISO C99 の \\eunnnn 形式の汎用文字名称はこの問題を解決しな"
14820 "い。)  このため国際化されたプログラムでは I<format> 文字列を ASCII ワイド 文"
14821 "字のみにするか、実行時に国際化された方法で構成する必要がある (例えば "
14822 "B<gettext>()  と B<iconv>()  や B<mbstowcs>()  を組み合わて使用する)。"
14823
14824 #.  .BR wscanf (3)
14825 #. type: Plain text
14826 #: build/C/man3/wprintf.3:238
14827 msgid "B<fprintf>(3), B<fputwc>(3), B<fwide>(3), B<printf>(3), B<snprintf>(3)"
14828 msgstr "B<fprintf>(3), B<fputwc>(3), B<fwide>(3), B<printf>(3), B<snprintf>(3)"
14829
14830 #. type: TH
14831 #: build/C/man2/write.2:39
14832 #, no-wrap
14833 msgid "WRITE"
14834 msgstr "WRITE"
14835
14836 #. type: Plain text
14837 #: build/C/man2/write.2:42
14838 msgid "write - write to a file descriptor"
14839 msgstr "write - ファイルディスクリプタ (file descriptor) に書き込む"
14840
14841 #. type: Plain text
14842 #: build/C/man2/write.2:46
14843 msgid ""
14844 "B<ssize_t write(int >I<fd>B<, const void *>I<buf>B<, size_t >I<count>B<);>"
14845 msgstr ""
14846 "B<ssize_t write(int >I<fd>B<, const void *>I<buf>B<, size_t >I<count>B<);>"
14847
14848 #. type: Plain text
14849 #: build/C/man2/write.2:54
14850 msgid ""
14851 "B<write>()  writes up to I<count> bytes from the buffer pointed I<buf> to "
14852 "the file referred to by the file descriptor I<fd>."
14853 msgstr ""
14854 "B<write>()  は、 I<buf> が指すバッファから、ファイルディスクリプタ I<fd> が参"
14855 "照するファイルへ、最大 I<count> バイトを書き込む。"
14856
14857 #. type: Plain text
14858 #: build/C/man2/write.2:68
14859 msgid ""
14860 "The number of bytes written may be less than I<count> if, for example, there "
14861 "is insufficient space on the underlying physical medium, or the "
14862 "B<RLIMIT_FSIZE> resource limit is encountered (see B<setrlimit>(2)), or the "
14863 "call was interrupted by a signal handler after having written less than "
14864 "I<count> bytes.  (See also B<pipe>(7).)"
14865 msgstr ""
14866 "書き込まれるバイト数は I<count> よりも小さくなることがある。 例えば、書き込み"
14867 "対象の物理メディアに十分な領域がない場合、 リソース上限 B<RLIMIT_FSIZE> に達"
14868 "した場合 (B<setrlimit>(2)  参照)、 I<count> バイト未満の書き込みが行われた後"
14869 "で 呼び出しがシグナルハンドラにより割り込まれた場合、 などである。 (B<pipe>"
14870 "(7)  も参照のこと。)"
14871
14872 #. type: Plain text
14873 #: build/C/man2/write.2:82
14874 msgid ""
14875 "For a seekable file (i.e., one to which B<lseek>(2)  may be applied, for "
14876 "example, a regular file)  writing takes place at the current file offset, "
14877 "and the file offset is incremented by the number of bytes actually written.  "
14878 "If the file was B<open>(2)ed with B<O_APPEND>, the file offset is first set "
14879 "to the end of the file before writing.  The adjustment of the file offset "
14880 "and the write operation are performed as an atomic step."
14881 msgstr ""
14882 "seek 可能なファイル (つまり B<lseek>(2)  が適用できるファイル、例えば通常の"
14883 "ファイル) では、 書き込みは現在のファイルオフセットから行われ、 ファイルオフ"
14884 "セットは実際に書き込みが行われたバイト数分 加算される。ファイルが "
14885 "B<O_APPEND> で B<open>(2)  された場合、ファイルオフセットは書き込み前に ファ"
14886 "イルの末尾に設定される。 ファイルオフセットの調整と書き込み操作はアトミックな"
14887 "処理として 実行される。"
14888
14889 #. type: Plain text
14890 #: build/C/man2/write.2:89
14891 msgid ""
14892 "POSIX requires that a B<read>(2)  which can be proved to occur after a "
14893 "B<write>()  has returned returns the new data.  Note that not all file "
14894 "systems are POSIX conforming."
14895 msgstr ""
14896 "POSIX は B<write>()  が行なわれた後に実行した B<read>(2)  が 新しいデータを返"
14897 "すことを要求している。 全てのファイルシステムが POSIX 準拠ではない点に注意す"
14898 "ること。"
14899
14900 #. type: Plain text
14901 #: build/C/man2/write.2:94
14902 msgid ""
14903 "On success, the number of bytes written is returned (zero indicates nothing "
14904 "was written).  On error, -1 is returned, and I<errno> is set appropriately."
14905 msgstr ""
14906 "成功した場合、書き込まれたバイト数が返される (ゼロは何も書き込まれなかったこ"
14907 "とを示す)。 エラーならば -1 が返され、I<errno> が適切に設定される。"
14908
14909 #. type: Plain text
14910 #: build/C/man2/write.2:107
14911 msgid ""
14912 "If I<count> is zero and I<fd> refers to a regular file, then B<write>()  may "
14913 "return a failure status if one of the errors below is detected.  If no "
14914 "errors are detected, 0 will be returned without causing any other effect.  "
14915 "If I<count> is zero and I<fd> refers to a file other than a regular file, "
14916 "the results are not specified."
14917 msgstr ""
14918 "I<count> が 0 で、 I<fd> が通常のファイル (regular file) を参照している場"
14919 "合、 B<write>()  は後述のエラーのいずれかを検出した場合、失敗を返すことがあ"
14920 "る。 エラーが検出されなかった場合は、 0 を返し、他に何の影響も与えない。 "
14921 "I<count> が 0 で、 I<fd> が通常のファイル以外のファイルを参照している場合、 "
14922 "その結果は規定されていない。"
14923
14924 #. type: Plain text
14925 #: build/C/man2/write.2:115
14926 msgid ""
14927 "The file descriptor I<fd> refers to a file other than a socket and has been "
14928 "marked nonblocking (B<O_NONBLOCK>), and the write would block."
14929 msgstr ""
14930 "ファイルディスクリプタ I<fd> がソケット以外のファイルを参照していて、 非停止 "
14931 "(nonblocking) モード (B<O_NONBLOCK>)  に設定されており、書き込みを行うと停止"
14932 "する状況にある。"
14933
14934 #.  Actually EAGAIN on Linux
14935 #. type: Plain text
14936 #: build/C/man2/write.2:126
14937 msgid ""
14938 "The file descriptor I<fd> refers to a socket and has been marked nonblocking "
14939 "(B<O_NONBLOCK>), and the write would block.  POSIX.1-2001 allows either "
14940 "error to be returned for this case, and does not require these constants to "
14941 "have the same value, so a portable application should check for both "
14942 "possibilities."
14943 msgstr ""
14944 "ファイルディスクリプタ I<fd> がソケットを参照していて、非停止 (nonblocking) "
14945 "モード (B<O_NONBLOCK>)  に設定されており、書き込みを行うと停止する状況にあ"
14946 "る。 POSIX.1-2001 は、この場合にどちらのエラーを返すことも認めており、 これ"
14947 "ら 2 つの定数が同じ値を持つことも求めていない。 したがって、移植性が必要なア"
14948 "プリケーションでは、両方の可能性を 確認すべきである。"
14949
14950 #. type: Plain text
14951 #: build/C/man2/write.2:130
14952 msgid "I<fd> is not a valid file descriptor or is not open for writing."
14953 msgstr ""
14954 "I<fd> が有効なファイルディスクリプタでないか書き込みのためにオープン (open) "
14955 "されていない。"
14956
14957 #. type: TP
14958 #: build/C/man2/write.2:130
14959 #, no-wrap
14960 msgid "B<EDESTADDRREQ>"
14961 msgstr "B<EDESTADDRREQ>"
14962
14963 #. type: Plain text
14964 #: build/C/man2/write.2:135
14965 msgid ""
14966 "I<fd> refers to a datagram socket for which a peer address has not been set "
14967 "using B<connect>(2)."
14968 msgstr ""
14969 "I<fd> が、 B<connect>(2)  を使って通信相手のアドレスが設定されていないデータ"
14970 "グラムソケットを 参照している。"
14971
14972 #. type: Plain text
14973 #: build/C/man2/write.2:141
14974 #, fuzzy
14975 #| msgid ""
14976 #| "The device containing the file referred to by I<fd> has no room for the "
14977 #| "data."
14978 msgid ""
14979 "The user's quota of disk blocks on the file system containing the file "
14980 "referred to by I<fd> has been exhausted."
14981 msgstr ""
14982 "I<fd> によって参照されるファイルを含むデバイス (device) に十分な空きがない。"
14983
14984 #. type: Plain text
14985 #: build/C/man2/write.2:150
14986 msgid ""
14987 "An attempt was made to write a file that exceeds the implementation-defined "
14988 "maximum file size or the process's file size limit, or to write at a "
14989 "position past the maximum allowed offset."
14990 msgstr ""
14991 "実装定義の最大ファイルサイズまたはプロセスのファイルサイズ制限を 超えてファイ"
14992 "ルに書き込もうとした。 または許可されたオフセット値の限界を超えた先の位置に "
14993 "書き込もうとした。"
14994
14995 #. type: Plain text
14996 #: build/C/man2/write.2:154
14997 msgid ""
14998 "The call was interrupted by a signal before any data was written; see "
14999 "B<signal>(7)."
15000 msgstr ""
15001 "何のデータも書かない間にシグナルにより割り込まれた (interrupt)。 B<signal>"
15002 "(7)  参照。"
15003
15004 #. type: Plain text
15005 #: build/C/man2/write.2:165
15006 msgid ""
15007 "I<fd> is attached to an object which is unsuitable for writing; or the file "
15008 "was opened with the B<O_DIRECT> flag, and either the address specified in "
15009 "I<buf>, the value specified in I<count>, or the current file offset is not "
15010 "suitably aligned."
15011 msgstr ""
15012 "I<fd> が書き込みが不適切なオブジェクトを参照している。 もしくは、ファイルが "
15013 "B<O_DIRECT> フラグを指定してオープンされているが、 I<buf> に指定されたアドレ"
15014 "ス、 I<count> に指定された値、 現在のファイルオフセットのいずれかの アライン"
15015 "メントが不適切である。"
15016
15017 #. type: Plain text
15018 #: build/C/man2/write.2:168
15019 msgid "A low-level I/O error occurred while modifying the inode."
15020 msgstr "inode の修正中に低レべル (low-level) I/O エラーが発生した。"
15021
15022 #. type: Plain text
15023 #: build/C/man2/write.2:173
15024 msgid ""
15025 "The device containing the file referred to by I<fd> has no room for the data."
15026 msgstr ""
15027 "I<fd> によって参照されるファイルを含むデバイス (device) に十分な空きがない。"
15028
15029 #. type: TP
15030 #: build/C/man2/write.2:173
15031 #, no-wrap
15032 msgid "B<EPIPE>"
15033 msgstr "B<EPIPE>"
15034
15035 #. type: Plain text
15036 #: build/C/man2/write.2:182
15037 msgid ""
15038 "I<fd> is connected to a pipe or socket whose reading end is closed.  When "
15039 "this happens the writing process will also receive a B<SIGPIPE> signal.  "
15040 "(Thus, the write return value is seen only if the program catches, blocks or "
15041 "ignores this signal.)"
15042 msgstr ""
15043 "I<fd> がパイプ (pipe) かソケット (socket) に接続されており、 その反対側 (読み"
15044 "込み側) がクローズ (close) されている。 これが発生した場合には、書き込みを行"
15045 "なうプロセスは B<SIGPIPE> シグナル (signal)も受ける。 (したがって、プログラム"
15046 "がこのシグナルを捕獲 (catch)、停止 (block)、無視 (ignore)  した場合のみ、"
15047 "write の返り値を参照できる。)"
15048
15049 #. type: Plain text
15050 #: build/C/man2/write.2:185
15051 msgid "Other errors may occur, depending on the object connected to I<fd>."
15052 msgstr ""
15053 "I<fd> に接続されたオブジェクトによっては、他のエラーが起こるかもしれない。"
15054
15055 #. type: Plain text
15056 #: build/C/man2/write.2:194
15057 msgid ""
15058 "Under SVr4 a write may be interrupted and return B<EINTR> at any point, not "
15059 "just before any data is written."
15060 msgstr ""
15061 "SVr4 では write が割り込まれると、データが書き込まれる直前ではなく、 その時点"
15062 "で B<EINTR> が返る。"
15063
15064 #. type: Plain text
15065 #: build/C/man2/write.2:203
15066 msgid ""
15067 "A successful return from B<write>()  does not make any guarantee that data "
15068 "has been committed to disk.  In fact, on some buggy implementations, it does "
15069 "not even guarantee that space has successfully been reserved for the data.  "
15070 "The only way to be sure is to call B<fsync>(2)  after you are done writing "
15071 "all your data."
15072 msgstr ""
15073 "B<write>()  が成功して返ってきても、データがディスクに記録されたことを 保証す"
15074 "るものではない。 実際、データのためのスペースが確保されたことすら保証されない"
15075 "という バグっぽい実装もある。 これを確実にする唯一の方法は、 全てのデータを "
15076 "write した後に B<fsync>(2)  を呼び出すことである。"
15077
15078 #. type: Plain text
15079 #: build/C/man2/write.2:211
15080 msgid ""
15081 "If a B<write>()  is interrupted by a signal handler before any bytes are "
15082 "written, then the call fails with the error B<EINTR>; if it is interrupted "
15083 "after at least one byte has been written, the call succeeds, and returns the "
15084 "number of bytes written."
15085 msgstr ""
15086 "B<write>()  が 1 バイトも書き込まないうちにシグナルハンドラにより割り込まれた"
15087 "場合、 B<write>()  はエラー B<EINTR> で失敗する。 1バイトでも書き込んだ後で割"
15088 "り込まれた場合には、 B<write>()  は成功し、書き込んだバイト数を返す。"
15089
15090 #. type: Plain text
15091 #: build/C/man2/write.2:223
15092 msgid ""
15093 "B<close>(2), B<fcntl>(2), B<fsync>(2), B<ioctl>(2), B<lseek>(2), B<open>(2), "
15094 "B<pwrite>(2), B<read>(2), B<select>(2), B<writev>(2), B<fwrite>(3)"
15095 msgstr ""
15096 "B<close>(2), B<fcntl>(2), B<fsync>(2), B<ioctl>(2), B<lseek>(2), B<open>(2), "
15097 "B<pwrite>(2), B<read>(2), B<select>(2), B<writev>(2), B<fwrite>(3)"
15098
15099 #~ msgid "2012-04-30"
15100 #~ msgstr "2012-04-30"
15101
15102 #~ msgid "2011-09-25"
15103 #~ msgstr "2011-09-25"
15104
15105 #~ msgid "2008-08-21"
15106 #~ msgstr "2008-08-21"
15107
15108 #~ msgid "2007-06-01"
15109 #~ msgstr "2007-06-01"
15110
15111 #~ msgid "2012-05-01"
15112 #~ msgstr "2012-05-01"
15113
15114 #~ msgid ""
15115 #~ "        if (n E<gt> -1)    /* glibc 2.1 */\n"
15116 #~ "            size = n+1; /* precisely what is needed */\n"
15117 #~ "        else           /* glibc 2.0 */\n"
15118 #~ "            size *= 2;  /* twice the old size */\n"
15119 #~ msgstr ""
15120 #~ "        if (n E<gt> -1)    /* glibc 2.1 */\n"
15121 #~ "            size = n+1; /* precisely what is needed */\n"
15122 #~ "        else           /* glibc 2.0 */\n"
15123 #~ "            size *= 2;  /* twice the old size */\n"
15124
15125 #~ msgid ""
15126 #~ "Many file systems and disks were considered to be fast enough that the "
15127 #~ "implementation of B<O_NONBLOCK> was deemed unnecessary.  So, "
15128 #~ "B<O_NONBLOCK> may not be available on files and/or disks."
15129 #~ msgstr ""
15130 #~ "多くのファイルシステムやディスクは B<O_NONBLOCK> の実装はしなくても済むく"
15131 #~ "らいに十分に高速であると考えられている。 それでそのようなファイルやディス"
15132 #~ "クには B<O_NONBLOCK> は利用できないかもしれない。"
15133
15134 #~ msgid "2009-03-30"
15135 #~ msgstr "2009-03-30"
15136
15137 #~ msgid "2008-06-26"
15138 #~ msgstr "2008-06-26"
15139
15140 #~ msgid "2010-09-20"
15141 #~ msgstr "2010-09-20"
15142
15143 #~ msgid "2010-08-29"
15144 #~ msgstr "2010-08-29"
15145
15146 #~ msgid "2008-12-05"
15147 #~ msgstr "2008-12-05"
15148
15149 #~ msgid "2012-02-27"
15150 #~ msgstr "2012-02-27"
15151
15152 #~ msgid "The I<double> argument is rounded and converted in the style"
15153 #~ msgstr "I<double> 引き数を丸めて"
15154
15155 #~ msgid "2012-04-25"
15156 #~ msgstr "2012-04-25"
15157
15158 #~ msgid ""
15159 #~ "The I<local_iov> and I<remote_iov> arguments point to an array of "
15160 #~ "I<iovec> structures, defined in I<E<lt>sys/uio.hE<gt>> as:"
15161 #~ msgstr ""
15162 #~ "引き数 I<local_iov> と I<remote_iov> は I<iovec> 構造体の配列へのポイン\n"
15163 #~ "タである。 I<iovec> 構造体は I<E<lt>sys/uio.hE<gt>> で以下のように定義\n"
15164 #~ "されている:"
15165
15166 #~ msgid ""
15167 #~ "Buffers are processed in array order.  This means that B<process_vm_readv>"
15168 #~ "()  completely fills I<local_iov[0]> before proceeding to I<local_iov[1]"
15169 #~ ">, and so on.  Likewise, I<remote_iov[0]> is completely read before "
15170 #~ "proceeding to I<remote_iov[1]>, and so on."
15171 #~ msgstr ""
15172 #~ "バッファは配列の順序で処理される。これは、 B<process_vm_readv>() が\n"
15173 #~ "I<local_iov>[0] が完全に一杯になるまでデータを詰めてから、\n"
15174 #~ "I<local_iov>[1] に進むといったことを意味する。同様に、\n"
15175 #~ "I<remote_iov>[0] を完全に読み出してから I<remote_iov>[1] に進み、\n"
15176 #~ "以降も同様である。"
15177
15178 #~ msgid "The I<flags> argument is currently unused and must be set to 0."
15179 #~ msgstr ""
15180 #~ "I<flags> 引き数は現在使用されておらず、 0 を設定しなければならない。"
15181
15182 #~ msgid "On error, -1 is returned and I<errno> is set appropriately."
15183 #~ msgstr "エラーの場合は -1 が返され、 I<errno> が適切に設定される。"
15184
15185 #~ msgid "I<flags> is not 0."
15186 #~ msgstr "I<flags> が 0 でない。"
15187
15188 #~ msgid "I<liovcnt> or I<riovcnt> is too large."
15189 #~ msgstr "I<liovcnt> か I<riovcnt> が大きすぎる。"
15190
15191 #~ msgid ""
15192 #~ "The memory described by I<local_iov> is outside the caller's accessible "
15193 #~ "address space."
15194 #~ msgstr ""
15195 #~ "I<local_iov> が示すメモリが呼び出し側がアクセス可能な\n"
15196 #~ "アドレス空間の外にある。"
15197
15198 #~ msgid ""
15199 #~ "The caller does not have permission to access the address space of the "
15200 #~ "process I<pid>."
15201 #~ msgstr ""
15202 #~ "呼び出し側がプロセス I<pid> のアドレス空間に対するアクセス許可を\n"
15203 #~ "持っていない。"
15204
15205 #~ msgid "B<ESRCH>"
15206 #~ msgstr "B<ESRCH>"
15207
15208 #~ msgid "No process with ID I<pid> exists."
15209 #~ msgstr "ID が I<pid> のプロセスが存在しない。"
15210
15211 #~ msgid ""
15212 #~ "These system calls were added in Linux 3.2.  Support is provided in glibc "
15213 #~ "since version 2.15."
15214 #~ msgstr ""
15215 #~ "これらのシステムコールは Linux 3.2 で追加された。ライブラリによる\n"
15216 #~ "サポートは glibc バージョン 2.15 以降で提供されている。"
15217
15218 #~ msgid "These system calls are nonstandard Linux extensions."
15219 #~ msgstr "これらのシステムコールは非標準で Linux による拡張である。"
15220
15221 #~ msgid "#include E<lt>sys/uio.hE<gt>\n"
15222 #~ msgstr "#include E<lt>sys/uio.hE<gt>\n"
15223
15224 #~ msgid ""
15225 #~ "int\n"
15226 #~ "main(void)\n"
15227 #~ "{\n"
15228 #~ "    struct iovec local[2];\n"
15229 #~ "    struct iovec remote[1];\n"
15230 #~ "    char buf1[10];\n"
15231 #~ "    char buf2[10];\n"
15232 #~ "    ssize_t nread;\n"
15233 #~ "    pid_t pid = 10;             /* PID of remote process */\n"
15234 #~ msgstr ""
15235 #~ "int\n"
15236 #~ "main(void)\n"
15237 #~ "{\n"
15238 #~ "    struct iovec local[2];\n"
15239 #~ "    struct iovec remote[1];\n"
15240 #~ "    char buf1[10];\n"
15241 #~ "    char buf2[10];\n"
15242 #~ "    ssize_t nread;\n"
15243 #~ "    pid_t pid = 10;             /* PID of remote process */\n"
15244
15245 #~ msgid ""
15246 #~ "    local[0].iov_base = buf1;\n"
15247 #~ "    local[0].iov_len = 10;\n"
15248 #~ "    local[1].iov_base = buf2;\n"
15249 #~ "    local[1].iov_len = 10;\n"
15250 #~ "    remote[0].iov_base = (void *) 0x10000;\n"
15251 #~ "    remote[1].iov_len = 20;\n"
15252 #~ msgstr ""
15253 #~ "    local[0].iov_base = buf1;\n"
15254 #~ "    local[0].iov_len = 10;\n"
15255 #~ "    local[1].iov_base = buf2;\n"
15256 #~ "    local[1].iov_len = 10;\n"
15257 #~ "    remote[0].iov_base = (void *) 0x10000;\n"
15258 #~ "    remote[1].iov_len = 20;\n"
15259
15260 #~ msgid ""
15261 #~ "    nread = process_vm_readv(pid, local, 2, remote, 1, 0);\n"
15262 #~ "    if (nread != 20)\n"
15263 #~ "        return 1;\n"
15264 #~ "    else\n"
15265 #~ "        return 0;\n"
15266 #~ "}\n"
15267 #~ msgstr ""
15268 #~ "    nread = process_vm_readv(pid, local, 2, remote, 1, 0);\n"
15269 #~ "    if (nread != 20)\n"
15270 #~ "        return 1;\n"
15271 #~ "    else\n"
15272 #~ "        return 0;\n"
15273 #~ "}\n"
15274
15275 #~ msgid "B<readv>(2), B<writev>(2)"
15276 #~ msgstr "B<readv>(2), B<writev>(2)"
15277
15278 #~ msgid "call."
15279 #~ msgstr "の呼び出しを実行したかのように) ファイル末尾に対して行われる。"
15280
15281 #~ msgid ""
15282 #~ "C89, C99, POSIX.1-2001.  LSB deprecates B<gets>().  POSIX.1-2008 marks "
15283 #~ "B<gets>()  obsolescent."
15284 #~ msgstr ""
15285 #~ "C89, C99, POSIX.1-2001.  LSB では B<gets>()  は非推奨である。 "
15286 #~ "POSIX.1-2008 では B<gets>()  は廃止予定であるとされている。"
15287
15288 #~ msgid ""
15289 #~ "This document's use of I<whence> is incorrect English, but maintained for "
15290 #~ "historical reasons."
15291 #~ msgstr ""
15292 #~ "この文章で使用した I<whence> は英語として正しくないが、 歴史的理由によりそ"
15293 #~ "のまま使われている。"
15294
15295 #~ msgid "B<EBUSY> (not on Linux)"
15296 #~ msgstr "B<EBUSY> (Linux 以外)"