OSDN Git Service

(split) LDP: Translate strings updated in LDP 3.52
[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-07-15 16:09+0900\n"
10 "PO-Revision-Date: 2013-07-22 05:27+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 build/C/man3/fcloseall.3:25
26 #: build/C/man3/ferror.3:44 build/C/man3/fmtmsg.3:13
27 #: build/C/man3/stdio_ext.3:25 build/C/man3/tmpnam.3:27
28 #, no-wrap
29 msgid "2013-06-21"
30 msgstr "2013-06-21"
31
32 #. type: TH
33 #: build/C/man3/asprintf.3:27 build/C/man3/ctermid.3:26
34 #: build/C/man3/dprintf.3:26 build/C/man3/fclose.3:44
35 #: build/C/man3/fcloseall.3:25 build/C/man3/fflush.3:45
36 #: build/C/man3/fgetwc.3:18 build/C/man3/fmemopen.3:10 build/C/man3/fopen.3:44
37 #: build/C/man3/fputwc.3:16 build/C/man3/fread.3:45 build/C/man3/fseek.3:42
38 #: build/C/man3/getline.3:26 build/C/man3/gets.3:27 build/C/man3/getw.3:25
39 #: build/C/man3/popen.3:40 build/C/man3/printf.3:34 build/C/man3/puts.3:26
40 #: build/C/man3/remove.3:31 build/C/man3/scanf.3:52 build/C/man3/wprintf.3:16
41 #, no-wrap
42 msgid "GNU"
43 msgstr "GNU"
44
45 #. type: TH
46 #: build/C/man3/asprintf.3:27 build/C/man3/ctermid.3:26
47 #: build/C/man3/dprintf.3:26 build/C/man3/fclose.3:44
48 #: build/C/man3/fcloseall.3:25 build/C/man3/ferror.3:44
49 #: build/C/man3/fflush.3:45 build/C/man3/fgetwc.3:18
50 #: build/C/man3/flockfile.3:25 build/C/man3/fmemopen.3:10
51 #: build/C/man3/fmtmsg.3:13 build/C/man3/fopen.3:44
52 #: build/C/man3/fopencookie.3:26 build/C/man3/fpurge.3:25
53 #: build/C/man3/fputwc.3:16 build/C/man3/fread.3:45 build/C/man3/fseek.3:42
54 #: build/C/man3/fseeko.3:25 build/C/man3/getline.3:26 build/C/man3/gets.3:27
55 #: build/C/man3/getw.3:25 build/C/man2/link.2:31 build/C/man2/llseek.2:28
56 #: build/C/man2/lseek.2:47 build/C/man3/lseek64.3:25 build/C/man2/open.2:52
57 #: build/C/man3/perror.3:31 build/C/man2/pipe.2:36 build/C/man3/popen.3:40
58 #: build/C/man3/printf.3:34 build/C/man3/puts.3:26 build/C/man2/read.2:35
59 #: build/C/man2/readlink.2:43 build/C/man2/readv.2:32 build/C/man3/remove.3:31
60 #: build/C/man2/rename.2:32 build/C/man2/rmdir.2:30 build/C/man3/scanf.3:52
61 #: build/C/man3/setbuf.3:48 build/C/man3/stdin.3:13 build/C/man3/stdio.3:39
62 #: build/C/man3/stdio_ext.3:25 build/C/man2/symlink.2:32
63 #: build/C/man7/symlink.7:36 build/C/man3/tempnam.3:25
64 #: build/C/man3/tmpfile.3:31 build/C/man3/tmpnam.3:27 build/C/man2/unlink.2:32
65 #: build/C/man3/unlocked_stdio.3:25 build/C/man3/wprintf.3:16
66 #: build/C/man2/write.2:39
67 #, no-wrap
68 msgid "Linux Programmer's Manual"
69 msgstr "Linux Programmer's Manual"
70
71 #. type: SH
72 #: build/C/man3/asprintf.3:28 build/C/man3/ctermid.3:27
73 #: build/C/man3/dprintf.3:27 build/C/man3/fclose.3:45
74 #: build/C/man3/fcloseall.3:26 build/C/man3/ferror.3:45
75 #: build/C/man3/fflush.3:46 build/C/man3/fgetwc.3:19
76 #: build/C/man3/flockfile.3:26 build/C/man3/fmemopen.3:11
77 #: build/C/man3/fmtmsg.3:14 build/C/man3/fopen.3:45
78 #: build/C/man3/fopencookie.3:27 build/C/man3/fpurge.3:26
79 #: build/C/man3/fputwc.3:17 build/C/man3/fread.3:46 build/C/man3/fseek.3:43
80 #: build/C/man3/fseeko.3:26 build/C/man3/getline.3:27 build/C/man3/gets.3:28
81 #: build/C/man3/getw.3:26 build/C/man2/link.2:32 build/C/man2/llseek.2:29
82 #: build/C/man2/lseek.2:48 build/C/man3/lseek64.3:26 build/C/man2/open.2:53
83 #: build/C/man3/perror.3:32 build/C/man2/pipe.2:37 build/C/man3/popen.3:41
84 #: build/C/man3/printf.3:35 build/C/man3/puts.3:27 build/C/man2/read.2:36
85 #: build/C/man2/readlink.2:44 build/C/man2/readv.2:33 build/C/man3/remove.3:32
86 #: build/C/man2/rename.2:33 build/C/man2/rmdir.2:31 build/C/man3/scanf.3:53
87 #: build/C/man3/setbuf.3:49 build/C/man3/stdin.3:14 build/C/man3/stdio.3:40
88 #: build/C/man3/stdio_ext.3:26 build/C/man2/symlink.2:33
89 #: build/C/man7/symlink.7:37 build/C/man3/tempnam.3:26
90 #: build/C/man3/tmpfile.3:32 build/C/man3/tmpnam.3:28 build/C/man2/unlink.2:33
91 #: build/C/man3/unlocked_stdio.3:26 build/C/man3/wprintf.3:17
92 #: build/C/man2/write.2:40
93 #, no-wrap
94 msgid "NAME"
95 msgstr "名前"
96
97 #. type: Plain text
98 #: build/C/man3/asprintf.3:30
99 msgid "asprintf, vasprintf - print to allocated string"
100 msgstr "asprintf, vasprintf - 文字列を割り当ててそれに出力する"
101
102 #. type: SH
103 #: build/C/man3/asprintf.3:30 build/C/man3/ctermid.3:29
104 #: build/C/man3/dprintf.3:29 build/C/man3/fclose.3:47
105 #: build/C/man3/fcloseall.3:28 build/C/man3/ferror.3:47
106 #: build/C/man3/fflush.3:48 build/C/man3/fgetwc.3:21
107 #: build/C/man3/flockfile.3:28 build/C/man3/fmemopen.3:13
108 #: build/C/man3/fmtmsg.3:16 build/C/man3/fopen.3:47
109 #: build/C/man3/fopencookie.3:29 build/C/man3/fpurge.3:28
110 #: build/C/man3/fputwc.3:19 build/C/man3/fread.3:48 build/C/man3/fseek.3:45
111 #: build/C/man3/fseeko.3:28 build/C/man3/getline.3:29 build/C/man3/gets.3:30
112 #: build/C/man3/getw.3:28 build/C/man2/link.2:34 build/C/man2/llseek.2:31
113 #: build/C/man2/lseek.2:50 build/C/man3/lseek64.3:28 build/C/man2/open.2:55
114 #: build/C/man3/perror.3:34 build/C/man2/pipe.2:39 build/C/man3/popen.3:43
115 #: build/C/man3/printf.3:38 build/C/man3/puts.3:29 build/C/man2/read.2:38
116 #: build/C/man2/readlink.2:46 build/C/man2/readv.2:35 build/C/man3/remove.3:34
117 #: build/C/man2/rename.2:35 build/C/man2/rmdir.2:33 build/C/man3/scanf.3:55
118 #: build/C/man3/setbuf.3:51 build/C/man3/stdin.3:16 build/C/man3/stdio.3:42
119 #: build/C/man3/stdio_ext.3:30 build/C/man2/symlink.2:35
120 #: build/C/man3/tempnam.3:28 build/C/man3/tmpfile.3:34
121 #: build/C/man3/tmpnam.3:30 build/C/man2/unlink.2:35
122 #: build/C/man3/unlocked_stdio.3:29 build/C/man3/wprintf.3:20
123 #: build/C/man2/write.2:42
124 #, no-wrap
125 msgid "SYNOPSIS"
126 msgstr "書式"
127
128 #. type: Plain text
129 #: build/C/man3/asprintf.3:32
130 msgid "B<#define _GNU_SOURCE> /* See feature_test_macros(7) */"
131 msgstr "B<#define _GNU_SOURCE> /* feature_test_macros(7) 参照 */"
132
133 #. type: Plain text
134 #: build/C/man3/asprintf.3:34 build/C/man3/dprintf.3:31
135 #: build/C/man3/fclose.3:49 build/C/man3/ferror.3:49 build/C/man3/fflush.3:50
136 #: build/C/man3/fseek.3:47 build/C/man3/perror.3:36 build/C/man3/printf.3:40
137 #: build/C/man3/remove.3:36 build/C/man2/rename.2:37 build/C/man3/stdio.3:44
138 #: build/C/man3/stdio_ext.3:32
139 msgid "B<#include E<lt>stdio.hE<gt>>"
140 msgstr "B<#include E<lt>stdio.hE<gt>>"
141
142 #. type: Plain text
143 #: build/C/man3/asprintf.3:36
144 msgid "B<int asprintf(char **>I<strp>B<, const char *>I<fmt>B<, ...);>"
145 msgstr "B<int asprintf(char **>I<strp>B<, const char *>I<fmt>B<, ...);>"
146
147 #. type: Plain text
148 #: build/C/man3/asprintf.3:38
149 msgid ""
150 "B<int vasprintf(char **>I<strp>B<, const char *>I<fmt>B<, va_list >I<ap>B<);>"
151 msgstr ""
152 "B<int vasprintf(char **>I<strp>B<, const char *>I<fmt>B<, va_list >I<ap>B<);>"
153
154 #. type: SH
155 #: build/C/man3/asprintf.3:38 build/C/man3/ctermid.3:46
156 #: build/C/man3/dprintf.3:55 build/C/man3/fclose.3:51
157 #: build/C/man3/fcloseall.3:35 build/C/man3/ferror.3:65
158 #: build/C/man3/fflush.3:52 build/C/man3/fgetwc.3:30
159 #: build/C/man3/flockfile.3:51 build/C/man3/fmemopen.3:46
160 #: build/C/man3/fmtmsg.3:26 build/C/man3/fopen.3:65
161 #: build/C/man3/fopencookie.3:37 build/C/man3/fpurge.3:42
162 #: build/C/man3/fputwc.3:28 build/C/man3/fread.3:58 build/C/man3/fseek.3:57
163 #: build/C/man3/fseeko.3:37 build/C/man3/getline.3:58 build/C/man3/gets.3:46
164 #: build/C/man3/getw.3:59 build/C/man2/link.2:38 build/C/man2/llseek.2:43
165 #: build/C/man2/lseek.2:56 build/C/man3/lseek64.3:36 build/C/man2/open.2:66
166 #: build/C/man3/perror.3:55 build/C/man2/pipe.2:51 build/C/man3/popen.3:64
167 #: build/C/man3/printf.3:76 build/C/man3/puts.3:43 build/C/man2/read.2:44
168 #: build/C/man2/readlink.2:63 build/C/man2/readv.2:58 build/C/man3/remove.3:38
169 #: build/C/man2/rename.2:39 build/C/man2/rmdir.2:37 build/C/man3/scanf.3:87
170 #: build/C/man3/setbuf.3:73 build/C/man3/stdin.3:24 build/C/man3/stdio.3:50
171 #: build/C/man3/stdio_ext.3:54 build/C/man2/symlink.2:52
172 #: build/C/man3/tempnam.3:42 build/C/man3/tmpfile.3:40
173 #: build/C/man3/tmpnam.3:36 build/C/man2/unlink.2:39
174 #: build/C/man3/unlocked_stdio.3:106 build/C/man3/wprintf.3:60
175 #: build/C/man2/write.2:46
176 #, no-wrap
177 msgid "DESCRIPTION"
178 msgstr "説明"
179
180 #. type: Plain text
181 #: build/C/man3/asprintf.3:53
182 msgid ""
183 "The functions B<asprintf>()  and B<vasprintf>()  are analogs of B<sprintf>"
184 "(3)  and B<vsprintf>(3), except that they allocate a string large enough to "
185 "hold the output including the terminating null byte (\\(aq\\e0\\(aq), and "
186 "return a pointer to it via the first argument.  This pointer should be "
187 "passed to B<free>(3)  to release the allocated storage when it is no longer "
188 "needed."
189 msgstr "B<asprintf>()  関数と B<vasprintf>()  関数とは、それぞれ B<sprintf>(3)  関数と B<vsprintf>(3)  関数とに似ているが、 出力文字列を (終端の NULL バイト (\\(aq\\e0\\(aq) も含めて)  保持するのに十分な大きさのメモリを確保し、 最初の引数にその文字列へのポインタを返す。 このポインタは、不要になったら B<free>(3)  に渡し、割り当てられた記憶領域を解放すべきである。"
190
191 #. type: SH
192 #: build/C/man3/asprintf.3:53 build/C/man3/ctermid.3:59
193 #: build/C/man3/fclose.3:59 build/C/man3/fcloseall.3:50
194 #: build/C/man3/fflush.3:74 build/C/man3/fgetwc.3:55
195 #: build/C/man3/flockfile.3:120 build/C/man3/fmemopen.3:176
196 #: build/C/man3/fmtmsg.3:152 build/C/man3/fopen.3:189
197 #: build/C/man3/fopencookie.3:238 build/C/man3/fpurge.3:58
198 #: build/C/man3/fputwc.3:54 build/C/man3/fread.3:83 build/C/man3/fseek.3:121
199 #: build/C/man3/fseeko.3:75 build/C/man3/getline.3:110 build/C/man3/gets.3:111
200 #: build/C/man3/getw.3:73 build/C/man2/link.2:52 build/C/man2/llseek.2:62
201 #: build/C/man2/lseek.2:162 build/C/man2/open.2:477 build/C/man2/pipe.2:92
202 #: build/C/man3/popen.3:123 build/C/man3/puts.3:84 build/C/man2/read.2:81
203 #: build/C/man2/readlink.2:77 build/C/man2/readv.2:177
204 #: build/C/man3/remove.3:60 build/C/man2/rename.2:91 build/C/man2/rmdir.2:40
205 #: build/C/man3/scanf.3:530 build/C/man3/setbuf.3:152
206 #: build/C/man2/symlink.2:84 build/C/man3/tempnam.3:87
207 #: build/C/man3/tmpfile.3:47 build/C/man3/tmpnam.3:70 build/C/man2/unlink.2:55
208 #: build/C/man3/wprintf.3:205 build/C/man2/write.2:89
209 #, no-wrap
210 msgid "RETURN VALUE"
211 msgstr "返り値"
212
213 #. type: Plain text
214 #: build/C/man3/asprintf.3:61
215 msgid ""
216 "When successful, these functions return the number of bytes printed, just "
217 "like B<sprintf>(3).  If memory allocation wasn't possible, or some other "
218 "error occurs, these functions will return -1, and the contents of I<strp> is "
219 "undefined."
220 msgstr ""
221 "成功すると、これらの関数は出力されたバイト数を (B<sprintf>(3)  のように) 返"
222 "す。 メモリの割り当てができなかったり、 その他エラーが生じると、 これらの関数"
223 "は -1 を返し、 I<strp> の内容は未定義となる。"
224
225 #. type: SH
226 #: build/C/man3/asprintf.3:61 build/C/man3/ctermid.3:67
227 #: build/C/man3/dprintf.3:69 build/C/man3/fclose.3:90
228 #: build/C/man3/fcloseall.3:60 build/C/man3/ferror.3:115
229 #: build/C/man3/fflush.3:93 build/C/man3/fgetwc.3:70
230 #: build/C/man3/flockfile.3:127 build/C/man3/fmemopen.3:195
231 #: build/C/man3/fmtmsg.3:237 build/C/man3/fopen.3:246
232 #: build/C/man3/fopencookie.3:245 build/C/man3/fpurge.3:70
233 #: build/C/man3/fputwc.3:68 build/C/man3/fread.3:103 build/C/man3/fseek.3:168
234 #: build/C/man3/fseeko.3:87 build/C/man3/getline.3:137 build/C/man3/gets.3:138
235 #: build/C/man3/getw.3:80 build/C/man2/link.2:138 build/C/man2/llseek.2:81
236 #: build/C/man2/lseek.2:200 build/C/man2/open.2:629 build/C/man3/perror.3:111
237 #: build/C/man2/pipe.2:118 build/C/man3/popen.3:172 build/C/man3/printf.3:806
238 #: build/C/man3/puts.3:103 build/C/man2/read.2:173 build/C/man2/readlink.2:125
239 #: build/C/man2/readv.2:214 build/C/man3/remove.3:70 build/C/man2/rename.2:232
240 #: build/C/man2/rmdir.2:127 build/C/man3/scanf.3:577 build/C/man3/setbuf.3:164
241 #: build/C/man3/stdin.3:113 build/C/man3/stdio.3:246
242 #: build/C/man2/symlink.2:149 build/C/man3/tempnam.3:98
243 #: build/C/man3/tmpfile.3:78 build/C/man3/tmpnam.3:87
244 #: build/C/man2/unlink.2:141 build/C/man3/unlocked_stdio.3:113
245 #: build/C/man3/wprintf.3:213 build/C/man2/write.2:185
246 #, no-wrap
247 msgid "CONFORMING TO"
248 msgstr "準拠"
249
250 #. type: Plain text
251 #: build/C/man3/asprintf.3:67
252 msgid ""
253 "These functions are GNU extensions, not in C or POSIX.  They are also "
254 "available under *BSD.  The FreeBSD implementation sets I<strp> to NULL on "
255 "error."
256 msgstr ""
257 "これらの関数は GNU の拡張であり、C や POSIX のものではない。 これらは *BSD で"
258 "も利用できる。 FreeBSD の実装では、エラーの際には I<strp> を NULL にセットす"
259 "る。"
260
261 #. type: SH
262 #: build/C/man3/asprintf.3:67 build/C/man3/ctermid.3:77
263 #: build/C/man3/dprintf.3:95 build/C/man3/fclose.3:102
264 #: build/C/man3/fcloseall.3:62 build/C/man3/ferror.3:122
265 #: build/C/man3/fflush.3:108 build/C/man3/fgetwc.3:87
266 #: build/C/man3/flockfile.3:135 build/C/man3/fmemopen.3:341
267 #: build/C/man3/fmtmsg.3:309 build/C/man3/fopen.3:348
268 #: build/C/man3/fopencookie.3:437 build/C/man3/fpurge.3:80
269 #: build/C/man3/fputwc.3:85 build/C/man3/fread.3:105 build/C/man3/fseek.3:170
270 #: build/C/man3/fseeko.3:93 build/C/man3/getline.3:171 build/C/man3/gets.3:173
271 #: build/C/man3/getw.3:86 build/C/man2/link.2:187 build/C/man2/llseek.2:87
272 #: build/C/man2/lseek.2:245 build/C/man3/lseek64.3:159 build/C/man2/open.2:901
273 #: build/C/man3/perror.3:139 build/C/man2/pipe.2:190 build/C/man3/popen.3:201
274 #: build/C/man3/printf.3:1080 build/C/man3/puts.3:112 build/C/man2/read.2:187
275 #: build/C/man2/readlink.2:214 build/C/man2/readv.2:284
276 #: build/C/man3/remove.3:81 build/C/man2/rename.2:245 build/C/man2/rmdir.2:132
277 #: build/C/man3/scanf.3:715 build/C/man3/setbuf.3:200 build/C/man3/stdin.3:154
278 #: build/C/man3/stdio.3:250 build/C/man3/stdio_ext.3:151
279 #: build/C/man2/symlink.2:164 build/C/man7/symlink.7:471
280 #: build/C/man3/tempnam.3:168 build/C/man3/tmpfile.3:97
281 #: build/C/man3/tmpnam.3:163 build/C/man2/unlink.2:148
282 #: build/C/man3/unlocked_stdio.3:136 build/C/man3/wprintf.3:253
283 #: build/C/man2/write.2:211
284 #, no-wrap
285 msgid "SEE ALSO"
286 msgstr "関連項目"
287
288 #. type: Plain text
289 #: build/C/man3/asprintf.3:71
290 msgid "B<free>(3), B<malloc>(3), B<printf>(3)"
291 msgstr "B<free>(3), B<malloc>(3), B<printf>(3)"
292
293 #. type: SH
294 #: build/C/man3/asprintf.3:71 build/C/man3/ctermid.3:79
295 #: build/C/man3/dprintf.3:97 build/C/man3/fclose.3:108
296 #: build/C/man3/fcloseall.3:68 build/C/man3/ferror.3:127
297 #: build/C/man3/fflush.3:116 build/C/man3/fgetwc.3:92
298 #: build/C/man3/flockfile.3:137 build/C/man3/fmemopen.3:344
299 #: build/C/man3/fmtmsg.3:312 build/C/man3/fopen.3:354
300 #: build/C/man3/fopencookie.3:442 build/C/man3/fpurge.3:85
301 #: build/C/man3/fputwc.3:89 build/C/man3/fread.3:111 build/C/man3/fseek.3:173
302 #: build/C/man3/fseeko.3:95 build/C/man3/getline.3:178 build/C/man3/gets.3:189
303 #: build/C/man3/getw.3:92 build/C/man2/link.2:197 build/C/man2/llseek.2:90
304 #: build/C/man2/lseek.2:252 build/C/man3/lseek64.3:162 build/C/man2/open.2:923
305 #: build/C/man3/perror.3:144 build/C/man2/pipe.2:197 build/C/man3/popen.3:211
306 #: build/C/man3/printf.3:1089 build/C/man3/puts.3:124 build/C/man2/read.2:200
307 #: build/C/man2/readlink.2:222 build/C/man2/readv.2:288
308 #: build/C/man3/remove.3:92 build/C/man2/rename.2:254 build/C/man2/rmdir.2:141
309 #: build/C/man3/scanf.3:722 build/C/man3/setbuf.3:208 build/C/man3/stdin.3:160
310 #: build/C/man3/stdio.3:257 build/C/man3/stdio_ext.3:154
311 #: build/C/man2/symlink.2:176 build/C/man7/symlink.7:489
312 #: build/C/man3/tempnam.3:173 build/C/man3/tmpfile.3:103
313 #: build/C/man3/tmpnam.3:168 build/C/man2/unlink.2:161
314 #: build/C/man3/unlocked_stdio.3:139 build/C/man3/wprintf.3:260
315 #: build/C/man2/write.2:223
316 #, no-wrap
317 msgid "COLOPHON"
318 msgstr "この文書について"
319
320 #. type: Plain text
321 #: build/C/man3/asprintf.3:78 build/C/man3/ctermid.3:86
322 #: build/C/man3/dprintf.3:104 build/C/man3/fclose.3:115
323 #: build/C/man3/fcloseall.3:75 build/C/man3/ferror.3:134
324 #: build/C/man3/fflush.3:123 build/C/man3/fgetwc.3:99
325 #: build/C/man3/flockfile.3:144 build/C/man3/fmemopen.3:351
326 #: build/C/man3/fmtmsg.3:319 build/C/man3/fopen.3:361
327 #: build/C/man3/fopencookie.3:449 build/C/man3/fpurge.3:92
328 #: build/C/man3/fputwc.3:96 build/C/man3/fread.3:118 build/C/man3/fseek.3:180
329 #: build/C/man3/fseeko.3:102 build/C/man3/getline.3:185
330 #: build/C/man3/gets.3:196 build/C/man3/getw.3:99 build/C/man2/link.2:204
331 #: build/C/man2/llseek.2:97 build/C/man2/lseek.2:259
332 #: build/C/man3/lseek64.3:169 build/C/man2/open.2:930
333 #: build/C/man3/perror.3:151 build/C/man2/pipe.2:204 build/C/man3/popen.3:218
334 #: build/C/man3/printf.3:1096 build/C/man3/puts.3:131 build/C/man2/read.2:207
335 #: build/C/man2/readlink.2:229 build/C/man2/readv.2:295
336 #: build/C/man3/remove.3:99 build/C/man2/rename.2:261 build/C/man2/rmdir.2:148
337 #: build/C/man3/scanf.3:729 build/C/man3/setbuf.3:215 build/C/man3/stdin.3:167
338 #: build/C/man3/stdio.3:264 build/C/man3/stdio_ext.3:161
339 #: build/C/man2/symlink.2:183 build/C/man7/symlink.7:496
340 #: build/C/man3/tempnam.3:180 build/C/man3/tmpfile.3:110
341 #: build/C/man3/tmpnam.3:175 build/C/man2/unlink.2:168
342 #: build/C/man3/unlocked_stdio.3:146 build/C/man3/wprintf.3:267
343 #: build/C/man2/write.2:230
344 msgid ""
345 "This page is part of release 3.52 of the Linux I<man-pages> project.  A "
346 "description of the project, and information about reporting bugs, can be "
347 "found at \\%http://www.kernel.org/doc/man-pages/."
348 msgstr ""
349 "この man ページは Linux I<man-pages> プロジェクトのリリース 3.52 の一部\n"
350 "である。プロジェクトの説明とバグ報告に関する情報は\n"
351 "http://www.kernel.org/doc/man-pages/ に書かれている。"
352
353 #. type: TH
354 #: build/C/man3/ctermid.3:26
355 #, no-wrap
356 msgid "CTERMID"
357 msgstr "CTERMID"
358
359 #. type: TH
360 #: build/C/man3/ctermid.3:26
361 #, no-wrap
362 msgid "2013-07-04"
363 msgstr "2013-07-04"
364
365 #. type: Plain text
366 #: build/C/man3/ctermid.3:29
367 msgid "ctermid - get controlling terminal name"
368 msgstr "ctermid - 制御端末名の取得"
369
370 #. type: Plain text
371 #: build/C/man3/ctermid.3:34 build/C/man3/fgetwc.3:24
372 #: build/C/man3/flockfile.3:31 build/C/man3/fmemopen.3:16
373 #: build/C/man3/fopen.3:50 build/C/man3/fputwc.3:22 build/C/man3/fread.3:51
374 #: build/C/man3/fseeko.3:31 build/C/man3/getline.3:32 build/C/man3/gets.3:33
375 #: build/C/man3/getw.3:31 build/C/man3/popen.3:46 build/C/man3/puts.3:32
376 #: build/C/man3/scanf.3:58 build/C/man3/setbuf.3:54 build/C/man3/stdin.3:19
377 #: build/C/man3/tempnam.3:31 build/C/man3/tmpfile.3:37
378 #: build/C/man3/tmpnam.3:33 build/C/man3/unlocked_stdio.3:32
379 #, no-wrap
380 msgid "B<#include E<lt>stdio.hE<gt>>\n"
381 msgstr "B<#include E<lt>stdio.hE<gt>>\n"
382
383 #. type: Plain text
384 #: build/C/man3/ctermid.3:36
385 #, no-wrap
386 msgid "B<char *ctermid(char *>I<s>B<);>\n"
387 msgstr "B<char *ctermid(char *>I<s>B<);>\n"
388
389 #. type: Plain text
390 #: build/C/man3/ctermid.3:41 build/C/man3/dprintf.3:39
391 #: build/C/man3/ferror.3:61 build/C/man3/flockfile.3:42
392 #: build/C/man3/fmemopen.3:29 build/C/man3/fopen.3:61
393 #: build/C/man3/getline.3:42 build/C/man3/getw.3:40 build/C/man3/perror.3:50
394 #: build/C/man3/popen.3:55 build/C/man3/printf.3:63 build/C/man2/readlink.2:54
395 #: build/C/man2/readv.2:53 build/C/man3/scanf.3:73 build/C/man3/setbuf.3:68
396 #: build/C/man2/symlink.2:43 build/C/man3/tempnam.3:38
397 #: build/C/man3/unlocked_stdio.3:68 build/C/man3/wprintf.3:39
398 msgid ""
399 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
400 msgstr "glibc 向けの機能検査マクロの要件 (B<feature_test_macros>(7)  参照):"
401
402 #.  From <unistd.h>: _XOPEN_SOURCE
403 #. type: Plain text
404 #: build/C/man3/ctermid.3:46
405 msgid ""
406 "B<ctermid>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
407 msgstr ""
408 "B<ctermid>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
409
410 #. type: Plain text
411 #: build/C/man3/ctermid.3:59
412 msgid ""
413 "B<ctermid>()  returns a string which is the pathname for the current "
414 "controlling terminal for this process.  If I<s> is NULL, a static buffer is "
415 "used, otherwise I<s> points to a buffer used to hold the terminal pathname.  "
416 "The symbolic constant B<L_ctermid> is the maximum number of characters in "
417 "the returned pathname."
418 msgstr ""
419 "B<ctermid>()  はプロセスの現在の制御端末のパス名を返す。 I<s> が NULL の場"
420 "合、静的なバッファを用いる。それ以外の場合、 I<s> は端末パス名を保持するのに"
421 "使用されるバッファへのポインタとなる。 シンボル定数 B<L_ctermid> は返されるパ"
422 "ス名の最大文字数である。"
423
424 #. type: Plain text
425 #: build/C/man3/ctermid.3:61
426 msgid "The pointer to the pathname."
427 msgstr "パス名へのポインタ。"
428
429 #. type: SH
430 #: build/C/man3/ctermid.3:61 build/C/man3/fcloseall.3:55
431 #: build/C/man3/ferror.3:106 build/C/man3/fmtmsg.3:225
432 #: build/C/man3/stdio_ext.3:132 build/C/man3/tmpnam.3:77
433 #, no-wrap
434 msgid "ATTRIBUTES"
435 msgstr "属性"
436
437 #. type: SS
438 #: build/C/man3/ctermid.3:62 build/C/man3/fcloseall.3:56
439 #: build/C/man3/ferror.3:107 build/C/man3/fmtmsg.3:226
440 #: build/C/man3/stdio_ext.3:133 build/C/man3/tmpnam.3:78
441 #, no-wrap
442 msgid "Multithreading (see pthreads(7))"
443 msgstr "マルチスレッディング (pthreads(7) 参照)"
444
445 #. type: Plain text
446 #: build/C/man3/ctermid.3:67
447 msgid ""
448 "The B<ctermid>()  function is thread-safe with exceptions.  It is not thread-"
449 "safe if called with a NULL parameter."
450 msgstr ""
451
452 #. type: Plain text
453 #: build/C/man3/ctermid.3:69
454 msgid "Svr4, POSIX.1-2001."
455 msgstr "SVr4, POSIX.1-2001."
456
457 #. type: SH
458 #: build/C/man3/ctermid.3:69 build/C/man3/fmemopen.3:213
459 #: build/C/man3/fopen.3:331 build/C/man3/gets.3:152 build/C/man3/getw.3:82
460 #: build/C/man2/link.2:181 build/C/man2/open.2:890 build/C/man3/popen.3:178
461 #: build/C/man3/printf.3:929 build/C/man3/puts.3:105 build/C/man2/readv.2:258
462 #: build/C/man3/remove.3:78 build/C/man2/rename.2:234 build/C/man2/rmdir.2:129
463 #: build/C/man3/scanf.3:646 build/C/man3/setbuf.3:170
464 #: build/C/man3/tempnam.3:158 build/C/man3/tmpnam.3:156
465 #: build/C/man2/unlink.2:145
466 #, no-wrap
467 msgid "BUGS"
468 msgstr "バグ"
469
470 #. type: Plain text
471 #: build/C/man3/ctermid.3:73
472 msgid ""
473 "The path returned may not uniquely identify the controlling terminal; it "
474 "may, for example, be I</dev/tty>."
475 msgstr ""
476 "返されたパスはたぶん制御端末を一意には特定できない。 たとえば I</dev/tty> の"
477 "ように。"
478
479 #.  in glibc 2.3.x, x >= 4, the glibc headers threw an error
480 #.  if ctermid() was given an argument; fixed in 2.4.
481 #. type: Plain text
482 #: build/C/man3/ctermid.3:77
483 msgid "It is not assured that the program can open the terminal."
484 msgstr "プログラムが端末をオープンできることは保証されていない。"
485
486 #. type: Plain text
487 #: build/C/man3/ctermid.3:79
488 msgid "B<ttyname>(3)"
489 msgstr "B<ttyname>(3)"
490
491 #. type: TH
492 #: build/C/man3/dprintf.3:26
493 #, no-wrap
494 msgid "DPRINTF"
495 msgstr "DPRINTF"
496
497 #. type: TH
498 #: build/C/man3/dprintf.3:26
499 #, no-wrap
500 msgid "2010-09-15"
501 msgstr "2010-09-15"
502
503 #. type: Plain text
504 #: build/C/man3/dprintf.3:29
505 msgid "dprintf, vdprintf - print to a file descriptor"
506 msgstr "dprintf, vdprintf - ファイルディスクリプタに文字出力する"
507
508 #. type: Plain text
509 #: build/C/man3/dprintf.3:33
510 msgid "B<int dprintf(int >I<fd>B<, const char *>I<format>B<, ...);>"
511 msgstr "B<int dprintf(int >I<fd>B<, const char *>I<format>B<, ...);>"
512
513 #. type: Plain text
514 #: build/C/man3/dprintf.3:35
515 msgid ""
516 "B<int vdprintf(int >I<fd>B<, const char *>I<format>B<, va_list >I<ap>B<);>"
517 msgstr ""
518 "B<int vdprintf(int >I<fd>B<, const char *>I<format>B<, va_list >I<ap>B<);>"
519
520 #. type: Plain text
521 #: build/C/man3/dprintf.3:43
522 msgid "B<dprintf>(), B<vdprintf>():"
523 msgstr "B<dprintf>(), B<vdprintf>():"
524
525 #. type: TP
526 #: build/C/man3/dprintf.3:46 build/C/man3/fmemopen.3:37
527 #: build/C/man3/getline.3:49
528 #, no-wrap
529 msgid "Since glibc 2.10:"
530 msgstr "glibc 2.10 以降:"
531
532 #. type: Plain text
533 #: build/C/man3/dprintf.3:49 build/C/man3/fmemopen.3:40
534 msgid "_XOPEN_SOURCE\\ E<gt>=\\ 700 || _POSIX_C_SOURCE\\ E<gt>=\\ 200809L"
535 msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 700 || _POSIX_C_SOURCE\\ E<gt>=\\ 200809L"
536
537 #. type: TP
538 #: build/C/man3/dprintf.3:49 build/C/man3/fmemopen.3:40
539 #: build/C/man3/getline.3:52
540 #, no-wrap
541 msgid "Before glibc 2.10:"
542 msgstr "glibc 2.10 より前:"
543
544 #. type: Plain text
545 #: build/C/man3/dprintf.3:52 build/C/man3/fmemopen.3:43
546 #: build/C/man3/getline.3:55 build/C/man3/unlocked_stdio.3:104
547 msgid "_GNU_SOURCE"
548 msgstr "_GNU_SOURCE"
549
550 #. type: Plain text
551 #: build/C/man3/dprintf.3:69
552 msgid ""
553 "The functions B<dprintf>()  and B<vdprintf>()  (as found in the glibc2 "
554 "library) are exact analogs of B<fprintf>(3)  and B<vfprintf>(3), except that "
555 "they output to a file descriptor I<fd> instead of to a I<stdio> stream."
556 msgstr ""
557 "(glibc2 ライブラリにおける)  B<dprintf>()  関数と B<vdprintf>()  関数とは、そ"
558 "れぞれ B<fprintf>(3)  関数と B<vfprintf>(3)  関数とにちょうど対応するが、 こ"
559 "れらは I<stdio> ストリームではなくファイルディスクリプタ I<fd> に対して出力を"
560 "行う。"
561
562 #.  .SH NOTES
563 #.  These functions are GNU extensions, not in C or POSIX.
564 #.  Clearly, the names were badly chosen.
565 #.  Many systems (like MacOS) have incompatible functions called
566 #.  .BR dprintf (),
567 #.  usually some debugging version of
568 #.  .BR printf (3),
569 #.  perhaps with a prototype like
570 #.  .BI "void dprintf(int level, const char *" format ", ...);"
571 #.  where the first argument is a debugging level (and output is to
572 #.  .IR stderr ).
573 #.  Moreover,
574 #.  .BR dprintf ()
575 #.  (or
576 #.  .BR DPRINTF )
577 #.  is also a popular macro name for a debugging printf.
578 #.  So, probably, it is better to avoid this function in programs
579 #.  intended to be portable.
580 #.  A better name would have been
581 #.  .BR fdprintf ().
582 #. type: Plain text
583 #: build/C/man3/dprintf.3:95
584 msgid ""
585 "These functions are GNU extensions that are nowadays specified in "
586 "POSIX.1-2008."
587 msgstr ""
588 "これらの関数は GNU による拡張であり、 現在では POSIX.1-2008 で規定されてい"
589 "る。"
590
591 #. type: Plain text
592 #: build/C/man3/dprintf.3:97
593 msgid "B<printf>(3)"
594 msgstr "B<printf>(3)"
595
596 #. type: TH
597 #: build/C/man3/fclose.3:44
598 #, no-wrap
599 msgid "FCLOSE"
600 msgstr "FCLOSE"
601
602 #. type: TH
603 #: build/C/man3/fclose.3:44
604 #, no-wrap
605 msgid "2009-02-23"
606 msgstr "2009-02-23"
607
608 #. type: Plain text
609 #: build/C/man3/fclose.3:47
610 msgid "fclose - close a stream"
611 msgstr "fclose - ストリームを閉じる"
612
613 #. type: Plain text
614 #: build/C/man3/fclose.3:51
615 msgid "B<int fclose(FILE *>I<fp>B<);>"
616 msgstr "B<int fclose(FILE *>I<fp>B<);>"
617
618 #. type: Plain text
619 #: build/C/man3/fclose.3:59
620 msgid ""
621 "The B<fclose>()  function flushes the stream pointed to by I<fp> (writing "
622 "any buffered output data using B<fflush>(3))  and closes the underlying file "
623 "descriptor."
624 msgstr ""
625 "B<fclose>() 関数は、 I<fp> が指すストリームを (バッファリングされて\n"
626 "いた全ての出力データを B<fflush>(3) を用いて書き込んで) フラッシュし、\n"
627 "対応するファイルディスクリプタをクローズする。"
628
629 #. type: Plain text
630 #: build/C/man3/fclose.3:70
631 msgid ""
632 "Upon successful completion 0 is returned.  Otherwise, B<EOF> is returned and "
633 "I<errno> is set to indicate the error.  In either case any further access "
634 "(including another call to B<fclose>())  to the stream results in undefined "
635 "behavior."
636 msgstr ""
637 "関数が正常に終了すると 0 が返される。 正常に終了しなかった場合には B<EOF> が"
638 "返され、 I<errno> がエラーを示すために設定される。 どちらの場合も、そのスト"
639 "リームに対する (B<fclose>()  へのさらなる呼び出しを含む) それ以上のアクセス"
640 "は 未定義の動作を生じさせる。"
641
642 #. type: SH
643 #: build/C/man3/fclose.3:70 build/C/man3/ferror.3:96 build/C/man3/fflush.3:81
644 #: build/C/man3/fgetwc.3:64 build/C/man3/flockfile.3:125
645 #: build/C/man3/fopen.3:201 build/C/man3/fpurge.3:65 build/C/man3/fputwc.3:63
646 #: build/C/man3/fseek.3:136 build/C/man3/fseeko.3:84
647 #: build/C/man3/getline.3:125 build/C/man2/link.2:57 build/C/man2/llseek.2:69
648 #: build/C/man2/lseek.2:170 build/C/man2/open.2:485 build/C/man2/pipe.2:97
649 #: build/C/man3/popen.3:146 build/C/man2/read.2:95 build/C/man2/readlink.2:85
650 #: build/C/man2/readv.2:188 build/C/man3/remove.3:65 build/C/man2/rename.2:96
651 #: build/C/man2/rmdir.2:45 build/C/man3/scanf.3:547 build/C/man2/symlink.2:89
652 #: build/C/man3/tempnam.3:94 build/C/man3/tmpfile.3:56
653 #: build/C/man3/tmpnam.3:75 build/C/man2/unlink.2:60 build/C/man2/write.2:107
654 #, no-wrap
655 msgid "ERRORS"
656 msgstr "エラー"
657
658 #. type: TP
659 #: build/C/man3/fclose.3:71 build/C/man3/fflush.3:82 build/C/man3/fpurge.3:66
660 #: build/C/man3/fseek.3:137 build/C/man2/llseek.2:70 build/C/man2/lseek.2:171
661 #: build/C/man2/read.2:114 build/C/man3/scanf.3:553 build/C/man2/write.2:126
662 #, no-wrap
663 msgid "B<EBADF>"
664 msgstr "B<EBADF>"
665
666 #.   This error cannot occur unless you are mixing ANSI C stdio operations and
667 #.   low-level file operations on the same stream. If you do get this error,
668 #.   you must have closed the stream's low-level file descriptor using
669 #.   something like close(fileno(fp)).
670 #. type: Plain text
671 #: build/C/man3/fclose.3:80
672 msgid "The file descriptor underlying I<fp> is not valid."
673 msgstr "I<fp> の基となるファイルディスクリプタが不正である。"
674
675 #. type: Plain text
676 #: build/C/man3/fclose.3:90
677 msgid ""
678 "The B<fclose>()  function may also fail and set I<errno> for any of the "
679 "errors specified for the routines B<close>(2), B<write>(2)  or B<fflush>(3)."
680 msgstr ""
681 "B<fclose>()  関数はこれ以外にも B<close>(2), B<write>(2), B<fflush>(3)  の"
682 "ルーチンで失敗することがある。その場合は I<errno> が、失敗したルーチンで設定"
683 "された値に設定される。"
684
685 #. type: Plain text
686 #: build/C/man3/fclose.3:92 build/C/man3/fseek.3:170 build/C/man3/puts.3:105
687 msgid "C89, C99."
688 msgstr "C89, C99."
689
690 #. type: SH
691 #: build/C/man3/fclose.3:92 build/C/man3/fflush.3:99 build/C/man3/fgetwc.3:72
692 #: build/C/man3/fmemopen.3:207 build/C/man3/fmtmsg.3:252
693 #: build/C/man3/fopen.3:255 build/C/man3/fpurge.3:78 build/C/man3/fputwc.3:70
694 #: build/C/man3/fseeko.3:89 build/C/man2/link.2:143 build/C/man2/llseek.2:84
695 #: build/C/man2/lseek.2:210 build/C/man2/open.2:655 build/C/man3/perror.3:124
696 #: build/C/man3/printf.3:867 build/C/man2/read.2:175
697 #: build/C/man2/readlink.2:130 build/C/man2/readv.2:226
698 #: build/C/man3/remove.3:72 build/C/man3/scanf.3:608 build/C/man3/stdin.3:122
699 #: build/C/man2/symlink.2:155 build/C/man3/tempnam.3:103
700 #: build/C/man3/tmpfile.3:80 build/C/man3/tmpnam.3:92
701 #: build/C/man3/wprintf.3:215 build/C/man2/write.2:194
702 #, no-wrap
703 msgid "NOTES"
704 msgstr "注意"
705
706 #. type: Plain text
707 #: build/C/man3/fclose.3:102
708 msgid ""
709 "Note that B<fclose>()  only flushes the user-space buffers provided by the C "
710 "library.  To ensure that the data is physically stored on disk the kernel "
711 "buffers must be flushed too, for example, with B<sync>(2)  or B<fsync>(2)."
712 msgstr ""
713 "B<fclose>()  は C ライブラリで提供されたユーザー空間バッファをフラッシュする"
714 "だけで ある点に注意すること。 データを確実に物理的にディスクに記録するために"
715 "は カーネルバッファも (B<sync>(2)  や B<fsync>(2)  を用いて) フラッシュしなけ"
716 "ればならない。"
717
718 #. type: Plain text
719 #: build/C/man3/fclose.3:108
720 msgid "B<close>(2), B<fcloseall>(3), B<fflush>(3), B<fopen>(3), B<setbuf>(3)"
721 msgstr "B<close>(2), B<fcloseall>(3), B<fflush>(3), B<fopen>(3), B<setbuf>(3)"
722
723 #. type: TH
724 #: build/C/man3/fcloseall.3:25
725 #, no-wrap
726 msgid "FCLOSEALL"
727 msgstr "FCLOSEALL"
728
729 #. type: Plain text
730 #: build/C/man3/fcloseall.3:28
731 msgid "fcloseall - close all open streams"
732 msgstr "fcloseall - 開いているすべてのストリームを閉じる"
733
734 #. type: Plain text
735 #: build/C/man3/fcloseall.3:32 build/C/man3/fopencookie.3:33
736 #, no-wrap
737 msgid ""
738 "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
739 "B<#include E<lt>stdio.hE<gt>>\n"
740 msgstr ""
741 "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
742 "B<#include E<lt>stdio.hE<gt>>\n"
743
744 #. type: Plain text
745 #: build/C/man3/fcloseall.3:34
746 #, no-wrap
747 msgid "B<int fcloseall(void);>\n"
748 msgstr "B<int fcloseall(void);>\n"
749
750 #. type: Plain text
751 #: build/C/man3/fcloseall.3:43
752 msgid ""
753 "The B<fcloseall>()  function closes all of the calling process's open "
754 "streams.  Buffered output for each stream is written before it is closed (as "
755 "for B<fflush>(3)); buffered input is discarded."
756 msgstr ""
757 "B<fcloseall>()  関数は、呼び出し元プロセスが開いているすべてのストリームを閉"
758 "じる。 ストリームを閉じる前に、 (B<fflush>(3)  と同じように) 各ストリームの"
759 "バッファに溜っている出力データは書き出される。 入力バッファ内のデータは破棄さ"
760 "れる。"
761
762 #. type: Plain text
763 #: build/C/man3/fcloseall.3:50
764 msgid ""
765 "The standard streams, I<stdin>, I<stdout>, and I<stderr> are also closed."
766 msgstr "標準入出力 I<stdin>, I<stdout>, I<stderr> も閉じられる。"
767
768 #. type: Plain text
769 #: build/C/man3/fcloseall.3:55
770 msgid ""
771 "This function returns 0 if all files were successfully closed; on error, "
772 "B<EOF> is returned."
773 msgstr ""
774 "この関数は、すべてのファイルが正常に閉じられた場合 0 を返す。 エラーの場合、 "
775 "B<EOF> を返す。"
776
777 #. type: Plain text
778 #: build/C/man3/fcloseall.3:60
779 msgid ""
780 "The B<fcloseall>()  function does not lock the streams, so it is not thread-"
781 "safe."
782 msgstr "B<fcloseall>() 関数はストリームのロックを行わない。そのため、スレッドセーフではない。"
783
784 #. type: Plain text
785 #: build/C/man3/fcloseall.3:62
786 msgid "This function is a GNU extension."
787 msgstr "この関数は GNU 拡張である。"
788
789 #. type: Plain text
790 #: build/C/man3/fcloseall.3:68
791 msgid "B<close>(2), B<fclose>(3), B<fflush>(3), B<fopen>(3), B<setbuf>(3)"
792 msgstr "B<close>(2), B<fclose>(3), B<fflush>(3), B<fopen>(3), B<setbuf>(3)"
793
794 #. type: TH
795 #: build/C/man3/ferror.3:44
796 #, no-wrap
797 msgid "FERROR"
798 msgstr "FERROR"
799
800 #. type: Plain text
801 #: build/C/man3/ferror.3:47
802 msgid "clearerr, feof, ferror, fileno - check and reset stream status"
803 msgstr ""
804 "clearerr, feof, ferror, fileno - ストリームステータスのチェックとリセット"
805
806 #. type: Plain text
807 #: build/C/man3/ferror.3:51
808 msgid "B<void clearerr(FILE *>I<stream>B<);>"
809 msgstr "B<void clearerr(FILE *>I<stream>B<);>"
810
811 #. type: Plain text
812 #: build/C/man3/ferror.3:53
813 msgid "B<int feof(FILE *>I<stream>B<);>"
814 msgstr "B<int feof(FILE *>I<stream>B<);>"
815
816 #. type: Plain text
817 #: build/C/man3/ferror.3:55
818 msgid "B<int ferror(FILE *>I<stream>B<);>"
819 msgstr "B<int ferror(FILE *>I<stream>B<);>"
820
821 #. type: Plain text
822 #: build/C/man3/ferror.3:57
823 msgid "B<int fileno(FILE *>I<stream>B<);>"
824 msgstr "B<int fileno(FILE *>I<stream>B<);>"
825
826 #. type: Plain text
827 #: build/C/man3/ferror.3:65
828 msgid ""
829 "B<fileno>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
830 msgstr ""
831 "B<fileno>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
832
833 #. type: Plain text
834 #: build/C/man3/ferror.3:70
835 msgid ""
836 "The function B<clearerr>()  clears the end-of-file and error indicators for "
837 "the stream pointed to by I<stream>."
838 msgstr ""
839 "関数 B<clearerr>()  は I<stream> で示されるストリームの EOF(end-of-file) 指示"
840 "子とエラー指示子をクリアする。"
841
842 #. type: Plain text
843 #: build/C/man3/ferror.3:78
844 msgid ""
845 "The function B<feof>()  tests the end-of-file indicator for the stream "
846 "pointed to by I<stream>, returning nonzero if it is set.  The end-of-file "
847 "indicator can be cleared only by the function B<clearerr>()."
848 msgstr ""
849 "関数 B<feof>()  は I<stream> で示されるストリームの EOF 指示子をテストし、 "
850 "セットされていれば 0 以外の数を返す。 EOF 指示子は、関数 B<clearerr>()  に"
851 "よってのみクリアすることができる。"
852
853 #. type: Plain text
854 #: build/C/man3/ferror.3:87
855 msgid ""
856 "The function B<ferror>()  tests the error indicator for the stream pointed "
857 "to by I<stream>, returning nonzero if it is set.  The error indicator can be "
858 "reset only by the B<clearerr>()  function."
859 msgstr ""
860 "関数 B<ferror>()  は I<stream> で示されるストリームのエラー指示子をテスト"
861 "し、 セットされていれば 0 以外の数を返す。 エラー指示子は、関数 B<clearerr>"
862 "()  によってのみリセットすることができる。"
863
864 #. type: Plain text
865 #: build/C/man3/ferror.3:93
866 msgid ""
867 "The function B<fileno>()  examines the argument I<stream> and returns its "
868 "integer descriptor."
869 msgstr ""
870 "関数 B<fileno>()  は、引数 I<stream> を調べ、その整数のディスクリプタを返す。"
871
872 #. type: Plain text
873 #: build/C/man3/ferror.3:96 build/C/man3/fgetwc.3:55 build/C/man3/fputwc.3:54
874 #: build/C/man3/fread.3:83 build/C/man3/gets.3:111 build/C/man3/puts.3:84
875 msgid "For nonlocking counterparts, see B<unlocked_stdio>(3)."
876 msgstr ""
877 "これらの処理を停止せずに行いたいときは、 B<unlocked_stdio>(3)  を参照のこと。"
878
879 #. type: Plain text
880 #: build/C/man3/ferror.3:106
881 msgid ""
882 "These functions should not fail and do not set the external variable "
883 "I<errno>.  (However, in case B<fileno>()  detects that its argument is not a "
884 "valid stream, it must return -1 and set I<errno> to B<EBADF>.)"
885 msgstr ""
886 "これらの関数は失敗すべきではなく、また、外部変数 I<errno> に値をセットしな"
887 "い。 (しかし、 B<fileno>()  関数の場合で、引数が有効なストリームでなかった場"
888 "合、 関数は -1 を返し、 I<errno> に B<EBADF> を設定しなければならない。)"
889
890 #. type: Plain text
891 #: build/C/man3/ferror.3:115
892 msgid ""
893 "The B<clearerr>(), B<feof>(), B<ferror>(), and B<fileno>()  functions are "
894 "thread-safe."
895 msgstr "関数 B<clearerr>(), B<feof>(), B<ferror>(), B<fileno>() はスレッドセーフである。"
896
897 #. type: Plain text
898 #: build/C/man3/ferror.3:122
899 msgid ""
900 "The functions B<clearerr>(), B<feof>(), and B<ferror>()  conform to C89 and "
901 "C99."
902 msgstr ""
903 "関数 B<clearerr>(), B<feof>(), B<ferror>()  は C89 と C99 に準拠している。"
904
905 #. type: Plain text
906 #: build/C/man3/ferror.3:127
907 msgid "B<open>(2), B<fdopen>(3), B<stdio>(3), B<unlocked_stdio>(3)"
908 msgstr "B<open>(2), B<fdopen>(3), B<stdio>(3), B<unlocked_stdio>(3)"
909
910 #. type: TH
911 #: build/C/man3/fflush.3:45
912 #, no-wrap
913 msgid "FFLUSH"
914 msgstr "FFLUSH"
915
916 #. type: TH
917 #: build/C/man3/fflush.3:45
918 #, no-wrap
919 msgid "2009-09-06"
920 msgstr "2009-09-06"
921
922 #. type: Plain text
923 #: build/C/man3/fflush.3:48
924 msgid "fflush - flush a stream"
925 msgstr "fflush - ストリームの内容を強制的に出力(フラッシュ)する"
926
927 #. type: Plain text
928 #: build/C/man3/fflush.3:52
929 msgid "B<int fflush(FILE *>I<stream>B<);>"
930 msgstr "B<int fflush(FILE *>I<stream>B<);>"
931
932 #. type: Plain text
933 #: build/C/man3/fflush.3:63
934 msgid ""
935 "For output streams, B<fflush>()  forces a write of all user-space buffered "
936 "data for the given output or update I<stream> via the stream's underlying "
937 "write function.  For input streams, B<fflush>()  discards any buffered data "
938 "that has been fetched from the underlying file, but has not been consumed by "
939 "the application.  The open status of the stream is unaffected."
940 msgstr ""
941 "出力ストリームに関しては、 B<fflush>()  は、ユーザー空間でバッファリングされ"
942 "ているすべてのデータを 指定された出力に書き出す (フラッシュする)、 もしくはス"
943 "トリーム I<stream> の下位にある書き込み関数を用いてこのストリームを更新す"
944 "る。 入力ストリームに関しては、 B<fflush>()  は、対応するファイルから取得され"
945 "たが、アプリケーションからは 読み出されていないバッファデータを全て破棄す"
946 "る。 ストリームは開いた状態のままであり、 この関数によって何の影響も受けな"
947 "い。"
948
949 #. type: Plain text
950 #: build/C/man3/fflush.3:71
951 msgid ""
952 "If the I<stream> argument is NULL, B<fflush>()  flushes I<all> open output "
953 "streams."
954 msgstr ""
955 "I<stream> 引数が .BR NULL ならば、 B<fflush>()  は開いているI<すべての>出力ス"
956 "トリームをフラッシュする。"
957
958 #. type: Plain text
959 #: build/C/man3/fflush.3:74
960 msgid "For a nonlocking counterpart, see B<unlocked_stdio>(3)."
961 msgstr ""
962 "これらの処理をロックせずに行いたいときは、 B<unlocked_stdio>(3)  を参照のこ"
963 "と。"
964
965 #. type: Plain text
966 #: build/C/man3/fflush.3:81
967 msgid ""
968 "Upon successful completion 0 is returned.  Otherwise, B<EOF> is returned and "
969 "I<errno> is set to indicate the error."
970 msgstr ""
971 "成功すると 0 が返される。 その他の場合には B<EOF> が返され、 I<errno> が、エ"
972 "ラーに対応した値に設定される。"
973
974 #. type: Plain text
975 #: build/C/man3/fflush.3:86
976 msgid "I<Stream> is not an open stream, or is not open for writing."
977 msgstr ""
978 "I<Stream> は開いているストリームではない。 あるいはストリームは書き込み用では"
979 "ない。"
980
981 #. type: Plain text
982 #: build/C/man3/fflush.3:93
983 msgid ""
984 "The function B<fflush>()  may also fail and set I<errno> for any of the "
985 "errors specified for B<write>(2)."
986 msgstr ""
987 "B<fflush>()  関数は B<write>(2)  に関して規定されているエラーで失敗することも"
988 "ある。 この場合 I<errno> もその値に設定される。"
989
990 #. type: Plain text
991 #: build/C/man3/fflush.3:95
992 msgid "C89, C99, POSIX.1-2001, POSIX.1-2008."
993 msgstr "C89, C99, POSIX.1-2001, POSIX.1-2008."
994
995 #.  Verified on: Solaris 8.
996 #. type: Plain text
997 #: build/C/man3/fflush.3:99
998 msgid ""
999 "The standards do not specify the behavior for input streams.  Most other "
1000 "implementations behave the same as Linux."
1001 msgstr ""
1002 "標準では、入力ストリームに対する動作は規定されていない。 他のほとんどの実装"
1003 "は Linux と同じ動作をする。"
1004
1005 #. type: Plain text
1006 #: build/C/man3/fflush.3:108
1007 msgid ""
1008 "Note that B<fflush>()  only flushes the user-space buffers provided by the C "
1009 "library.  To ensure that the data is physically stored on disk the kernel "
1010 "buffers must be flushed too, for example, with B<sync>(2)  or B<fsync>(2)."
1011 msgstr ""
1012 "B<fflush>()  は、 C ライブラリが与えているユーザー空間のバッファしかフラッ"
1013 "シュしない。 データが物理的にディスクに保存されることを保証したければ、 カー"
1014 "ネルバッファもフラッシュしなければならない。 これには例えば B<sync>(2)  や "
1015 "B<fsync>(2)  を用いる。"
1016
1017 #. type: Plain text
1018 #: build/C/man3/fflush.3:116
1019 msgid ""
1020 "B<fsync>(2), B<sync>(2), B<write>(2), B<fclose>(3), B<fopen>(3), B<setbuf>"
1021 "(3), B<unlocked_stdio>(3)"
1022 msgstr ""
1023 "B<fsync>(2), B<sync>(2), B<write>(2), B<fclose>(3), B<fopen>(3), B<setbuf>"
1024 "(3), B<unlocked_stdio>(3)"
1025
1026 #. type: TH
1027 #: build/C/man3/fgetwc.3:18
1028 #, no-wrap
1029 msgid "FGETWC"
1030 msgstr "FGETWC"
1031
1032 #. type: TH
1033 #: build/C/man3/fgetwc.3:18 build/C/man3/fputwc.3:16 build/C/man3/getline.3:26
1034 #: build/C/man3/popen.3:40 build/C/man3/tempnam.3:25
1035 #, no-wrap
1036 msgid "2013-04-19"
1037 msgstr "2013-04-19"
1038
1039 #. type: Plain text
1040 #: build/C/man3/fgetwc.3:21
1041 msgid "fgetwc, getwc - read a wide character from a FILE stream"
1042 msgstr "fgetwc, getwc - ワイド文字を FILE ストリームから読み込む"
1043
1044 #. type: Plain text
1045 #: build/C/man3/fgetwc.3:26 build/C/man3/fmemopen.3:22
1046 #: build/C/man3/fputwc.3:24 build/C/man3/unlocked_stdio.3:54
1047 #, no-wrap
1048 msgid "B<#include E<lt>wchar.hE<gt>>\n"
1049 msgstr "B<#include E<lt>wchar.hE<gt>>\n"
1050
1051 #. type: Plain text
1052 #: build/C/man3/fgetwc.3:29
1053 #, no-wrap
1054 msgid ""
1055 "B<wint_t fgetwc(FILE *>I<stream>B<);>\n"
1056 "B<wint_t getwc(FILE *>I<stream>B<);>\n"
1057 msgstr ""
1058 "B<wint_t fgetwc(FILE *>I<stream>B<);>\n"
1059 "B<wint_t getwc(FILE *>I<stream>B<);>\n"
1060
1061 #. type: Plain text
1062 #: build/C/man3/fgetwc.3:44
1063 msgid ""
1064 "The B<fgetwc>()  function is the wide-character equivalent of the B<fgetc>"
1065 "(3)  function.  It reads a wide character from I<stream> and returns it.  If "
1066 "the end of stream is reached, or if I<ferror(stream)> becomes true, it "
1067 "returns B<WEOF>.  If a wide-character conversion error occurs, it sets "
1068 "I<errno> to B<EILSEQ> and returns B<WEOF>."
1069 msgstr ""
1070 "B<fgetwc>()  関数は、 B<fgetc>(3)  に対応するワイド文字関数である。 この関数"
1071 "は I<stream> からワイド文字を 1 文字読み込み、これを返す。 ストリームの終端に"
1072 "達するか、I<ferror(stream)> が真になった場合には、 この関数は B<WEOF> を返"
1073 "す。 ワイド文字変換でエラーが発生した場合は、 I<errno> に B<EILSEQ> をセット"
1074 "し、 B<WEOF> を返す。"
1075
1076 #. type: Plain text
1077 #: build/C/man3/fgetwc.3:52
1078 msgid ""
1079 "The B<getwc>()  function or macro functions identically to B<fgetwc>().  It "
1080 "may be implemented as a macro, and may evaluate its argument more than "
1081 "once.  There is no reason ever to use it."
1082 msgstr ""
1083 "B<getwc>()  関数あるいはマクロは、 B<fgetwc>()  と全く同じ動作をする。 この関"
1084 "数はマクロとして実装されるかもしれないので、引き数が複数回評価さ れるかもしれ"
1085 "ない。この関数を使う理由はもはや存在しない。"
1086
1087 #. type: Plain text
1088 #: build/C/man3/fgetwc.3:64
1089 msgid ""
1090 "The B<fgetwc>()  function returns the next wide-character from the stream, "
1091 "or B<WEOF>.  In the event of an error, I<errno> is set to indicate the cause."
1092 msgstr "B<fgetwc>()  関数はストリームの次のワイド文字か、あるいは B<WEOF> を返す。 エラーが起こった場合、 I<errno> にエラーの原因を示す値が設定される。"
1093
1094 #. type: Plain text
1095 #: build/C/man3/fgetwc.3:66 build/C/man3/fputwc.3:65
1096 msgid "Apart from the usual ones, there is"
1097 msgstr "通常のエラーに加えて、以下のエラーがある:"
1098
1099 #. type: TP
1100 #: build/C/man3/fgetwc.3:66 build/C/man3/fputwc.3:65 build/C/man3/scanf.3:558
1101 #, no-wrap
1102 msgid "B<EILSEQ>"
1103 msgstr "B<EILSEQ>"
1104
1105 #. type: Plain text
1106 #: build/C/man3/fgetwc.3:70
1107 msgid ""
1108 "The data obtained from the input stream does not form a valid character."
1109 msgstr "入力ストリームから取得したデータが、正しい文字でない。"
1110
1111 #. type: Plain text
1112 #: build/C/man3/fgetwc.3:72 build/C/man3/fputwc.3:70
1113 msgid "C99, POSIX.1-2001."
1114 msgstr "C99, POSIX.1-2001."
1115
1116 #. type: Plain text
1117 #: build/C/man3/fgetwc.3:79
1118 msgid ""
1119 "The behavior of B<fgetwc>()  depends on the B<LC_CTYPE> category of the "
1120 "current locale."
1121 msgstr ""
1122 "B<fgetwc>()  の動作は、現在のロケールの B<LC_CTYPE> カテゴリに依存する。"
1123
1124 #. type: Plain text
1125 #: build/C/man3/fgetwc.3:87
1126 msgid ""
1127 "In the absence of additional information passed to the B<fopen>(3)  call, it "
1128 "is reasonable to expect that B<fgetwc>()  will actually read a multibyte "
1129 "sequence from the stream and then convert it to a wide character."
1130 msgstr ""
1131 "B<fopen>(3)  システムコールに渡す追加情報がない場合には、 B<fgetwc>()  が実"
1132 "際 にはマルチバイトシーケンスをストリームから読み込み、これをワイド文字に 変"
1133 "換すると期待することは適切である。"
1134
1135 #. type: Plain text
1136 #: build/C/man3/fgetwc.3:92
1137 msgid "B<fgetws>(3), B<fputwc>(3), B<ungetwc>(3), B<unlocked_stdio>(3)"
1138 msgstr "B<fgetws>(3), B<fputwc>(3), B<ungetwc>(3), B<unlocked_stdio>(3)"
1139
1140 #. type: TH
1141 #: build/C/man3/flockfile.3:25
1142 #, no-wrap
1143 msgid "FLOCKFILE"
1144 msgstr "FLOCKFILE"
1145
1146 #. type: TH
1147 #: build/C/man3/flockfile.3:25 build/C/man3/unlocked_stdio.3:25
1148 #, no-wrap
1149 msgid "2008-08-29"
1150 msgstr "2008-08-29"
1151
1152 #. type: Plain text
1153 #: build/C/man3/flockfile.3:28
1154 msgid "flockfile, ftrylockfile, funlockfile - lock FILE for stdio"
1155 msgstr "flockfile, ftrylockfile, funlockfile - 標準入出力 FILE のロックを行う"
1156
1157 #. type: Plain text
1158 #: build/C/man3/flockfile.3:33
1159 #, no-wrap
1160 msgid "B<void flockfile(FILE *>I<filehandle>B<);>\n"
1161 msgstr "B<void flockfile(FILE *>I<filehandle>B<);>\n"
1162
1163 #. type: Plain text
1164 #: build/C/man3/flockfile.3:35
1165 #, no-wrap
1166 msgid "B<int ftrylockfile(FILE *>I<filehandle>B<);>\n"
1167 msgstr "B<int ftrylockfile(FILE *>I<filehandle>B<);>\n"
1168
1169 #. type: Plain text
1170 #: build/C/man3/flockfile.3:37
1171 #, no-wrap
1172 msgid "B<void funlockfile(FILE *>I<filehandle>B<);>\n"
1173 msgstr "B<void funlockfile(FILE *>I<filehandle>B<);>\n"
1174
1175 #. type: Plain text
1176 #: build/C/man3/flockfile.3:46 build/C/man3/wprintf.3:43
1177 msgid "All functions shown above:"
1178 msgstr "上記の全ての関数:"
1179
1180 #. type: Plain text
1181 #: build/C/man3/flockfile.3:49
1182 msgid ""
1183 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE "
1184 "|| _POSIX_SOURCE"
1185 msgstr ""
1186 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE "
1187 "|| _POSIX_SOURCE"
1188
1189 #. type: Plain text
1190 #: build/C/man3/flockfile.3:63
1191 msgid ""
1192 "The stdio functions are thread-safe.  This is achieved by assigning to each "
1193 "I<FILE> object a lockcount and (if the lockcount is nonzero)  an owning "
1194 "thread.  For each library call, these functions wait until the I<FILE> "
1195 "object is no longer locked by a different thread, then lock it, do the "
1196 "requested I/O, and unlock the object again."
1197 msgstr ""
1198 "標準入出力関数はスレッドセーフである。これは、各 I<FILE> オブジェクトに対し、"
1199 "ロック数 (lockcount) と (ロック数が 0 でない場合は) 所有者スレッド (owner "
1200 "thread)  を管理することで実現される。 ライブラリの呼び出しが行われる毎に、標"
1201 "準入出力関数は I<FILE> オブジェクトが他のスレッドによってロックされていない状"
1202 "態になるまで待ち、 I<FILE> オブジェクトをロックし、要求されて入出力を行い、 "
1203 "オブジェクトのロックを解除する。"
1204
1205 #. type: Plain text
1206 #: build/C/man3/flockfile.3:69
1207 msgid ""
1208 "(Note: this locking has nothing to do with the file locking done by "
1209 "functions like B<flock>(2)  and B<lockf>(3).)"
1210 msgstr ""
1211 "(注: このロックは、 B<flock>(2)  や B<lockf>(3)  といった関数が行うロックとは"
1212 "全く無関係である。)"
1213
1214 #. type: Plain text
1215 #: build/C/man3/flockfile.3:77
1216 msgid ""
1217 "All this is invisible to the C-programmer, but there may be two reasons to "
1218 "wish for more detailed control.  On the one hand, maybe a series of I/O "
1219 "actions by one thread belongs together, and should not be interrupted by the "
1220 "I/O of some other thread.  On the other hand, maybe the locking overhead "
1221 "should be avoided for greater efficiency."
1222 msgstr ""
1223 "これらのことはすべて C プログラマには見えない部分で行われるが、 より細かい制"
1224 "御ができた方がよい理由が2つあるだろう。一つは、一つのスレッドが 行う一連の入"
1225 "出力動作は一緒に行われ、他のスレッドの入出力によって中断されない 方がよいとい"
1226 "うことであろう。もう一つは、効率を大きく上げるためには ロックのオーバヘッドを"
1227 "避ける必要があるということであろう。"
1228
1229 #. type: Plain text
1230 #: build/C/man3/flockfile.3:94
1231 msgid ""
1232 "To this end, a thread can explicitly lock the I<FILE> object, then do its "
1233 "series of I/O actions, then unlock.  This prevents other threads from coming "
1234 "in between.  If the reason for doing this was to achieve greater efficiency, "
1235 "one does the I/O with the nonlocking versions of the stdio functions: with "
1236 "B<getc_unlocked>(3)  and B<putc_unlocked>(3)  instead of B<getc>(3)  and "
1237 "B<putc>(3)."
1238 msgstr ""
1239 "この目的を実現するために、 I<FILE> オブジェクトのロック、一連の入出力動作の実"
1240 "行、 ロックの解除をスレッドが明示的に指示することができる。 これにより、他の"
1241 "スレッドが途中で入出力を行うのを防止する。 このようなことを行う理由が効率の向"
1242 "上であるならば、 ロックを行わないバージョンの標準入出力関数を使うこともでき"
1243 "る。 例えば、 B<getc>(3)  や B<putc>(3)  の代わりに B<getc_unlocked>(3)  や "
1244 "B<putc_unlocked>(3)  を使用する。"
1245
1246 #. type: Plain text
1247 #: build/C/man3/flockfile.3:105
1248 msgid ""
1249 "The B<flockfile>()  function waits for I<*filehandle> to be no longer locked "
1250 "by a different thread, then makes the current thread owner of "
1251 "I<*filehandle>, and increments the lockcount."
1252 msgstr ""
1253 "B<flockfile>()  関数は、I<*filehandle> が他のスレッドにロックされていな い状"
1254 "態になるまで待ったのち、現在のスレッドを I<*filehandle> のオーナに設 定し、"
1255 "ロック数を加算する。"
1256
1257 #. type: Plain text
1258 #: build/C/man3/flockfile.3:109
1259 msgid "The B<funlockfile>()  function decrements the lock count."
1260 msgstr "B<funlockfile>()  関数は、ロック数を減算する。"
1261
1262 #. type: Plain text
1263 #: build/C/man3/flockfile.3:120
1264 msgid ""
1265 "The B<ftrylockfile>()  function is a nonblocking version of B<flockfile>().  "
1266 "It does nothing in case some other thread owns I<*filehandle>, and it "
1267 "obtains ownership and increments the lockcount otherwise."
1268 msgstr ""
1269 "B<ftrylockfile>()  関数は B<flockfile>()  のブロッキングを行わない バージョン"
1270 "である。他のスレッドが I<*filehandle> をロックしている時は 何も行わず、そうで"
1271 "ない場合は I<*filehandle> の所有権を獲得し、 ロック数を加算する。"
1272
1273 #. type: Plain text
1274 #: build/C/man3/flockfile.3:125
1275 msgid ""
1276 "The B<ftrylockfile>()  function returns zero for success (the lock was "
1277 "obtained), and nonzero for failure."
1278 msgstr ""
1279 "B<ftrylockfile>()  関数はロックに成功すると 0 を返し、 失敗した場合は 0 以外"
1280 "の値を返す。"
1281
1282 #. type: Plain text
1283 #: build/C/man3/flockfile.3:127
1284 msgid "None."
1285 msgstr "なし。"
1286
1287 #. type: Plain text
1288 #: build/C/man3/flockfile.3:129 build/C/man3/popen.3:174
1289 msgid "POSIX.1-2001."
1290 msgstr "POSIX.1-2001."
1291
1292 #. type: SH
1293 #: build/C/man3/flockfile.3:129
1294 #, no-wrap
1295 msgid "AVAILABILITY"
1296 msgstr "可用性"
1297
1298 #. type: Plain text
1299 #: build/C/man3/flockfile.3:135
1300 msgid ""
1301 "These functions are available when B<_POSIX_THREAD_SAFE_FUNCTIONS> is "
1302 "defined.  They are in libc since libc 5.1.1 and in glibc since glibc 2.0."
1303 msgstr ""
1304 "B<_POSIX_THREAD_SAFE_FUNCTIONS> が定義されているときにこれらの関数を使用する"
1305 "ことができる。 5.1.1 以降の libc と 2.0 以降の glibc に存在する。"
1306
1307 #. type: Plain text
1308 #: build/C/man3/flockfile.3:137
1309 msgid "B<unlocked_stdio>(3)"
1310 msgstr "B<unlocked_stdio>(3)"
1311
1312 #. type: TH
1313 #: build/C/man3/fmemopen.3:10
1314 #, no-wrap
1315 msgid "FMEMOPEN"
1316 msgstr "FMEMOPEN"
1317
1318 #. type: TH
1319 #: build/C/man3/fmemopen.3:10
1320 #, no-wrap
1321 msgid "2012-04-28"
1322 msgstr "2012-04-28"
1323
1324 #. type: Plain text
1325 #: build/C/man3/fmemopen.3:13
1326 msgid "fmemopen, open_memstream, open_wmemstream - open memory as stream"
1327 msgstr ""
1328 "fmemopen, open_memstream, open_wmemstream - メモリをストリームとしてオープン"
1329 "する"
1330
1331 #. type: Plain text
1332 #: build/C/man3/fmemopen.3:18
1333 #, no-wrap
1334 msgid "B<FILE *fmemopen(void *>I<buf>B<, size_t >I<size>B<, const char *>I<mode>B<);>\n"
1335 msgstr "B<FILE *fmemopen(void *>I<buf>B<, size_t >I<size>B<, const char *>I<mode>B<);>\n"
1336
1337 #. type: Plain text
1338 #: build/C/man3/fmemopen.3:20
1339 #, no-wrap
1340 msgid "B<FILE *open_memstream(char **>I<ptr>B<, size_t *>I<sizeloc>B<);>\n"
1341 msgstr "B<FILE *open_memstream(char **>I<ptr>B<, size_t *>I<sizeloc>B<);>\n"
1342
1343 #. type: Plain text
1344 #: build/C/man3/fmemopen.3:24
1345 #, no-wrap
1346 msgid "B<FILE *open_wmemstream(wchar_t **>I<ptr>B<, size_t *>I<sizeloc>B<);>\n"
1347 msgstr "B<FILE *open_wmemstream(wchar_t **>I<ptr>B<, size_t *>I<sizeloc>B<);>\n"
1348
1349 #. type: Plain text
1350 #: build/C/man3/fmemopen.3:34
1351 msgid "B<fmemopen>(), B<open_memstream>(), B<open_wmemstream>():"
1352 msgstr "B<fmemopen>(), B<open_memstream>(), B<open_wmemstream>():"
1353
1354 #. type: Plain text
1355 #: build/C/man3/fmemopen.3:57
1356 msgid ""
1357 "The B<fmemopen>()  function opens a stream that permits the access specified "
1358 "by I<mode>.  The stream allows I/O to be performed on the string or memory "
1359 "buffer pointed to by I<buf>.  This buffer must be at least I<size> bytes "
1360 "long."
1361 msgstr ""
1362 "B<fmemopen>()  関数は、ストリームをオープンし、そのストリームに I<mode> で指"
1363 "定されたアクセス許可を設定する。 そのストリームを通じて、 I<buf> で指定された"
1364 "文字列やメモリバッファへの読み書きができる。 このバッファは少なくとも "
1365 "I<size> バイトの長さでなければならない。"
1366
1367 #. type: Plain text
1368 #: build/C/man3/fmemopen.3:77
1369 msgid ""
1370 "The argument I<mode> is the same as for B<fopen>(3).  If I<mode> specifies "
1371 "an append mode, then the initial file position is set to the location of the "
1372 "first null byte (\\(aq\\e0\\(aq) in the buffer; otherwise the initial file "
1373 "position is set to the start of the buffer.  Since glibc 2.9, the letter "
1374 "\\(aqb\\(aq may be specified as the second character in I<mode>.  This "
1375 "provides \"binary\" mode: writes don't implicitly add a terminating null "
1376 "byte, and B<fseek>(3)  B<SEEK_END> is relative to the end of the buffer (i."
1377 "e., the value specified by the I<size> argument), rather than the current "
1378 "string length."
1379 msgstr ""
1380 "引き数 I<mode> は B<fopen>(3) の場合と同じである。 I<mode> で追記モード\n"
1381 "(append mode) が指定された場合、ファイル位置の初期値は バッファ中の\n"
1382 "最初の NULL バイト (\\(aq\\e0\\(aq) の位置に設定される。\n"
1383 "それ以外の場合は、ファイル位置の初期値はバッファの先頭になる。 \n"
1384 "glibc 2.9 以降では、文字 \\(aqb\\(aq を I<mode> の二番目の文字として指定\n"
1385 "することができる。 この文字は「バイナリ」モードを指定するものである。\n"
1386 "このモードでは、書き込み時に文字列終端のヌルバイトが黙って追加 される\n"
1387 "ことはない。また、 B<fseek>(3) B<SEEK_END> は、文字列の長さからの相対値\n"
1388 "ではなく、バッファの末尾 (I<size> で指定した値) からの相対値となる。"
1389
1390 #. type: Plain text
1391 #: build/C/man3/fmemopen.3:89
1392 msgid ""
1393 "When a stream that has been opened for writing is flushed (B<fflush>(3))  or "
1394 "closed (B<fclose>(3)), a null byte is written at the end of the buffer if "
1395 "there is space.  The caller should ensure that an extra byte is available in "
1396 "the buffer (and that I<size> counts that byte)  to allow for this."
1397 msgstr ""
1398 "書き込み用にオープンされたストリームをフラッシュ (B<fflush>(3))  やクローズ "
1399 "(B<fclose>(3))  した時に、 (バッファに空きがあれば) NULL バイトがバッファの末"
1400 "尾に書き込まれる。 このようにするためには、呼び出し元は バッファに 1バイト余"
1401 "裕を作る (I<size> にこの 1バイトを含めた値を指定する) 必要がある。"
1402
1403 #.  See http://sourceware.org/bugzilla/show_bug.cgi?id=1995
1404 #.  and
1405 #.  http://sources.redhat.com/ml/libc-alpha/2006-04/msg00064.html
1406 #. type: Plain text
1407 #: build/C/man3/fmemopen.3:107
1408 msgid ""
1409 "Attempts to write more than I<size> bytes to the buffer result in an error.  "
1410 "(By default, such errors will be visible only when the I<stdio> buffer is "
1411 "flushed.  Disabling buffering with I<setbuf(fp,\\ NULL)> may be useful to "
1412 "detect errors at the time of an output operation.  Alternatively, the caller "
1413 "can explicitly set I<buf> as the stdio stream buffer, at the same time "
1414 "informing stdio of the buffer's size, using I<setbuffer(fp, buf, size)>.)"
1415 msgstr ""
1416 "バッファに I<size> バイトよりたくさん書き込もうとした場合には、エラーとな"
1417 "る。 (デフォルトでは、このようなエラーが見えるのは I<stdio> バッファがフラッ"
1418 "シュされた時だけである。 I<setbuf(fp,\\ NULL)> を使ってバッファリングを無効に"
1419 "する方法は、 出力操作を行った時点でエラーを検出するのに役立つ。 別の方法とし"
1420 "ては、 I<setbuffer(fp, buf, size)> を使って、呼び出し側が明示的に stdio スト"
1421 "リームバッファとして I<buf> を指定し、バッファの指定時にバッファのサイズを "
1422 "stdio に教える方法がある。)"
1423
1424 #. type: Plain text
1425 #: build/C/man3/fmemopen.3:115
1426 msgid ""
1427 "In a stream opened for reading, null bytes (\\(aq\\e0\\(aq) in the buffer do "
1428 "not cause read operations to return an end-of-file indication.  A read from "
1429 "the buffer will only indicate end-of-file when the file pointer advances "
1430 "I<size> bytes past the start of the buffer."
1431 msgstr ""
1432 "読み出し用にオープンされたストリームでは、 バッファ内に NULL バイト (\\(aq"
1433 "\\e0\\(aq) があっても 読み出し操作がファイル末尾 (end-of-file) を返すことはな"
1434 "い。 バッファからの読み出しでファイル末尾が返るのは、 ファイルポインタがバッ"
1435 "ファの先頭から I<size> バイトを越えて先に進もうとした場合だけである。"
1436
1437 #. type: Plain text
1438 #: build/C/man3/fmemopen.3:130
1439 msgid ""
1440 "If I<buf> is specified as NULL, then B<fmemopen>()  dynamically allocates a "
1441 "buffer I<size> bytes long.  This is useful for an application that wants to "
1442 "write data to a temporary buffer and then read it back again.  The buffer is "
1443 "automatically freed when the stream is closed.  Note that the caller has no "
1444 "way to obtain a pointer to the temporary buffer allocated by this call (but "
1445 "see B<open_memstream>()  below)."
1446 msgstr ""
1447 "I<buf> に NULL が指定された場合、 B<fmemopen>()  は動的に I<size> バイトの長"
1448 "さのバッファを確保する。 この方法は、一時バッファにデータの書き込みを行ってか"
1449 "ら、 その内容を再度読み出すようなアプリケーションで有用である。 このバッファ"
1450 "はストリームがクローズされるときに自動的に解放される。 呼び出し元からはこの関"
1451 "数が割り当てた一時バッファへのポインタ値を 知る方法は存在しない点に注意 (下記"
1452 "の B<open_memstream>()  も参照)。"
1453
1454 #. type: Plain text
1455 #: build/C/man3/fmemopen.3:141
1456 msgid ""
1457 "The B<open_memstream>()  function opens a stream for writing to a buffer.  "
1458 "The buffer is dynamically allocated (as with B<malloc>(3)), and "
1459 "automatically grows as required.  After closing the stream, the caller "
1460 "should B<free>(3)  this buffer."
1461 msgstr ""
1462 "B<open_memstream>()  関数は、バッファへの書き込み用にストリームをオープンす"
1463 "る。 バッファは (B<malloc>(3)  を使って) 動的に割り当てられ、必要に応じて自動"
1464 "的に伸長する。 ストリームをクローズした後で、呼び出し元はこのバッファを "
1465 "B<free>(3)  すべきである。"
1466
1467 #. type: Plain text
1468 #: build/C/man3/fmemopen.3:156
1469 msgid ""
1470 "When the stream is closed (B<fclose>(3))  or flushed (B<fflush>(3)), the "
1471 "locations pointed to by I<ptr> and I<sizeloc> are updated to contain, "
1472 "respectively, a pointer to the buffer and the current size of the buffer.  "
1473 "These values remain valid only as long as the caller performs no further "
1474 "output on the stream.  If further output is performed, then the stream must "
1475 "again be flushed before trying to access these variables."
1476 msgstr ""
1477 "このストリームが クローズ (B<fclose>(3))  されたりフラッシュ (B<fflush>(3))  "
1478 "された時に、 I<ptr> と I<sizeloc> の値はそれぞれバッファへのポインタとそのサ"
1479 "イズに更新される。 これらの値は、呼び出し元がそのストリームに新たな書き込み"
1480 "を 行わない場合に限り有効である。 ストリームに書き込みを行った際には、これら"
1481 "の変数を参照する前に ストリームを再度フラッシュしなければならない。"
1482
1483 #. type: Plain text
1484 #: build/C/man3/fmemopen.3:162
1485 msgid ""
1486 "A null byte is maintained at the end of the buffer.  This byte is I<not> "
1487 "included in the size value stored at I<sizeloc>."
1488 msgstr ""
1489 "バッファ末尾の NULL バイトは保持される。 この NULL バイトは I<sizeloc> に格納"
1490 "されるサイズには「含まれない」。"
1491
1492 #. type: Plain text
1493 #: build/C/man3/fmemopen.3:170
1494 msgid ""
1495 "The stream's file position can be changed with B<fseek>(3)  or B<fseeko>"
1496 "(3).  Moving the file position past the end of the data already written "
1497 "fills the intervening space with zeros."
1498 msgstr ""
1499 "ストリームのファイル位置は B<fseek>(3)  や B<fseeko>(3)  で変更できる。 すで"
1500 "にデータが書き込まれた領域の末尾より先にファイル位置を動かすと、 その間の領域"
1501 "は 0 で埋められる。"
1502
1503 #. type: Plain text
1504 #: build/C/man3/fmemopen.3:176
1505 msgid ""
1506 "The B<open_wmemstream>()  is similar to B<open_memstream>(), but operates on "
1507 "wide characters instead of bytes."
1508 msgstr ""
1509 "B<open_wmemstream>()  は B<open_memstream>()  と同様だが、バイトではなくワイ"
1510 "ド文字に対して操作を行う点が異なる。"
1511
1512 #. type: Plain text
1513 #: build/C/man3/fmemopen.3:188
1514 msgid ""
1515 "Upon successful completion B<fmemopen>(), B<open_memstream>()  and "
1516 "B<open_wmemstream>()  return a I<FILE> pointer.  Otherwise, NULL is returned "
1517 "and I<errno> is set to indicate the error."
1518 msgstr ""
1519 "成功して終了した場合には、 B<fmemopen>(), B<open_memstream>(), "
1520 "B<open_wmemstream>()  は I<FILE> ポインタを返す。 失敗した場合は、 NULL を返"
1521 "し、 I<errno> にエラーを示す値をセットする。"
1522
1523 #. type: SH
1524 #: build/C/man3/fmemopen.3:188 build/C/man3/fmtmsg.3:222
1525 #: build/C/man3/getline.3:135 build/C/man2/pipe.2:113 build/C/man2/readv.2:209
1526 #, no-wrap
1527 msgid "VERSIONS"
1528 msgstr "バージョン"
1529
1530 #. type: Plain text
1531 #: build/C/man3/fmemopen.3:195
1532 msgid ""
1533 "B<fmemopen>()  and B<open_memstream>()  were already available in glibc 1.0."
1534 "x.  B<open_wmemstream>()  is available since glibc 2.4."
1535 msgstr ""
1536 "B<fmemopen>()  と B<open_memstream>()  は glibc 1.0.x ですでに利用可能であっ"
1537 "た。 B<open_wmemstream>()  は glibc 2.4 以降で利用可能である。"
1538
1539 #. type: Plain text
1540 #: build/C/man3/fmemopen.3:199
1541 msgid ""
1542 "POSIX.1-2008.  These functions are not specified in POSIX.1-2001, and are "
1543 "not widely available on other systems."
1544 msgstr ""
1545 "POSIX.1-2008.  これらの関数は POSIX.1-2001 では規定れていないが、 Linux 以外"
1546 "のシステムで広く利用可能である。"
1547
1548 #.  http://austingroupbugs.net/view.php?id=396
1549 #. type: Plain text
1550 #: build/C/man3/fmemopen.3:207
1551 msgid ""
1552 "POSIX.1-2008 specifies that \\(aqb\\(aq in I<mode> shall be ignored.  "
1553 "However, Technical Corrigendum 1 adjusts the standard to allow "
1554 "implementation-specific treatment for this case, thus permitting the glibc "
1555 "treatment of \\(aqb\\(aq."
1556 msgstr ""
1557 "POSIX.1-2008 では I<mode> の \\(aqb\\(aq は無視されるべきだと規定されて\n"
1558 "いる。一方、Technical Corrigendum (正誤表) 1 では、I<mode> の\n"
1559 "\\(aqb\\(aq が指定された場合の扱いは実装依存であることを許容するように\n"
1560 "標準規格が修正されており、glibc の \\(aqb\\(aq の扱いは許されている。"
1561
1562 #. type: Plain text
1563 #: build/C/man3/fmemopen.3:213
1564 msgid ""
1565 "There is no file descriptor associated with the file stream returned by "
1566 "these functions (i.e., B<fileno>(3)  will return an error if called on the "
1567 "returned stream)."
1568 msgstr ""
1569 "これらの関数が返すファイルストリームに対応するファイル ディスクリプタはない "
1570 "(つまり、返されたストリームに対して B<fileno>(3)  を呼び出すとエラーが返るこ"
1571 "とになる)。"
1572
1573 #.  http://sourceware.org/bugzilla/show_bug.cgi?id=1996
1574 #. type: Plain text
1575 #: build/C/man3/fmemopen.3:220
1576 msgid ""
1577 "In glibc before version 2.7, seeking past the end of a stream created by "
1578 "B<open_memstream>()  does not enlarge the buffer; instead the B<fseek>(3)  "
1579 "call fails, returning -1."
1580 msgstr ""
1581 "バージョン 2.7 より前の glibc では、 B<open_memstream>()  で作成されたスト"
1582 "リームの末尾より先にファイル位置を動かしても、 バッファが伸長されず、 "
1583 "B<fseek>(3)  が失敗し -1 が返る。"
1584
1585 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=11216
1586 #. type: Plain text
1587 #: build/C/man3/fmemopen.3:231
1588 msgid ""
1589 "If I<size> is specified as zero, B<fmemopen>()  fails with the error "
1590 "B<EINVAL>.  It would be more consistent if this case successfully created a "
1591 "stream that then returned end of file on the first attempt at reading.  "
1592 "Furthermore, POSIX.1-2008 does not specify a failure for this case."
1593 msgstr ""
1594 "I<size> に 0 が指定された場合、 B<fmemopen>() はエラー B<EINVAL> で失敗\n"
1595 "する。この場合にはストリームの作成に成功して、最初の読み出しを行った際に\n"
1596 "EOF (end of file) が返される方が、ストリームの扱いの一貫性が増すだろう。\n"
1597 "また、 POSIX.1-2008 ではこの場合のエラーは規定されていない。"
1598
1599 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=13152
1600 #. type: Plain text
1601 #: build/C/man3/fmemopen.3:239
1602 msgid ""
1603 "Specifying append mode (\"a\" or \"a+\") for B<fmemopen>()  sets the initial "
1604 "file position to the first null byte, but (if the file offset is reset to a "
1605 "location other than the end of the stream)  does not force subsequent writes "
1606 "to append at the end of the stream."
1607 msgstr ""
1608 "B<fmemopen>() に追記モード (\"a\" や \"a+\") を指定すると、\n"
1609 "ファイル位置の初期値は最初の NULL バイトに設定されるが、(ファイル\n"
1610 "オフセットをストリームの末尾以外の位置に再設定した場合)それ以降の\n"
1611 "書き込みではストリームの末尾への追記が行われる訳ではない。"
1612
1613 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=13151
1614 #. type: Plain text
1615 #: build/C/man3/fmemopen.3:255
1616 msgid ""
1617 "If the I<mode> argument to B<fmemopen>()  specifies append (\"a\" or \"a+"
1618 "\"), and the I<size> argument does not cover a null byte in I<buf> then, "
1619 "according to POSIX.1-2008, the initial file position should be set to the "
1620 "next byte after the end of the buffer.  However, in this case the glibc "
1621 "B<fmemopen>()  sets the file position to -1."
1622 msgstr ""
1623 "B<fmemopen>() の I<mode> 引き数に追記モード (\"a\" や \"a+\") を指定し、\n"
1624 "I<size> 引き数で指定した範囲の I<buf> 内に NULL バイトがない場合、\n"
1625 "POSIX.1-2008 では、ファイル位置の初期値はバッファの末尾の直後の\n"
1626 "バイトに設定すべきとされている。しかし、glibc の B<fmemopen>() では\n"
1627 "この場合ファイル位置は -1 に設定される。"
1628
1629 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=12836
1630 #. type: Plain text
1631 #: build/C/man3/fmemopen.3:268
1632 msgid ""
1633 "To specify binary mode for B<fmemopen>()  the \\(aqb\\(aq must be the "
1634 "I<second> character in I<mode>.  Thus, for example, \"wb+\" has the desired "
1635 "effect, but \"w+b\" does not.  This is inconsistent with the treatment of "
1636 "I<mode> by B<fopen>(3)."
1637 msgstr ""
1638 "B<fmemopen>() でバイナリモードを指定するには、\n"
1639 "\\(aqb\\(aq は I<mode> の I<2 文字目> でなければならない。\n"
1640 "例えば、 \"wb+\" は意図通りの効果になるが、 \"w+b\" はそうではない。\n"
1641 "これは B<fopen>(3) の I<mode> の扱いとは異なる。"
1642
1643 #.  http://sourceware.org/bugzilla/show_bug.cgi?id=6544
1644 #. type: Plain text
1645 #: build/C/man3/fmemopen.3:276
1646 msgid ""
1647 "The glibc 2.9 addition of \"binary\" mode for B<fmemopen>()  silently "
1648 "changed the ABI: previously, B<fmemopen>()  ignored \\(aqb\\(aq in I<mode>."
1649 msgstr ""
1650 "glibc 2.9 での B<fmemopen>() の「バイナリ」モードの追加は、\n"
1651 "ABI (Application Binary Interface) が黙って変更された。\n"
1652 "それ以前の B<fmemopen>() では I<mode> 内の \\(aqb\\(aq は無視されていた。"
1653
1654 #. type: SH
1655 #: build/C/man3/fmemopen.3:276 build/C/man3/fmtmsg.3:256
1656 #: build/C/man3/fopencookie.3:247 build/C/man3/getline.3:144
1657 #: build/C/man2/pipe.2:124 build/C/man3/printf.3:973
1658 #: build/C/man2/readlink.2:157 build/C/man2/readv.2:265
1659 #: build/C/man3/scanf.3:681
1660 #, no-wrap
1661 msgid "EXAMPLE"
1662 msgstr "例"
1663
1664 #. type: Plain text
1665 #: build/C/man3/fmemopen.3:286
1666 msgid ""
1667 "The program below uses B<fmemopen>()  to open an input buffer, and "
1668 "B<open_memstream>()  to open a dynamically sized output buffer.  The program "
1669 "scans its input string (taken from the program's first command-line "
1670 "argument) reading integers, and writes the squares of these integers to the "
1671 "output buffer.  An example of the output produced by this program is the "
1672 "following:"
1673 msgstr ""
1674 "このプログラムは B<fmemopen>()  を使って出力バッファをオープンし、 "
1675 "B<open_memstream>()  を使って動的にサイズが変化する出力バッファをオープンして"
1676 "いる。 (プログラムの第一コマンドライン引き数から取った) 入力文字列を スキャン"
1677 "して整数を読み込み、これらの整数の二乗を出力バッファに書き出す。 このプログラ"
1678 "ムの実行例は以下のようになる。"
1679
1680 #. type: Plain text
1681 #: build/C/man3/fmemopen.3:291
1682 #, no-wrap
1683 msgid ""
1684 "$B< ./a.out \\(aq1 23 43\\(aq>\n"
1685 "size=11; ptr=1 529 1849\n"
1686 msgstr ""
1687 "$B< ./a.out \\(aq1 23 43\\(aq>\n"
1688 "size=11; ptr=1 529 1849\n"
1689
1690 #. type: SS
1691 #: build/C/man3/fmemopen.3:293 build/C/man3/fopencookie.3:271
1692 #, no-wrap
1693 msgid "Program source"
1694 msgstr "プログラムのソース"
1695
1696 #. type: Plain text
1697 #: build/C/man3/fmemopen.3:300
1698 #, no-wrap
1699 msgid ""
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 msgstr ""
1705 "#define _GNU_SOURCE\n"
1706 "#include E<lt>string.hE<gt>\n"
1707 "#include E<lt>stdio.hE<gt>\n"
1708 "#include E<lt>stdlib.hE<gt>\n"
1709
1710 #. type: Plain text
1711 #: build/C/man3/fmemopen.3:303
1712 #, no-wrap
1713 msgid ""
1714 "#define handle_error(msg) \\e\n"
1715 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
1716 msgstr ""
1717 "#define handle_error(msg) \\e\n"
1718 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
1719
1720 #. type: Plain text
1721 #: build/C/man3/fmemopen.3:311
1722 #, no-wrap
1723 msgid ""
1724 "int\n"
1725 "main(int argc, char *argv[])\n"
1726 "{\n"
1727 "    FILE *out, *in;\n"
1728 "    int v, s;\n"
1729 "    size_t size;\n"
1730 "    char *ptr;\n"
1731 msgstr ""
1732 "int\n"
1733 "main(int argc, char *argv[])\n"
1734 "{\n"
1735 "    FILE *out, *in;\n"
1736 "    int v, s;\n"
1737 "    size_t size;\n"
1738 "    char *ptr;\n"
1739
1740 #. type: Plain text
1741 #: build/C/man3/fmemopen.3:316
1742 #, no-wrap
1743 msgid ""
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 msgstr ""
1749 "    if (argc != 2) {\n"
1750 "\tfprintf(stderr, \"Usage: %s E<lt>fileE<gt>\\en\", argv[0]);\n"
1751 "\texit(EXIT_FAILURE);\n"
1752 "    }\n"
1753
1754 #. type: Plain text
1755 #: build/C/man3/fmemopen.3:320
1756 #, no-wrap
1757 msgid ""
1758 "    in = fmemopen(argv[1], strlen(argv[1]), \"r\");\n"
1759 "    if (in == NULL)\n"
1760 "        handle_error(\"fmemopen\");\n"
1761 msgstr ""
1762 "    in = fmemopen(argv[1], strlen(argv[1]), \"r\");\n"
1763 "    if (in == NULL)\n"
1764 "        handle_error(\"fmemopen\");\n"
1765
1766 #. type: Plain text
1767 #: build/C/man3/fmemopen.3:324
1768 #, no-wrap
1769 msgid ""
1770 "    out = open_memstream(&ptr, &size);\n"
1771 "    if (out == NULL)\n"
1772 "        handle_error(\"open_memstream\");\n"
1773 msgstr ""
1774 "    out = open_memstream(&ptr, &size);\n"
1775 "    if (out == NULL)\n"
1776 "        handle_error(\"open_memstream\");\n"
1777
1778 #. type: Plain text
1779 #: build/C/man3/fmemopen.3:329
1780 #, no-wrap
1781 msgid ""
1782 "    for (;;) {\n"
1783 "        s = fscanf(in, \"%d\", &v);\n"
1784 "        if (s E<lt>= 0)\n"
1785 "            break;\n"
1786 msgstr ""
1787 "    for (;;) {\n"
1788 "        s = fscanf(in, \"%d\", &v);\n"
1789 "        if (s E<lt>= 0)\n"
1790 "            break;\n"
1791
1792 #. type: Plain text
1793 #: build/C/man3/fmemopen.3:340
1794 #, no-wrap
1795 msgid ""
1796 "        s = fprintf(out, \"%d \", v * v);\n"
1797 "        if (s == -1)\n"
1798 "            handle_error(\"fprintf\");\n"
1799 "    }\n"
1800 "    fclose(in);\n"
1801 "    fclose(out);\n"
1802 "    printf(\"size=%ld; ptr=%s\\en\", (long) size, ptr);\n"
1803 "    free(ptr);\n"
1804 "    exit(EXIT_SUCCESS);\n"
1805 "}\n"
1806 msgstr ""
1807 "        s = fprintf(out, \"%d \", v * v);\n"
1808 "        if (s == -1)\n"
1809 "            handle_error(\"fprintf\");\n"
1810 "    }\n"
1811 "    fclose(in);\n"
1812 "    fclose(out);\n"
1813 "    printf(\"size=%ld; ptr=%s\\en\", (long) size, ptr);\n"
1814 "    free(ptr);\n"
1815 "    exit(EXIT_SUCCESS);\n"
1816 "}\n"
1817
1818 #. type: Plain text
1819 #: build/C/man3/fmemopen.3:344
1820 msgid "B<fopen>(3), B<fopencookie>(3)"
1821 msgstr "B<fopen>(3), B<fopencookie>(3)"
1822
1823 #. type: TH
1824 #: build/C/man3/fmtmsg.3:13
1825 #, no-wrap
1826 msgid "FMTMSG"
1827 msgstr "FMTMSG"
1828
1829 #. type: Plain text
1830 #: build/C/man3/fmtmsg.3:16
1831 msgid "fmtmsg - print formatted error messages"
1832 msgstr "fmtmsg - 整形されたエラーメッセージを表示する"
1833
1834 #. type: Plain text
1835 #: build/C/man3/fmtmsg.3:19
1836 #, no-wrap
1837 msgid "B<#include E<lt>fmtmsg.hE<gt>>\n"
1838 msgstr "B<#include E<lt>fmtmsg.hE<gt>>\n"
1839
1840 #. type: Plain text
1841 #: build/C/man3/fmtmsg.3:21
1842 #, no-wrap
1843 msgid "B<int fmtmsg(long >I<classification>B<, const char *>I<label>B<,>\n"
1844 msgstr "B<int fmtmsg(long >I<classification>B<, const char *>I<label>B<,>\n"
1845
1846 #. type: Plain text
1847 #: build/C/man3/fmtmsg.3:23
1848 #, no-wrap
1849 msgid "B<           int >I<severity>B<, const char *>I<text>B<,>\n"
1850 msgstr "B<           int >I<severity>B<, const char *>I<text>B<,>\n"
1851
1852 #. type: Plain text
1853 #: build/C/man3/fmtmsg.3:25
1854 #, no-wrap
1855 msgid "B<           const char *>I<action>B<, const char *>I<tag>B<);>\n"
1856 msgstr "B<           const char *>I<action>B<, const char *>I<tag>B<);>\n"
1857
1858 #. type: Plain text
1859 #: build/C/man3/fmtmsg.3:36
1860 msgid ""
1861 "This function displays a message described by its arguments on the device"
1862 "(s)  specified in the I<classification> argument.  For messages written to "
1863 "I<stderr>, the format depends on the B<MSGVERB> environment variable."
1864 msgstr ""
1865 "この関数は、引き数で記述されたメッセージを、 I<classification> 引き数で指定さ"
1866 "れたデバイス上に表示する。 I<stderr> に書き出されるメッセージのフォーマット"
1867 "は、 B<MSGVERB> 環境変数に依存する。"
1868
1869 #. type: Plain text
1870 #: build/C/man3/fmtmsg.3:43
1871 msgid ""
1872 "The I<label> argument identifies the source of the message.  The string must "
1873 "consist of two colon separated parts where the first part has not more than "
1874 "10 and the second part not more than 14 characters."
1875 msgstr ""
1876 "I<label> 引き数はメッセージの発生源を識別する。 この文字列はコロンで区切られ"
1877 "た 2 つの部分から構成されていなければならない。 1 つ目の部分は 10 文字以内で"
1878 "なければならず、 2 つ目の部分は 14 文字以内でなければならない。"
1879
1880 #. type: Plain text
1881 #: build/C/man3/fmtmsg.3:47
1882 msgid "The I<text> argument describes the condition of the error."
1883 msgstr "I<text> 引き数にはエラー条件を記述する。"
1884
1885 #. type: Plain text
1886 #: build/C/man3/fmtmsg.3:52
1887 msgid ""
1888 "The I<action> argument describes possible steps to recover from the error.  "
1889 "If it is printed, it is prefixed by \"TO FIX: \"."
1890 msgstr ""
1891 "I<action> 引き数にはエラーから回復するために利用可能なステップを記述する。 こ"
1892 "れが表示される場合、\"TO FIX: \" が前に付く。"
1893
1894 #. type: Plain text
1895 #: build/C/man3/fmtmsg.3:60
1896 msgid ""
1897 "The I<tag> argument is a reference to the online documentation where more "
1898 "information can be found.  It should contain the I<label> value and a unique "
1899 "identification number."
1900 msgstr ""
1901 "I<tag> 引き数はより多くの情報を見つけるためのオンラインドキュメントへの参照で"
1902 "ある。 これは I<label> 値とユニークな識別番号を含んでいるべきである。"
1903
1904 #. type: SS
1905 #: build/C/man3/fmtmsg.3:60
1906 #, no-wrap
1907 msgid "Dummy arguments"
1908 msgstr "ダミー引き数"
1909
1910 #. type: Plain text
1911 #: build/C/man3/fmtmsg.3:79
1912 msgid ""
1913 "Each of the arguments can have a dummy value.  The dummy classification "
1914 "value B<MM_NULLMC> (0L) does not specify any output, so nothing is printed.  "
1915 "The dummy severity value B<NO_SEV> (0) says that no severity is supplied.  "
1916 "The values B<MM_NULLLBL>, B<MM_NULLTXT>, B<MM_NULLACT>, B<MM_NULLTAG> are "
1917 "synonyms for I<((char\\ *)\\ 0)>, the empty string, and B<MM_NULLSEV> is a "
1918 "synonym for B<NO_SEV>."
1919 msgstr "各引き数にはダミーの値を入れることができる。 ダミーの I<classification> 値 B<MM_NULLMC> (0L) は出力を何も指定しない。そのため何も表示されない。 ダミーの I<severity> 値 B<NO_SEV> (0) は重大度 (severity) が与えられていないことを表す。 値 B<MM_NULLLBL>, B<MM_NULLTXT>, B<MM_NULLACT>, B<MM_NULLTAG> は I<((char\\ *)\\ 0)> と空文字列の別名であり、 B<MM_NULLSEV> は B<NO_SEV> の別名である。"
1920
1921 #. type: SS
1922 #: build/C/man3/fmtmsg.3:79
1923 #, no-wrap
1924 msgid "The classification argument"
1925 msgstr "classification 引き数"
1926
1927 #. type: Plain text
1928 #: build/C/man3/fmtmsg.3:83
1929 msgid ""
1930 "The I<classification> argument is the sum of values describing 4 types of "
1931 "information."
1932 msgstr "I<classification> 引き数は 4 種類の情報を記述する値の和である。"
1933
1934 #. type: Plain text
1935 #: build/C/man3/fmtmsg.3:86
1936 msgid "The first value defines the output channel."
1937 msgstr "最初の値は出力チャンネルを定義する。"
1938
1939 #. type: TP
1940 #: build/C/man3/fmtmsg.3:86
1941 #, no-wrap
1942 msgid "B<MM_PRINT>"
1943 msgstr "B<MM_PRINT>"
1944
1945 #. type: Plain text
1946 #: build/C/man3/fmtmsg.3:90
1947 msgid "Output to I<stderr>."
1948 msgstr "I<stderr> に出力する。"
1949
1950 #. type: TP
1951 #: build/C/man3/fmtmsg.3:90
1952 #, no-wrap
1953 msgid "B<MM_CONSOLE>"
1954 msgstr "B<MM_CONSOLE>"
1955
1956 #. type: Plain text
1957 #: build/C/man3/fmtmsg.3:93
1958 msgid "Output to the system console."
1959 msgstr "システムコンソールに出力する。"
1960
1961 #. type: TP
1962 #: build/C/man3/fmtmsg.3:93
1963 #, no-wrap
1964 msgid "B<MM_PRINT | MM_CONSOLE>"
1965 msgstr "B<MM_PRINT | MM_CONSOLE>"
1966
1967 #. type: Plain text
1968 #: build/C/man3/fmtmsg.3:96
1969 msgid "Output to both."
1970 msgstr "両方に出力する。"
1971
1972 #. type: Plain text
1973 #: build/C/man3/fmtmsg.3:98
1974 msgid "The second value is the source of the error:"
1975 msgstr "2 番目の値はエラーの発生源である:"
1976
1977 #. type: TP
1978 #: build/C/man3/fmtmsg.3:98
1979 #, no-wrap
1980 msgid "B<MM_HARD>"
1981 msgstr "B<MM_HARD>"
1982
1983 #. type: Plain text
1984 #: build/C/man3/fmtmsg.3:101
1985 msgid "A hardware error occurred."
1986 msgstr "ハードウェアエラーが起こった。"
1987
1988 #. type: TP
1989 #: build/C/man3/fmtmsg.3:101
1990 #, no-wrap
1991 msgid "B<MM_FIRM>"
1992 msgstr "B<MM_FIRM>"
1993
1994 #. type: Plain text
1995 #: build/C/man3/fmtmsg.3:104
1996 msgid "A firmware error occurred."
1997 msgstr "ファームウェアエラーが起こった。"
1998
1999 #. type: TP
2000 #: build/C/man3/fmtmsg.3:104
2001 #, no-wrap
2002 msgid "B<MM_SOFT>"
2003 msgstr "B<MM_SOFT>"
2004
2005 #. type: Plain text
2006 #: build/C/man3/fmtmsg.3:107
2007 msgid "A software error occurred."
2008 msgstr "ソフトウェアエラーが起こった。"
2009
2010 #. type: Plain text
2011 #: build/C/man3/fmtmsg.3:109
2012 msgid "The third value encodes the detector of the problem:"
2013 msgstr "3 番目の値は問題の検知を行ったものをエンコードする:"
2014
2015 #. type: TP
2016 #: build/C/man3/fmtmsg.3:109
2017 #, no-wrap
2018 msgid "B<MM_APPL>"
2019 msgstr "B<MM_APPL>"
2020
2021 #. type: Plain text
2022 #: build/C/man3/fmtmsg.3:112
2023 msgid "It is detected by an application."
2024 msgstr "アプリケーションによって検知された。"
2025
2026 #. type: TP
2027 #: build/C/man3/fmtmsg.3:112
2028 #, no-wrap
2029 msgid "B<MM_UTIL>"
2030 msgstr "B<MM_UTIL>"
2031
2032 #. type: Plain text
2033 #: build/C/man3/fmtmsg.3:115
2034 msgid "It is detected by a utility."
2035 msgstr "ユーティリティによって検知された。"
2036
2037 #. type: TP
2038 #: build/C/man3/fmtmsg.3:115
2039 #, no-wrap
2040 msgid "B<MM_OPSYS>"
2041 msgstr "B<MM_OPSYS>"
2042
2043 #. type: Plain text
2044 #: build/C/man3/fmtmsg.3:118
2045 msgid "It is detected by the operating system."
2046 msgstr "オペレーティングシステムによって検知された。"
2047
2048 #. type: Plain text
2049 #: build/C/man3/fmtmsg.3:120
2050 msgid "The fourth value shows the severity of the incident:"
2051 msgstr "4 番目の値は問題の重大度を表す:"
2052
2053 #. type: TP
2054 #: build/C/man3/fmtmsg.3:120
2055 #, no-wrap
2056 msgid "B<MM_RECOVER>"
2057 msgstr "B<MM_RECOVER>"
2058
2059 #. type: Plain text
2060 #: build/C/man3/fmtmsg.3:123
2061 msgid "It is a recoverable error."
2062 msgstr "回復可能なエラーである。"
2063
2064 #. type: TP
2065 #: build/C/man3/fmtmsg.3:123
2066 #, no-wrap
2067 msgid "B<MM_NRECOV>"
2068 msgstr "B<MM_NRECOV>"
2069
2070 #. type: Plain text
2071 #: build/C/man3/fmtmsg.3:126
2072 msgid "It is a nonrecoverable error."
2073 msgstr "回復不可能なエラーである。"
2074
2075 #. type: SS
2076 #: build/C/man3/fmtmsg.3:126
2077 #, no-wrap
2078 msgid "The severity argument"
2079 msgstr "severity 引き数"
2080
2081 #. type: Plain text
2082 #: build/C/man3/fmtmsg.3:130
2083 msgid "The I<severity> argument can take one of the following values:"
2084 msgstr "I<severity> 引き数は以下の 1 つの値をとることができる。"
2085
2086 #. type: TP
2087 #: build/C/man3/fmtmsg.3:130
2088 #, no-wrap
2089 msgid "B<MM_NOSEV>"
2090 msgstr "B<MM_NOSEV>"
2091
2092 #. type: Plain text
2093 #: build/C/man3/fmtmsg.3:133
2094 msgid "No severity is printed."
2095 msgstr "重大度は表示されない。"
2096
2097 #. type: TP
2098 #: build/C/man3/fmtmsg.3:133
2099 #, no-wrap
2100 msgid "B<MM_HALT>"
2101 msgstr "B<MM_HALT>"
2102
2103 #. type: Plain text
2104 #: build/C/man3/fmtmsg.3:136
2105 msgid "This value is printed as HALT."
2106 msgstr "この値は HALT として表示される。"
2107
2108 #. type: TP
2109 #: build/C/man3/fmtmsg.3:136
2110 #, no-wrap
2111 msgid "B<MM_ERROR>"
2112 msgstr "B<MM_ERROR>"
2113
2114 #. type: Plain text
2115 #: build/C/man3/fmtmsg.3:139
2116 msgid "This value is printed as ERROR."
2117 msgstr "この値は ERROR として表示される。"
2118
2119 #. type: TP
2120 #: build/C/man3/fmtmsg.3:139
2121 #, no-wrap
2122 msgid "B<MM_WARNING>"
2123 msgstr "B<MM_WARNING>"
2124
2125 #. type: Plain text
2126 #: build/C/man3/fmtmsg.3:142
2127 msgid "This value is printed as WARNING."
2128 msgstr "この値は WARNING として表示される。"
2129
2130 #. type: TP
2131 #: build/C/man3/fmtmsg.3:142
2132 #, no-wrap
2133 msgid "B<MM_INFO>"
2134 msgstr "B<MM_INFO>"
2135
2136 #. type: Plain text
2137 #: build/C/man3/fmtmsg.3:145
2138 msgid "This value is printed as INFO."
2139 msgstr "この値は INFO として表示される。"
2140
2141 #. type: Plain text
2142 #: build/C/man3/fmtmsg.3:152
2143 msgid ""
2144 "The numeric values are between 0 and 4.  Using B<addseverity>(3)  or the "
2145 "environment variable B<SEV_LEVEL> you can add more levels and strings to "
2146 "print."
2147 msgstr ""
2148 "数値の場合は 0 から 4 である。 B<addseverity>(3)  または環境変数 "
2149 "B<SEV_LEVEL> を使うことにより、表示するレベルと文字列を更に追加できる。"
2150
2151 #. type: Plain text
2152 #: build/C/man3/fmtmsg.3:154
2153 msgid "The function can return 4 values:"
2154 msgstr "関数は 4 つの値を返す:"
2155
2156 #. type: TP
2157 #: build/C/man3/fmtmsg.3:154
2158 #, no-wrap
2159 msgid "B<MM_OK>"
2160 msgstr "B<MM_OK>"
2161
2162 #. type: Plain text
2163 #: build/C/man3/fmtmsg.3:157
2164 msgid "Everything went smooth."
2165 msgstr "全てがうまくいった。"
2166
2167 #. type: TP
2168 #: build/C/man3/fmtmsg.3:157
2169 #, no-wrap
2170 msgid "B<MM_NOTOK>"
2171 msgstr "B<MM_NOTOK>"
2172
2173 #. type: Plain text
2174 #: build/C/man3/fmtmsg.3:160
2175 msgid "Complete failure."
2176 msgstr "完全に失敗した。"
2177
2178 #. type: TP
2179 #: build/C/man3/fmtmsg.3:160
2180 #, no-wrap
2181 msgid "B<MM_NOMSG>"
2182 msgstr "B<MM_NOMSG>"
2183
2184 #. type: Plain text
2185 #: build/C/man3/fmtmsg.3:164
2186 msgid "Error writing to I<stderr>."
2187 msgstr "I<stderr> に書き込むときにエラーが起こった。"
2188
2189 #. type: TP
2190 #: build/C/man3/fmtmsg.3:164
2191 #, no-wrap
2192 msgid "B<MM_NOCON>"
2193 msgstr "B<MM_NOCON>"
2194
2195 #. type: Plain text
2196 #: build/C/man3/fmtmsg.3:167
2197 msgid "Error writing to the console."
2198 msgstr "コンソールに書き込むときにエラーが起こった。"
2199
2200 #. type: SH
2201 #: build/C/man3/fmtmsg.3:167
2202 #, no-wrap
2203 msgid "ENVIRONMENT"
2204 msgstr "環境変数"
2205
2206 #. type: Plain text
2207 #: build/C/man3/fmtmsg.3:178
2208 msgid ""
2209 "The environment variable B<MSGVERB> (\"message verbosity\") can be used to "
2210 "suppress parts of the output to I<stderr>.  (It does not influence output to "
2211 "the console.)  When this variable is defined, is non-NULL, and is a colon-"
2212 "separated list of valid keywords, then only the parts of the message "
2213 "corresponding to these keywords is printed.  Valid keywords are \"label\", "
2214 "\"severity\", \"text\", \"action\" and \"tag\"."
2215 msgstr ""
2216 "環境変数 B<MSGVERB> (\"message verbosity\") は I<stderr> への出力の一部を抑制"
2217 "するのに使うことができる。 (コンソールへの出力には影響しない。)  この変数が定"
2218 "義されて、NULL でなく、 コロンで区切られた有効なキーワードのリストである場"
2219 "合、 キーワードに対応するメッセージの一部のみが表示される。 有効なキーワード"
2220 "は \"label\", \"severity\", \"text\", \"action\", \"tag\" である。"
2221
2222 #. type: Plain text
2223 #: build/C/man3/fmtmsg.3:190
2224 msgid ""
2225 "The environment variable B<SEV_LEVEL> can be used to introduce new severity "
2226 "levels.  By default, only the five severity levels described above are "
2227 "available.  Any other numeric value would make B<fmtmsg>()  print nothing.  "
2228 "If the user puts B<SEV_LEVEL> with a format like"
2229 msgstr ""
2230 "環境変数 B<SEV_LEVEL> は新しい重大度レベルを導入するのに使用できる。 デフォル"
2231 "トでは、上記の 5 つの重大度レベルのみが利用可能である。 他の数値の場合、 "
2232 "B<fmtmsg>()  は何も表示しない。 B<fmtmsg>()  を初めて呼び出す前に、ユーザが "
2233 "B<SEV_LEVEL> を"
2234
2235 #. type: Plain text
2236 #: build/C/man3/fmtmsg.3:193
2237 msgid "SEV_LEVEL=[description[:description[:...]]]"
2238 msgstr "SEV_LEVEL=[description[:description[:...]]]"
2239
2240 #. type: Plain text
2241 #: build/C/man3/fmtmsg.3:198
2242 msgid ""
2243 "in the environment of the process before the first call to B<fmtmsg>(), "
2244 "where each description is of the form"
2245 msgstr ""
2246 "のような形式でプロセスの環境に設定すると、 B<fmtmsg>()  は (標準のレベル 0-4 "
2247 "に加えて) level に指定された値も受け付け、 そのようなレベルの問題が発生すると"
2248 "指定された printstring を表示する。 各 description は"
2249
2250 #. type: Plain text
2251 #: build/C/man3/fmtmsg.3:201
2252 msgid "severity-keyword,level,printstring"
2253 msgstr "severity-keyword,level,printstring"
2254
2255 #. type: Plain text
2256 #: build/C/man3/fmtmsg.3:208
2257 msgid ""
2258 "then B<fmtmsg>()  will also accept the indicated values for the level (in "
2259 "addition to the standard levels 0-4), and use the indicated printstring when "
2260 "such a level occurs."
2261 msgstr "という形式である。"
2262
2263 #. type: Plain text
2264 #: build/C/man3/fmtmsg.3:222
2265 msgid ""
2266 "The severity-keyword part is not used by B<fmtmsg>()  but it has to be "
2267 "present.  The level part is a string representation of a number.  The "
2268 "numeric value must be a number greater than 4.  This value must be used in "
2269 "the severity argument of B<fmtmsg>()  to select this class.  It is not "
2270 "possible to overwrite any of the predefined classes.  The printstring is the "
2271 "string printed when a message of this class is processed by B<fmtmsg>()."
2272 msgstr ""
2273 "severity-keyword 部は B<fmtmsg>()  に使用されないが、存在しなければならな"
2274 "い。 level 部は数値を文字列で表したものである。 数値は 4 より大きい値でなけれ"
2275 "ばならない。 この値は B<fmtmsg>()  の severity 引き数で使用されなければなら"
2276 "ず、この重大度を選択する。 前もって宣言された重大度を上書きすることはできな"
2277 "い。 printstring は、 この重大度のメッセージが B<fmtmsg>()  によって生成され"
2278 "た場合に表示される文字列である。"
2279
2280 #. type: Plain text
2281 #: build/C/man3/fmtmsg.3:225
2282 msgid "B<fmtmsg>()  is provided in glibc since version 2.1."
2283 msgstr "B<fmtmsg>()  は、バージョン 2.1 以降の glibc で提供されている。"
2284
2285 #. type: Plain text
2286 #: build/C/man3/fmtmsg.3:231
2287 msgid ""
2288 "Before glibc 2.16, the B<fmtmsg>()  function uses a static variable that is "
2289 "not protected, so it is not thread-safe."
2290 msgstr ""
2291
2292 #.  Modified in commit 7724defcf8873116fe4efab256596861eef21a94
2293 #. type: Plain text
2294 #: build/C/man3/fmtmsg.3:237
2295 msgid ""
2296 "Since glibc 2.16, the B<fmtmsg>()  function uses a lock to protect the "
2297 "static variable, so it is thread-safe."
2298 msgstr ""
2299
2300 #. type: Plain text
2301 #: build/C/man3/fmtmsg.3:252
2302 msgid ""
2303 "The functions B<fmtmsg>()  and B<addseverity>(3), and environment variables "
2304 "B<MSGVERB> and B<SEV_LEVEL> come from System V.  The function B<fmtmsg>()  "
2305 "and the environment variable B<MSGVERB> are described in POSIX.1-2001."
2306 msgstr ""
2307 "関数 B<fmtmsg>()  と B<addseverity>(3)  と環境変数 B<MSGVERB> と "
2308 "B<SEV_LEVEL> は System V に由来している。 関数 B<fmtmsg>()  と環境変数 "
2309 "B<MSGVERB> は POSIX.1-2001 に記述されている。"
2310
2311 #. type: Plain text
2312 #: build/C/man3/fmtmsg.3:256
2313 msgid ""
2314 "System V and UnixWare man pages tell us that these functions have been "
2315 "replaced by \"pfmt() and addsev()\" or by \"pfmt(), vpfmt(), lfmt(), and "
2316 "vlfmt()\", and will be removed later."
2317 msgstr ""
2318 "System V と UnixWare の man ページには、 「これらの関数は \"pfmt() と addsev"
2319 "()\" または \"pfmt(), vpfmt(), lfmt(), vlfmt()\" で置き換えられており、 将来"
2320 "は削除される予定である」と書かれている。"
2321
2322 #. type: Plain text
2323 #: build/C/man3/fmtmsg.3:261
2324 #, no-wrap
2325 msgid ""
2326 "#include E<lt>stdio.hE<gt>\n"
2327 "#include E<lt>stdlib.hE<gt>\n"
2328 "#include E<lt>fmtmsg.hE<gt>\n"
2329 msgstr ""
2330 "#include E<lt>stdio.hE<gt>\n"
2331 "#include E<lt>stdlib.hE<gt>\n"
2332 "#include E<lt>fmtmsg.hE<gt>\n"
2333
2334 #. type: Plain text
2335 #: build/C/man3/fmtmsg.3:267
2336 #, no-wrap
2337 msgid ""
2338 "int\n"
2339 "main(void)\n"
2340 "{\n"
2341 "    long class = MM_PRINT | MM_SOFT | MM_OPSYS | MM_RECOVER;\n"
2342 "    int err;\n"
2343 msgstr ""
2344 "int\n"
2345 "main(void)\n"
2346 "{\n"
2347 "    long class = MM_PRINT | MM_SOFT | MM_OPSYS | MM_RECOVER;\n"
2348 "    int err;\n"
2349
2350 #. type: Plain text
2351 #: build/C/man3/fmtmsg.3:288
2352 #, no-wrap
2353 msgid ""
2354 "    err = fmtmsg(class, \"util-linux:mount\", MM_ERROR,\n"
2355 "                \"unknown mount option\", \"See mount(8).\",\n"
2356 "                \"util-linux:mount:017\");\n"
2357 "    switch (err) {\n"
2358 "    case MM_OK:\n"
2359 "        break;\n"
2360 "    case MM_NOTOK:\n"
2361 "        printf(\"Nothing printed\\en\");\n"
2362 "        break;\n"
2363 "    case MM_NOMSG:\n"
2364 "        printf(\"Nothing printed to stderr\\en\");\n"
2365 "        break;\n"
2366 "    case MM_NOCON:\n"
2367 "        printf(\"No console output\\en\");\n"
2368 "        break;\n"
2369 "    default:\n"
2370 "        printf(\"Unknown error from fmtmsg()\\en\");\n"
2371 "    }\n"
2372 "    exit(EXIT_SUCCESS);\n"
2373 "}\n"
2374 msgstr ""
2375 "    err = fmtmsg(class, \"util-linux:mount\", MM_ERROR,\n"
2376 "                \"unknown mount option\", \"See mount(8).\",\n"
2377 "                \"util-linux:mount:017\");\n"
2378 "    switch (err) {\n"
2379 "    case MM_OK:\n"
2380 "      break;\n"
2381 "    case MM_NOTOK:\n"
2382 "        printf(\"Nothing printed\\en\");\n"
2383 "        break;\n"
2384 "    case MM_NOMSG:\n"
2385 "        printf(\"Nothing printed to stderr\\en\");\n"
2386 "        break;\n"
2387 "    case MM_NOCON:\n"
2388 "        printf(\"No console output\\en\");\n"
2389 "        break;\n"
2390 "    default:\n"
2391 "        printf(\"Unknown error from fmtmsg()\\en\");\n"
2392 "    }\n"
2393 "    exit(EXIT_SUCCESS);\n"
2394 "}\n"
2395
2396 #. type: Plain text
2397 #: build/C/man3/fmtmsg.3:291
2398 msgid "The output should be:"
2399 msgstr "出力は"
2400
2401 #. type: Plain text
2402 #: build/C/man3/fmtmsg.3:295
2403 #, no-wrap
2404 msgid ""
2405 "    util-linux:mount: ERROR: unknown mount option\n"
2406 "    TO FIX: See mount(8).  util-linux:mount:017\n"
2407 msgstr ""
2408 "    util-linux:mount: ERROR: unknown mount option\n"
2409 "    TO FIX: See mount(8).  util-linux:mount:017\n"
2410
2411 #. type: Plain text
2412 #: build/C/man3/fmtmsg.3:298
2413 msgid "and after"
2414 msgstr "のようになり、"
2415
2416 #. type: Plain text
2417 #: build/C/man3/fmtmsg.3:301
2418 #, no-wrap
2419 msgid "    MSGVERB=text:action; export MSGVERB\n"
2420 msgstr "    MSGVERB=text:action; export MSGVERB\n"
2421
2422 #. type: Plain text
2423 #: build/C/man3/fmtmsg.3:304
2424 msgid "the output becomes:"
2425 msgstr "を実行すると、次のようになる。"
2426
2427 #. type: Plain text
2428 #: build/C/man3/fmtmsg.3:308
2429 #, no-wrap
2430 msgid ""
2431 "    unknown mount option\n"
2432 "    TO FIX: See mount(8).\n"
2433 msgstr ""
2434 "    unknown mount option\n"
2435 "    TO FIX: See mount(8).\n"
2436
2437 #. type: Plain text
2438 #: build/C/man3/fmtmsg.3:312
2439 msgid "B<addseverity>(3), B<perror>(3)"
2440 msgstr "B<addseverity>(3), B<perror>(3)"
2441
2442 #. type: TH
2443 #: build/C/man3/fopen.3:44
2444 #, no-wrap
2445 msgid "FOPEN"
2446 msgstr "FOPEN"
2447
2448 #. type: TH
2449 #: build/C/man3/fopen.3:44
2450 #, no-wrap
2451 msgid "2012-04-22"
2452 msgstr "2012-04-22"
2453
2454 #. type: Plain text
2455 #: build/C/man3/fopen.3:47
2456 msgid "fopen, fdopen, freopen - stream open functions"
2457 msgstr "fopen, fdopen, freopen - ストリームを開く関数"
2458
2459 #. type: Plain text
2460 #: build/C/man3/fopen.3:52
2461 #, no-wrap
2462 msgid "B<FILE *fopen(const char *>I<path>B<, const char *>I<mode>B<);>\n"
2463 msgstr "B<FILE *fopen(const char *>I<path>B<, const char *>I<mode>B<);>\n"
2464
2465 #. type: Plain text
2466 #: build/C/man3/fopen.3:54
2467 #, no-wrap
2468 msgid "B<FILE *fdopen(int >I<fd>B<, const char *>I<mode>B<);>\n"
2469 msgstr "B<FILE *fdopen(int >I<fd>B<, const char *>I<mode>B<);>\n"
2470
2471 #. type: Plain text
2472 #: build/C/man3/fopen.3:56
2473 #, no-wrap
2474 msgid "B<FILE *freopen(const char *>I<path>B<, const char *>I<mode>B<, FILE *>I<stream>B<);>\n"
2475 msgstr "B<FILE *freopen(const char *>I<path>B<, const char *>I<mode>B<, FILE *>I<stream>B<);>\n"
2476
2477 #. type: Plain text
2478 #: build/C/man3/fopen.3:65
2479 msgid ""
2480 "B<fdopen>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
2481 msgstr ""
2482 "B<fdopen>(): _POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE"
2483
2484 #. type: Plain text
2485 #: build/C/man3/fopen.3:71
2486 msgid ""
2487 "The B<fopen>()  function opens the file whose name is the string pointed to "
2488 "by I<path> and associates a stream with it."
2489 msgstr ""
2490 "B<fopen>()  関数は、 I<path> で指定された名前のファイルを開き、ストリームと結"
2491 "びつける。"
2492
2493 #. type: Plain text
2494 #: build/C/man3/fopen.3:76
2495 msgid ""
2496 "The argument I<mode> points to a string beginning with one of the following "
2497 "sequences (possibly followed by additional characters, as described below):"
2498 msgstr ""
2499 "引数 I<mode> は、以下に続く文字のひとつから始まる文字列へのポインタであ\n"
2500 "る (以下の述べる、追加の文字が後に続くこともある):"
2501
2502 #. type: TP
2503 #: build/C/man3/fopen.3:76
2504 #, no-wrap
2505 msgid "B<r>"
2506 msgstr "B<r>"
2507
2508 #. type: Plain text
2509 #: build/C/man3/fopen.3:80
2510 msgid ""
2511 "Open text file for reading.  The stream is positioned at the beginning of "
2512 "the file."
2513 msgstr ""
2514 "テキストファイルを読み出すために開く。 ストリームはファイルの先頭に位置され"
2515 "る。"
2516
2517 #. type: TP
2518 #: build/C/man3/fopen.3:80
2519 #, no-wrap
2520 msgid "B<r+>"
2521 msgstr "B<r+>"
2522
2523 #. type: Plain text
2524 #: build/C/man3/fopen.3:84
2525 msgid ""
2526 "Open for reading and writing.  The stream is positioned at the beginning of "
2527 "the file."
2528 msgstr ""
2529 "読み出しおよび書き込みするために開く。 ストリームはファイルの先頭に位置され"
2530 "る。"
2531
2532 #. type: TP
2533 #: build/C/man3/fopen.3:84
2534 #, no-wrap
2535 msgid "B<w>"
2536 msgstr "B<w>"
2537
2538 #. type: Plain text
2539 #: build/C/man3/fopen.3:88
2540 msgid ""
2541 "Truncate file to zero length or create text file for writing.  The stream is "
2542 "positioned at the beginning of the file."
2543 msgstr ""
2544 "ファイルを書き込みのために開く。 ファイルが既に存在する場合には長さゼロに切り"
2545 "詰める。 ファイルがなかった場合には新たに作成する。 ストリームはファイルの先"
2546 "頭に位置される。"
2547
2548 #. type: TP
2549 #: build/C/man3/fopen.3:88
2550 #, no-wrap
2551 msgid "B<w+>"
2552 msgstr "B<w+>"
2553
2554 #. type: Plain text
2555 #: build/C/man3/fopen.3:94
2556 msgid ""
2557 "Open for reading and writing.  The file is created if it does not exist, "
2558 "otherwise it is truncated.  The stream is positioned at the beginning of the "
2559 "file."
2560 msgstr ""
2561 "読み出しおよび書き込みのために開く。 ファイルが存在していない場合には新たに作"
2562 "成する。 存在している場合には長さゼロに切り詰められる。 ストリームはファイル"
2563 "の先頭に位置される。"
2564
2565 #. type: TP
2566 #: build/C/man3/fopen.3:94 build/C/man3/scanf.3:447
2567 #, no-wrap
2568 msgid "B<a>"
2569 msgstr "B<a>"
2570
2571 #. type: Plain text
2572 #: build/C/man3/fopen.3:99
2573 msgid ""
2574 "Open for appending (writing at end of file).  The file is created if it does "
2575 "not exist.  The stream is positioned at the end of the file."
2576 msgstr ""
2577 "追加 (ファイルの最後に書き込む) のために開く。 ファイルが存在していない場合に"
2578 "は新たに作成する。 ストリームはファイルの最後に位置される。"
2579
2580 #. type: TP
2581 #: build/C/man3/fopen.3:99
2582 #, no-wrap
2583 msgid "B<a+>"
2584 msgstr "B<a+>"
2585
2586 #. type: Plain text
2587 #: build/C/man3/fopen.3:105
2588 msgid ""
2589 "Open for reading and appending (writing at end of file).  The file is "
2590 "created if it does not exist.  The initial file position for reading is at "
2591 "the beginning of the file, but output is always appended to the end of the "
2592 "file."
2593 msgstr ""
2594 "読み出しおよび追加 (ファイルの最後に書き込む) のために開く。 ファイルが存在し"
2595 "ていない場合には新たに作成する。 読み出しの初期ファイル位置はファイルの先頭で"
2596 "あるが、 書き込みは常にファイルの最後に追加される。"
2597
2598 #. type: Plain text
2599 #: build/C/man3/fopen.3:118
2600 msgid ""
2601 "The I<mode> string can also include the letter \\(aqb\\(aq either as a last "
2602 "character or as a character between the characters in any of the two-"
2603 "character strings described above.  This is strictly for compatibility with "
2604 "C89 and has no effect; the \\(aqb\\(aq is ignored on all POSIX conforming "
2605 "systems, including Linux.  (Other systems may treat text files and binary "
2606 "files differently, and adding the \\(aqb\\(aq may be a good idea if you do I/"
2607 "O to a binary file and expect that your program may be ported to non-UNIX "
2608 "environments.)"
2609 msgstr ""
2610 "I<mode> 文字列には文字 \\(aqb\\(aq を追加指定することができ、 I<mode> 文字列"
2611 "の最後の文字として指定する。 上記のうち 2 文字のモードの場合には 2 つの文字の"
2612 "間に指定することもできる。 これは C89 との互換性のためだけに用意された もので"
2613 "あり、関数の実行に対してはいかなる影響も持たない。 すなわち、Linux を含む全て"
2614 "の POSIX 準拠システムでは、 この \\(aqb\\(aq は無視される。 (その他のシステム"
2615 "ではテキストファイルとバイナリファイルを別々に扱うものもあるので、 もしバイナ"
2616 "リファイルの入出力を行い、 そのプログラムが非 UNIX 環境へ移植されると予測する"
2617 "なら、 \\(aqb\\(aqを付けておくのは良い考えである)"
2618
2619 #. type: Plain text
2620 #: build/C/man3/fopen.3:121
2621 msgid "See NOTES below for details of glibc extensions for I<mode>."
2622 msgstr "I<mode> の glibc による拡張の詳細については下記の「注意」を参照。"
2623
2624 #. type: Plain text
2625 #: build/C/man3/fopen.3:126
2626 msgid ""
2627 "Any created files will have mode B<S_IRUSR> | B<S_IWUSR> | B<S_IRGRP> | "
2628 "B<S_IWGRP> | B<S_IROTH> | B<S_IWOTH> (0666), as modified by the process's "
2629 "umask value (see B<umask>(2))."
2630 msgstr ""
2631 "すべての生成されたファイルは、 B<S_IRUSR> | B<S_IWUSR> | B<S_IRGRP> | "
2632 "B<S_IWGRP> | B<S_IROTH> | B<S_IWOTH> (0666) のモードを そのプロセスの umask "
2633 "値によって修正したモードを持つ (B<umask>(2)  を見よ)。"
2634
2635 #. type: Plain text
2636 #: build/C/man3/fopen.3:141
2637 msgid ""
2638 "Reads and writes may be intermixed on read/write streams in any order.  Note "
2639 "that ANSI C requires that a file positioning function intervene between "
2640 "output and input, unless an input operation encounters end-of-file.  (If "
2641 "this condition is not met, then a read is allowed to return the result of "
2642 "writes other than the most recent.)  Therefore it is good practice (and "
2643 "indeed sometimes necessary under Linux) to put an B<fseek>(3)  or B<fgetpos>"
2644 "(3)  operation between write and read operations on such a stream.  This "
2645 "operation may be an apparent no-op (as in I<fseek(..., 0L, SEEK_CUR)> called "
2646 "for its synchronizing side effect."
2647 msgstr ""
2648 "読み出し/書き込みストリームに対しては任意の順序で読み書きを行うことができ"
2649 "る。 ただし ANSI C では、 (入力操作がファイルの末尾に到達した場合を除いて)  "
2650 "出力と入力の間にはファイルの位置決め関数を 挟まなければならないことになってい"
2651 "ることに注意されたい (この条件を満足しない場合には、読み込み操作は、 最後に書"
2652 "き込まれたものでなく、以前に書き込まれた 値を返すことを許されている)。 した"
2653 "がって、このようなストリームでの読み書き操作の間には B<fseek>(3)  または "
2654 "B<fgetpos>(3)  操作を挟んでおくと良いだろう (Linux では本当に必要となることも"
2655 "ときどきある)。 この操作は見かけ上何もしない操作 (no-op) でも良い (例えば "
2656 "I<fseek(..., 0L, SEEK_CUR)> を その副次的効果である同期のためだけに呼べば良"
2657 "い)。"
2658
2659 #. type: Plain text
2660 #: build/C/man3/fopen.3:146
2661 msgid ""
2662 "Opening a file in append mode (B<a> as the first character of I<mode>)  "
2663 "causes all subsequent write operations to this stream to occur at end-of-"
2664 "file, as if preceded the call:"
2665 msgstr ""
2666 "ファイルを追加モード (I<mode> の最初の文字を B<a> にする) で開くと、\n"
2667 "このストリームに対する書き込み操作は全て (先に以下の呼び出しを行った\n"
2668 "かのように) ファイルの末尾で行われる。"
2669
2670 #. type: Plain text
2671 #: build/C/man3/fopen.3:149
2672 #, no-wrap
2673 msgid "    fseek(stream, 0, SEEK_END);\n"
2674 msgstr "    fseek(stream, 0, SEEK_END);\n"
2675
2676 #. type: Plain text
2677 #: build/C/man3/fopen.3:171
2678 msgid ""
2679 "The B<fdopen>()  function associates a stream with the existing file "
2680 "descriptor, I<fd>.  The I<mode> of the stream (one of the values \"r\", \"r+"
2681 "\", \"w\", \"w+\", \"a\", \"a+\")  must be compatible with the mode of the "
2682 "file descriptor.  The file position indicator of the new stream is set to "
2683 "that belonging to I<fd>, and the error and end-of-file indicators are "
2684 "cleared.  Modes \"w\" or \"w+\" do not cause truncation of the file.  The "
2685 "file descriptor is not dup'ed, and will be closed when the stream created by "
2686 "B<fdopen>()  is closed.  The result of applying B<fdopen>()  to a shared "
2687 "memory object is undefined."
2688 msgstr ""
2689 "B<fdopen>()  関数は、既存のファイル記述子 I<fd> にストリームを結びつける。 ス"
2690 "トリームの I<mode> (\"r\", \"r+\", \"w\", \"w+\", \"a\", \"a+\" のいずれか) "
2691 "は ファイル記述子のモードと互換のものでなければならない。 新しいストリームの"
2692 "ファイル位置指示子は I<fd> に属している値に設定される。 error と end-of-file "
2693 "の各指示子はクリアされる。 \"w\" および \"w+\" モードでのファイルの切り詰めは"
2694 "行われない。 ファイル記述子の複製は行なわれない。 B<fdopen>()  で作成されたス"
2695 "トリームが閉じられたときにファイル記述子も 閉じられる。 共有メモリのオブジェ"
2696 "クトへ B<fdopen>()  を行ったときの結果は定義されていない。"
2697
2698 #. type: Plain text
2699 #: build/C/man3/fopen.3:189
2700 msgid ""
2701 "The B<freopen>()  function opens the file whose name is the string pointed "
2702 "to by I<path> and associates the stream pointed to by I<stream> with it.  "
2703 "The original stream (if it exists) is closed.  The I<mode> argument is used "
2704 "just as in the B<fopen>()  function.  The primary use of the B<freopen>()  "
2705 "function is to change the file associated with a standard text stream "
2706 "(I<stderr>, I<stdin>, or I<stdout>)."
2707 msgstr ""
2708 "B<freopen>()  関数は I<path> で名前が指定されたファイルを開き、 I<stream> で"
2709 "指定されたストリームに、そのファイルを結びつける。 もとのストリームは (もし存"
2710 "在する場合には) 閉じられる。 I<mode> 引数は B<fopen>()  関数と同じ形で使われ"
2711 "る。 B<freopen>()  関数の主な用途は、標準テキストストリーム (I<stderr>, "
2712 "I<stdin>, I<stdout>)  と対応付けられているファイルを変更することである。"
2713
2714 #. type: Plain text
2715 #: build/C/man3/fopen.3:201
2716 msgid ""
2717 "Upon successful completion B<fopen>(), B<fdopen>()  and B<freopen>()  return "
2718 "a I<FILE> pointer.  Otherwise, NULL is returned and I<errno> is set to "
2719 "indicate the error."
2720 msgstr ""
2721 "B<fopen>(), B<fdopen>(), B<freopen>()  は成功すると I<FILE> 型のポインタを返"
2722 "す。 失敗すると NULL が返され、 I<errno> がエラーを示す値にセットされる。"
2723
2724 #. type: TP
2725 #: build/C/man3/fopen.3:202 build/C/man3/fseek.3:142
2726 #: build/C/man3/getline.3:126 build/C/man2/llseek.2:77
2727 #: build/C/man2/lseek.2:175 build/C/man2/pipe.2:102 build/C/man2/read.2:126
2728 #: build/C/man2/read.2:137 build/C/man2/readlink.2:95
2729 #: build/C/man2/readlink.2:104 build/C/man2/readv.2:200
2730 #: build/C/man2/rename.2:139 build/C/man2/rmdir.2:67 build/C/man3/scanf.3:565
2731 #: build/C/man2/write.2:154
2732 #, no-wrap
2733 msgid "B<EINVAL>"
2734 msgstr "B<EINVAL>"
2735
2736 #. type: Plain text
2737 #: build/C/man3/fopen.3:212
2738 msgid ""
2739 "The I<mode> provided to B<fopen>(), B<fdopen>(), or B<freopen>()  was "
2740 "invalid."
2741 msgstr ""
2742 "B<fopen>(), B<fdopen>(), B<freopen>()  で与えられた I<mode> が不適切である。"
2743
2744 #. type: Plain text
2745 #: build/C/man3/fopen.3:222
2746 msgid ""
2747 "The B<fopen>(), B<fdopen>()  and B<freopen>()  functions may also fail and "
2748 "set I<errno> for any of the errors specified for the routine B<malloc>(3)."
2749 msgstr ""
2750 "B<fopen>(), B<fdopen>(), B<freopen>()  関数は B<malloc>(3)  ルーチンで規定さ"
2751 "れているエラーでも失敗することがあり、 その時は対応する値に I<errno> をセット"
2752 "する。"
2753
2754 #. type: Plain text
2755 #: build/C/man3/fopen.3:229
2756 msgid ""
2757 "The B<fopen>()  function may also fail and set I<errno> for any of the "
2758 "errors specified for the routine B<open>(2)."
2759 msgstr ""
2760 "B<fopen>()  関数は B<open>(2)  ルーチンで規定されているエラーでも失敗すること"
2761 "があり、 その時は対応する値に I<errno> をセットする。"
2762
2763 #. type: Plain text
2764 #: build/C/man3/fopen.3:236
2765 msgid ""
2766 "The B<fdopen>()  function may also fail and set I<errno> for any of the "
2767 "errors specified for the routine B<fcntl>(2)."
2768 msgstr ""
2769 "B<fdopen>()  関数は B<fcntl>(2)  ルーチンで規定されているエラーでも失敗するこ"
2770 "とがあり、 その時は対応する値に I<errno> をセットする。"
2771
2772 #. type: Plain text
2773 #: build/C/man3/fopen.3:246
2774 msgid ""
2775 "The B<freopen>()  function may also fail and set I<errno> for any of the "
2776 "errors specified for the routines B<open>(2), B<fclose>(3)  and B<fflush>(3)."
2777 msgstr ""
2778 "B<freopen>()  関数は B<open>(2), B<fclose>(3), B<fflush>(3)  各ルーチンで規定"
2779 "されているエラーでも失敗することがあり、 その時は対応する値に I<errno> をセッ"
2780 "トする。"
2781
2782 #. type: Plain text
2783 #: build/C/man3/fopen.3:255
2784 msgid ""
2785 "The B<fopen>()  and B<freopen>()  functions conform to C89.  The B<fdopen>"
2786 "()  function conforms to POSIX.1-1990."
2787 msgstr ""
2788 "B<fopen>()  関数と B<freopen>()  関数は C89に準拠している。 B<fdopen>()  関数"
2789 "は POSIX.1-1990 に準拠している。"
2790
2791 #. type: SS
2792 #: build/C/man3/fopen.3:256
2793 #, no-wrap
2794 msgid "Glibc notes"
2795 msgstr "glibc での注意"
2796
2797 #. type: Plain text
2798 #: build/C/man3/fopen.3:259
2799 msgid ""
2800 "The GNU C library allows the following extensions for the string specified "
2801 "in I<mode>:"
2802 msgstr ""
2803 "GNU C ライブラリでは、 I<mode> に指定できる文字列として、以下の拡張が行われて"
2804 "いる:"
2805
2806 #. type: TP
2807 #: build/C/man3/fopen.3:259
2808 #, no-wrap
2809 msgid "B<c> (since glibc 2.3.3)"
2810 msgstr "B<c> (glibc 2.3.3 以降)"
2811
2812 #. type: Plain text
2813 #: build/C/man3/fopen.3:266
2814 msgid ""
2815 "Do not make the open operation, or subsequent read and write operations, "
2816 "thread cancellation points.  This flag is ignored for B<fdopen>()."
2817 msgstr ""
2818 "open 操作、それに続く read/write 操作の、 スレッドの取り消しポイント\n"
2819 "(cancellation points) を作成しない。\n"
2820 "このフラグは B<fdopen>() では無視される。"
2821
2822 #. type: TP
2823 #: build/C/man3/fopen.3:266
2824 #, no-wrap
2825 msgid "B<e> (since glibc 2.7)"
2826 msgstr "B<e> (glibc 2.7 以降)"
2827
2828 #. type: Plain text
2829 #: build/C/man3/fopen.3:276
2830 msgid ""
2831 "Open the file with the B<O_CLOEXEC> flag.  See B<open>(2)  for more "
2832 "information.  This flag is ignored for B<fdopen>()."
2833 msgstr ""
2834 "B<O_CLOEXEC> フラグを有効にしてファイルをオープンする。詳細は\n"
2835 "B<open>(2) を参照。このフラグは B<fdopen>() では無視される。"
2836
2837 #. type: TP
2838 #: build/C/man3/fopen.3:276
2839 #, no-wrap
2840 msgid "B<m> (since glibc 2.3)"
2841 msgstr "B<m> (glibc 2.3 以降)"
2842
2843 #.  As at glibc 2.4:
2844 #. type: Plain text
2845 #: build/C/man3/fopen.3:288
2846 msgid ""
2847 "Attempt to access the file using B<mmap>(2), rather than I/O system calls "
2848 "(B<read>(2), B<write>(2)).  Currently, use of B<mmap>(2)  is attempted only "
2849 "for a file opened for reading."
2850 msgstr ""
2851 "I/O システムコール (B<read>(2), B<write>(2))  ではなく、 B<mmap>(2)  を使って"
2852 "ファイルにアクセスしようとする。 B<mmap>(2)  を使おうとするのは、読み出し用に"
2853 "オープンするファイルについてだけである。"
2854
2855 #. type: TP
2856 #: build/C/man3/fopen.3:288 build/C/man3/scanf.3:421
2857 #, no-wrap
2858 msgid "B<x>"
2859 msgstr "B<x>"
2860
2861 #.  Since glibc 2.0?
2862 #.  FIXME C11 specifies this flag
2863 #. type: Plain text
2864 #: build/C/man3/fopen.3:305
2865 msgid ""
2866 "Open the file exclusively (like the B<O_EXCL> flag of B<open>(2)).  If the "
2867 "file already exists, B<fopen>()  fails, and sets I<errno> to B<EEXIST>.  "
2868 "This flag is ignored for B<fdopen>()."
2869 msgstr ""
2870 "ファイルを排他的にオープンする (B<open>(2)  の B<O_EXCL> フラグと同様)。 ファ"
2871 "イルがすでに存在する場合、 B<fopen>()  は失敗し、 I<errno> に B<EEXIST> が"
2872 "セットされる。 このフラグは B<fdopen>()  では無視される。"
2873
2874 #. type: Plain text
2875 #: build/C/man3/fopen.3:313
2876 msgid ""
2877 "In addition to the above characters, B<fopen>()  and B<freopen>()  support "
2878 "the following syntax in I<mode>:"
2879 msgstr ""
2880 "上記の文字に加えて、\n"
2881 "B<fopen>() と B<freopen>() では I<mode> に\n"
2882 "以下の書式を 指定することができる。"
2883
2884 #. type: Plain text
2885 #: build/C/man3/fopen.3:315
2886 msgid "B< ,ccs=>I<string>"
2887 msgstr "B< ,ccs=>I<string>"
2888
2889 #. type: Plain text
2890 #: build/C/man3/fopen.3:331
2891 msgid ""
2892 "The given I<string> is taken as the name of a coded character set and the "
2893 "stream is marked as wide-oriented.  Thereafter, internal conversion "
2894 "functions convert I/O to and from the character set I<string>.  If the B<,"
2895 "ccs=>I<string> syntax is not specified, then the wide-orientation of the "
2896 "stream is determined by the first file operation.  If that operation is a "
2897 "wide-character operation, the stream is marked wide-oriented, and functions "
2898 "to convert to the coded character set are loaded."
2899 msgstr ""
2900 "指定された I<string> は、符号化文字集合の名前と解釈され、\n"
2901 "ストリームではワイド文字のストリームとして扱われる。\n"
2902 "内部変換関数で入出力時に文字集合 I<string> との変換が行われる。\n"
2903 "書式 B<,ccs=>I<string> が指定されない場合は、\n"
2904 "ストリームをワイド文字のストリームとして扱うかは\n"
2905 "最初のファイル操作時に決定される。\n"
2906 "最初のファイル操作がワイド文字操作であった場合は、\n"
2907 "そのストリームはワイド文字のストリームとして扱われ、\n"
2908 "符号化文字集合との変換を行う関数が読み込まれる。"
2909
2910 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=12685
2911 #. type: Plain text
2912 #: build/C/man3/fopen.3:348
2913 msgid ""
2914 "When parsing for individual flag characters in I<mode> (i.e., the characters "
2915 "preceding the \"ccs\" specification), the glibc implementation of B<fopen>"
2916 "()  and B<freopen>()  limits the number of characters examined in I<mode> to "
2917 "7 (or, in glibc versions before 2.14, to 6, which was not enough to include "
2918 "possible specifications such as \"rb+cmxe\").  The current implementation of "
2919 "B<fdopen>()  parses at most 5 characters in I<mode>."
2920 msgstr ""
2921 "I<mode> の個々のフラグ文字 (\"ccs\" 指定の前の文字) を解釈する際に、\n"
2922 "glibc の B<fopen>() と B<freopen>() の実装では、\n"
2923 "I<mode> の確認を最大 7 文字しか行わないという制限がある\n"
2924 "(バージョン 2.14 より前の glibc では最大 6 文字だが、\n"
2925 "6 文字では \"rb+cmxe\" などの指定を行うには不十分であった)。\n"
2926 "B<fdopen>() の現在の実装では最大 5 文字の I<mode> しか解釈されない。"
2927
2928 #. type: Plain text
2929 #: build/C/man3/fopen.3:354
2930 msgid ""
2931 "B<open>(2), B<fclose>(3), B<fileno>(3), B<fmemopen>(3), B<fopencookie>(3)"
2932 msgstr ""
2933 "B<open>(2), B<fclose>(3), B<fileno>(3), B<fmemopen>(3), B<fopencookie>(3)"
2934
2935 #. type: TH
2936 #: build/C/man3/fopencookie.3:26
2937 #, no-wrap
2938 msgid "FOPENCOOKIE"
2939 msgstr "FOPENCOOKIE"
2940
2941 #. type: TH
2942 #: build/C/man3/fopencookie.3:26
2943 #, no-wrap
2944 msgid "2013-03-17"
2945 msgstr "2013-03-17"
2946
2947 #. type: TH
2948 #: build/C/man3/fopencookie.3:26 build/C/man2/link.2:31
2949 #: build/C/man2/llseek.2:28 build/C/man2/lseek.2:47 build/C/man3/lseek64.3:25
2950 #: build/C/man2/open.2:52 build/C/man2/pipe.2:36 build/C/man2/read.2:35
2951 #: build/C/man2/readlink.2:43 build/C/man2/readv.2:32 build/C/man2/rename.2:32
2952 #: build/C/man2/rmdir.2:30 build/C/man3/setbuf.3:48 build/C/man3/stdin.3:13
2953 #: build/C/man2/symlink.2:32 build/C/man7/symlink.7:36
2954 #: build/C/man2/unlink.2:32 build/C/man2/write.2:39
2955 #, no-wrap
2956 msgid "Linux"
2957 msgstr "Linux"
2958
2959 #. type: Plain text
2960 #: build/C/man3/fopencookie.3:29
2961 msgid "fopencookie - opening a custom stream"
2962 msgstr ""
2963
2964 #. type: Plain text
2965 #: build/C/man3/fopencookie.3:36
2966 #, no-wrap
2967 msgid ""
2968 "B<FILE *fopencookie(void *>I<cookie>B<, const char *>I<mode>B<,>\n"
2969 "B<                  cookie_io_functions_t >I<io_funcs>B<);>\n"
2970 msgstr ""
2971 "B<FILE *fopencookie(void *>I<cookie>B<, const char *>I<mode>B<,>\n"
2972 "B<                  cookie_io_functions_t >I<io_funcs>B<);>\n"
2973
2974 #. type: Plain text
2975 #: build/C/man3/fopencookie.3:49
2976 msgid ""
2977 "The B<fopencookie>()  function allows the programmer to create a custom "
2978 "implementation for a standard I/O stream.  This implementation can store the "
2979 "stream's data at a location of its own choosing; for example, B<fopencookie>"
2980 "()  is used to implement B<fmemopen>(3), which provides a stream interface "
2981 "to data that is stored in a buffer in memory."
2982 msgstr ""
2983
2984 #. type: Plain text
2985 #: build/C/man3/fopencookie.3:51
2986 msgid "In order to create a custom stream the programmer must:"
2987 msgstr ""
2988
2989 #. type: IP
2990 #: build/C/man3/fopencookie.3:51 build/C/man3/fopencookie.3:54
2991 #: build/C/man3/fopencookie.3:65 build/C/man3/scanf.3:633
2992 #: build/C/man3/scanf.3:638 build/C/man3/scanf.3:644
2993 #: build/C/man7/symlink.7:249 build/C/man7/symlink.7:259
2994 #: build/C/man7/symlink.7:289 build/C/man7/symlink.7:349
2995 #: build/C/man7/symlink.7:378 build/C/man7/symlink.7:407
2996 #: build/C/man7/symlink.7:438 build/C/man7/symlink.7:451
2997 #, no-wrap
2998 msgid "*"
2999 msgstr "*"
3000
3001 #. type: Plain text
3002 #: build/C/man3/fopencookie.3:54
3003 msgid ""
3004 "Implement four \"hook\" functions that are used internally by the standard I/"
3005 "O library when performing I/O on the stream."
3006 msgstr ""
3007
3008 #. type: Plain text
3009 #: build/C/man3/fopencookie.3:65
3010 msgid ""
3011 "Define a \"cookie\" data type, a structure that provides bookkeeping "
3012 "information (e.g., where to store data) used by the aforementioned hook "
3013 "functions.  The standard I/O package knows nothing about the contents of "
3014 "this cookie (thus it is typed as I<void\\ *> when passed to B<fopencookie>"
3015 "()), but automatically supplies the cookie as the first argument when "
3016 "calling the hook functions."
3017 msgstr ""
3018
3019 #. type: Plain text
3020 #: build/C/man3/fopencookie.3:70
3021 msgid ""
3022 "Call B<fopencookie>()  to open a new stream and associate the cookie and "
3023 "hook functions with that stream."
3024 msgstr ""
3025
3026 #. type: Plain text
3027 #: build/C/man3/fopencookie.3:78
3028 msgid ""
3029 "The B<fopencookie>()  function serves a purpose similar to B<fopen>(3): it "
3030 "opens a new stream and returns a pointer to a I<FILE> object that is used to "
3031 "operate on that stream."
3032 msgstr ""
3033
3034 #. type: Plain text
3035 #: build/C/man3/fopencookie.3:85
3036 msgid ""
3037 "The I<cookie> argument is a pointer to the caller's cookie structure that is "
3038 "to be associated with the new stream.  This pointer is supplied as the first "
3039 "argument when the standard I/O library invokes any of the hook functions "
3040 "described below."
3041 msgstr ""
3042
3043 #. type: Plain text
3044 #: build/C/man3/fopencookie.3:101
3045 msgid ""
3046 "The I<mode> argument serves the same purpose as for B<fopen>(3).  The "
3047 "following modes are supported: I<r>, I<w>, I<a>, I<r+>, I<w+>, and I<a+>.  "
3048 "See B<fopen>(3)  for details."
3049 msgstr ""
3050
3051 #. type: Plain text
3052 #: build/C/man3/fopencookie.3:107
3053 msgid ""
3054 "The I<io_funcs> argument is a structure that contains four fields pointing "
3055 "to the programmer-defined hook functions that are used to implement this "
3056 "stream.  The structure is defined as follows"
3057 msgstr ""
3058
3059 #. type: Plain text
3060 #: build/C/man3/fopencookie.3:116
3061 #, no-wrap
3062 msgid ""
3063 "typedef struct {\n"
3064 "    cookie_read_function_t  *read;\n"
3065 "    cookie_write_function_t *write;\n"
3066 "    cookie_seek_function_t  *seek;\n"
3067 "    cookie_close_function_t *close;\n"
3068 "} cookie_io_functions_t;\n"
3069 msgstr ""
3070 "typedef struct {\n"
3071 "    cookie_read_function_t  *read;\n"
3072 "    cookie_write_function_t *write;\n"
3073 "    cookie_seek_function_t  *seek;\n"
3074 "    cookie_close_function_t *close;\n"
3075 "} cookie_io_functions_t;\n"
3076
3077 #. type: Plain text
3078 #: build/C/man3/fopencookie.3:120
3079 msgid "The four fields are as follows:"
3080 msgstr ""
3081
3082 #. type: TP
3083 #: build/C/man3/fopencookie.3:120
3084 #, no-wrap
3085 msgid "I<cookie_read_function_t *read>"
3086 msgstr "I<cookie_read_function_t *read>"
3087
3088 #. type: Plain text
3089 #: build/C/man3/fopencookie.3:124
3090 msgid ""
3091 "This function implements read operations for the stream.  When called, it "
3092 "receives three arguments:"
3093 msgstr ""
3094
3095 #. type: Plain text
3096 #: build/C/man3/fopencookie.3:126
3097 #, no-wrap
3098 msgid "    ssize_t read(void *cookie, char *buf, size_t size);\n"
3099 msgstr "    ssize_t read(void *cookie, char *buf, size_t size);\n"
3100
3101 #. type: Plain text
3102 #: build/C/man3/fopencookie.3:141
3103 msgid ""
3104 "The I<buf> and I<size> arguments are, respectively, a buffer into which "
3105 "input data can be placed and the size of that buffer.  As its function "
3106 "result, the I<read> function should return the number of bytes copied into "
3107 "I<buf>, 0 on end of file, or -1 on error.  The I<read> function should "
3108 "update the stream offset appropriately."
3109 msgstr ""
3110
3111 #. type: Plain text
3112 #: build/C/man3/fopencookie.3:146
3113 msgid ""
3114 "If I<*read> is a NULL pointer, then reads from the custom stream always "
3115 "return end of file."
3116 msgstr ""
3117
3118 #. type: TP
3119 #: build/C/man3/fopencookie.3:146
3120 #, no-wrap
3121 msgid "I<cookie_write_function_t *write>"
3122 msgstr "I<cookie_write_function_t *write>"
3123
3124 #. type: Plain text
3125 #: build/C/man3/fopencookie.3:150
3126 msgid ""
3127 "This function implements write operations for the stream.  When called, it "
3128 "receives three arguments:"
3129 msgstr ""
3130
3131 #. type: Plain text
3132 #: build/C/man3/fopencookie.3:152
3133 #, no-wrap
3134 msgid "    ssize_t write(void *cookie, const char *buf, size_t size);\n"
3135 msgstr "    ssize_t write(void *cookie, const char *buf, size_t size);\n"
3136
3137 #. type: Plain text
3138 #: build/C/man3/fopencookie.3:168
3139 msgid ""
3140 "The I<buf> and I<size> arguments are, respectively, a buffer of data to be "
3141 "output to the stream and the size of that buffer.  As its function result, "
3142 "the I<write> function should return the number of bytes copied from I<buf>, "
3143 "or 0 on error.  (The function must not return a negative value.)  The "
3144 "I<write> function should update the stream offset appropriately."
3145 msgstr ""
3146
3147 #. type: Plain text
3148 #: build/C/man3/fopencookie.3:173
3149 msgid "If I<*write> is a NULL pointer, then output to the stream is discarded."
3150 msgstr ""
3151
3152 #. type: TP
3153 #: build/C/man3/fopencookie.3:173
3154 #, no-wrap
3155 msgid "I<cookie_seek_function_t *seek>"
3156 msgstr "I<cookie_seek_function_t *seek>"
3157
3158 #. type: Plain text
3159 #: build/C/man3/fopencookie.3:177
3160 msgid ""
3161 "This function implements seek operations on the stream.  When called, it "
3162 "receives three arguments:"
3163 msgstr ""
3164
3165 #. type: Plain text
3166 #: build/C/man3/fopencookie.3:179
3167 #, no-wrap
3168 msgid "    int seek(void *cookie, off64_t *offset, int whence);\n"
3169 msgstr "    int seek(void *cookie, off64_t *offset, int whence);\n"
3170
3171 #. type: Plain text
3172 #: build/C/man3/fopencookie.3:185
3173 msgid ""
3174 "The I<*offset> argument specifies the new file offset depending on which of "
3175 "the following three values is supplied in I<whence>:"
3176 msgstr ""
3177
3178 #. type: TP
3179 #: build/C/man3/fopencookie.3:186 build/C/man2/lseek.2:67
3180 #, no-wrap
3181 msgid "B<SEEK_SET>"
3182 msgstr "B<SEEK_SET>"
3183
3184 #. type: Plain text
3185 #: build/C/man3/fopencookie.3:191
3186 msgid ""
3187 "The stream offset should be set I<*offset> bytes from the start of the "
3188 "stream."
3189 msgstr ""
3190
3191 #. type: TP
3192 #: build/C/man3/fopencookie.3:191 build/C/man2/lseek.2:72
3193 #, no-wrap
3194 msgid "B<SEEK_CUR>"
3195 msgstr "B<SEEK_CUR>"
3196
3197 #. type: Plain text
3198 #: build/C/man3/fopencookie.3:195
3199 msgid "I<*offset> should be added to the current stream offset."
3200 msgstr ""
3201
3202 #. type: TP
3203 #: build/C/man3/fopencookie.3:195 build/C/man2/lseek.2:77
3204 #, no-wrap
3205 msgid "B<SEEK_END>"
3206 msgstr "B<SEEK_END>"
3207
3208 #. type: Plain text
3209 #: build/C/man3/fopencookie.3:199
3210 msgid ""
3211 "The stream offset should be set to the size of the stream plus I<*offset>."
3212 msgstr ""
3213
3214 #. type: Plain text
3215 #: build/C/man3/fopencookie.3:206
3216 msgid ""
3217 "Before returning, the I<seek> function should update I<*offset> to indicate "
3218 "the new stream offset."
3219 msgstr ""
3220
3221 #. type: Plain text
3222 #: build/C/man3/fopencookie.3:210
3223 msgid ""
3224 "As its function result, the I<seek> function should return 0 on success, and "
3225 "-1 on error."
3226 msgstr ""
3227
3228 #. type: Plain text
3229 #: build/C/man3/fopencookie.3:215
3230 msgid ""
3231 "If I<*seek> is a NULL pointer, then it is not possible to perform seek "
3232 "operations on the stream."
3233 msgstr ""
3234
3235 #. type: TP
3236 #: build/C/man3/fopencookie.3:215
3237 #, no-wrap
3238 msgid "I<cookie_close_function_t *close>"
3239 msgstr "I<cookie_close_function_t *close>"
3240
3241 #. type: Plain text
3242 #: build/C/man3/fopencookie.3:221
3243 msgid ""
3244 "This function closes the stream.  The hook function can do things such as "
3245 "freeing buffers allocated for the stream.  When called, it receives one "
3246 "argument:"
3247 msgstr ""
3248
3249 #. type: Plain text
3250 #: build/C/man3/fopencookie.3:223
3251 #, no-wrap
3252 msgid "    int close(void *cookie);\n"
3253 msgstr "    int close(void *cookie);\n"
3254
3255 #. type: Plain text
3256 #: build/C/man3/fopencookie.3:228
3257 msgid ""
3258 "The I<cookie> argument is the cookie that the programmer supplied when "
3259 "calling B<fopencookie>()."
3260 msgstr ""
3261
3262 #. type: Plain text
3263 #: build/C/man3/fopencookie.3:234
3264 msgid ""
3265 "As its function result, the I<close> function should return 0 on success, "
3266 "and B<EOF> on error."
3267 msgstr ""
3268
3269 #. type: Plain text
3270 #: build/C/man3/fopencookie.3:238
3271 msgid ""
3272 "If I<*close> is NULL, then no special action is performed when the stream is "
3273 "closed."
3274 msgstr ""
3275
3276 #.  .SH ERRORS
3277 #.  It's not clear if errno ever gets set...
3278 #. type: Plain text
3279 #: build/C/man3/fopencookie.3:245
3280 msgid ""
3281 "On success B<fopencookie>()  returns a pointer to the new stream.  On error, "
3282 "NULL is returned."
3283 msgstr ""
3284
3285 #. type: Plain text
3286 #: build/C/man3/fopencookie.3:247
3287 msgid "This function is a nonstandard GNU extension."
3288 msgstr ""
3289
3290 #. type: Plain text
3291 #: build/C/man3/fopencookie.3:256
3292 msgid ""
3293 "The program below implements a custom stream whose functionality is similar "
3294 "(but not identical) to that available via B<fmemopen>(3).  It implements a "
3295 "stream whose data is stored in a memory buffer.  The program writes its "
3296 "command-line arguments to the stream, and then seeks through the stream "
3297 "reading two out of every five characters and writing them to standard "
3298 "output.  The following shell session demonstrates the use of the program:"
3299 msgstr ""
3300
3301 #. type: Plain text
3302 #: build/C/man3/fopencookie.3:264
3303 #, no-wrap
3304 msgid ""
3305 "$B< ./a.out \\(aqhello world\\(aq>\n"
3306 "/he/\n"
3307 "/ w/\n"
3308 "/d/\n"
3309 "Reached end of file\n"
3310 msgstr ""
3311 "$B< ./a.out \\(aqhello world\\(aq>\n"
3312 "/he/\n"
3313 "/ w/\n"
3314 "/d/\n"
3315 "Reached end of file\n"
3316
3317 #. type: Plain text
3318 #: build/C/man3/fopencookie.3:271
3319 msgid ""
3320 "Note that a more general version of the program below could be improved to "
3321 "more robustly handle various error situations (e.g., opening a stream with a "
3322 "cookie that already has an open stream; closing a stream that has already "
3323 "been closed)."
3324 msgstr ""
3325
3326 #. type: Plain text
3327 #: build/C/man3/fopencookie.3:280
3328 #, no-wrap
3329 msgid ""
3330 "#define _GNU_SOURCE\n"
3331 "#include E<lt>sys/types.hE<gt>\n"
3332 "#include E<lt>stdio.hE<gt>\n"
3333 "#include E<lt>stdlib.hE<gt>\n"
3334 "#include E<lt>unistd.hE<gt>\n"
3335 "#include E<lt>string.hE<gt>\n"
3336 msgstr ""
3337 "#define _GNU_SOURCE\n"
3338 "#include E<lt>sys/types.hE<gt>\n"
3339 "#include E<lt>stdio.hE<gt>\n"
3340 "#include E<lt>stdlib.hE<gt>\n"
3341 "#include E<lt>unistd.hE<gt>\n"
3342 "#include E<lt>string.hE<gt>\n"
3343
3344 #. type: Plain text
3345 #: build/C/man3/fopencookie.3:282
3346 #, no-wrap
3347 msgid "#define INIT_BUF_SIZE 4\n"
3348 msgstr "#define INIT_BUF_SIZE 4\n"
3349
3350 #. type: Plain text
3351 #: build/C/man3/fopencookie.3:289
3352 #, no-wrap
3353 msgid ""
3354 "struct memfile_cookie {\n"
3355 "    char   *buf;        /* Dynamically sized buffer for data */\n"
3356 "    size_t  allocated;  /* Size of buf */\n"
3357 "    size_t  endpos;     /* Number of characters in buf */\n"
3358 "    off_t   offset;     /* Current file offset in buf */\n"
3359 "};\n"
3360 msgstr ""
3361 "struct memfile_cookie {\n"
3362 "    char   *buf;        /* Dynamically sized buffer for data */\n"
3363 "    size_t  allocated;  /* Size of buf */\n"
3364 "    size_t  endpos;     /* Number of characters in buf */\n"
3365 "    off_t   offset;     /* Current file offset in buf */\n"
3366 "};\n"
3367
3368 #. type: Plain text
3369 #: build/C/man3/fopencookie.3:295
3370 #, no-wrap
3371 msgid ""
3372 "ssize_t\n"
3373 "memfile_write(void *c, const char *buf, size_t size)\n"
3374 "{\n"
3375 "    char *new_buff;\n"
3376 "    struct memfile_cookie *cookie = c;\n"
3377 msgstr ""
3378 "ssize_t\n"
3379 "memfile_write(void *c, const char *buf, size_t size)\n"
3380 "{\n"
3381 "    char *new_buff;\n"
3382 "    struct memfile_cookie *cookie = c;\n"
3383
3384 #. type: Plain text
3385 #: build/C/man3/fopencookie.3:297
3386 #, no-wrap
3387 msgid "    /* Buffer too small? Keep doubling size until big enough */\n"
3388 msgstr "    /* Buffer too small? Keep doubling size until big enough */\n"
3389
3390 #. type: Plain text
3391 #: build/C/man3/fopencookie.3:307
3392 #, no-wrap
3393 msgid ""
3394 "    while (size + cookie-E<gt>offset E<gt> cookie-E<gt>allocated) {\n"
3395 "        new_buff = realloc(cookie-E<gt>buf, cookie-E<gt>allocated * 2);\n"
3396 "        if (new_buff == NULL) {\n"
3397 "            return -1;\n"
3398 "        } else {\n"
3399 "            cookie-E<gt>allocated *= 2;\n"
3400 "            cookie-E<gt>buf = new_buff;\n"
3401 "        }\n"
3402 "    }\n"
3403 msgstr ""
3404 "    while (size + cookie-E<gt>offset E<gt> cookie-E<gt>allocated) {\n"
3405 "        new_buff = realloc(cookie-E<gt>buf, cookie-E<gt>allocated * 2);\n"
3406 "        if (new_buff == NULL) {\n"
3407 "            return -1;\n"
3408 "        } else {\n"
3409 "            cookie-E<gt>allocated *= 2;\n"
3410 "            cookie-E<gt>buf = new_buff;\n"
3411 "        }\n"
3412 "    }\n"
3413
3414 #. type: Plain text
3415 #: build/C/man3/fopencookie.3:309
3416 #, no-wrap
3417 msgid "    memcpy(cookie-E<gt>buf + cookie-E<gt>offset, buf, size);\n"
3418 msgstr "    memcpy(cookie-E<gt>buf + cookie-E<gt>offset, buf, size);\n"
3419
3420 #. type: Plain text
3421 #: build/C/man3/fopencookie.3:313
3422 #, no-wrap
3423 msgid ""
3424 "    cookie-E<gt>offset += size;\n"
3425 "    if (cookie-E<gt>offset E<gt> cookie-E<gt>endpos)\n"
3426 "        cookie-E<gt>endpos = cookie-E<gt>offset;\n"
3427 msgstr ""
3428 "    cookie-E<gt>offset += size;\n"
3429 "    if (cookie-E<gt>offset E<gt> cookie-E<gt>endpos)\n"
3430 "        cookie-E<gt>endpos = cookie-E<gt>offset;\n"
3431
3432 #. type: Plain text
3433 #: build/C/man3/fopencookie.3:316
3434 #, no-wrap
3435 msgid ""
3436 "    return size;\n"
3437 "}\n"
3438 msgstr ""
3439 "    return size;\n"
3440 "}\n"
3441
3442 #. type: Plain text
3443 #: build/C/man3/fopencookie.3:322
3444 #, no-wrap
3445 msgid ""
3446 "ssize_t\n"
3447 "memfile_read(void *c, char *buf, size_t size)\n"
3448 "{\n"
3449 "    ssize_t xbytes;\n"
3450 "    struct memfile_cookie *cookie = c;\n"
3451 msgstr ""
3452 "ssize_t\n"
3453 "memfile_read(void *c, char *buf, size_t size)\n"
3454 "{\n"
3455 "    ssize_t xbytes;\n"
3456 "    struct memfile_cookie *cookie = c;\n"
3457
3458 #. type: Plain text
3459 #: build/C/man3/fopencookie.3:324
3460 #, no-wrap
3461 msgid "    /* Fetch minimum of bytes requested and bytes available */\n"
3462 msgstr "    /* Fetch minimum of bytes requested and bytes available */\n"
3463
3464 #. type: Plain text
3465 #: build/C/man3/fopencookie.3:330
3466 #, no-wrap
3467 msgid ""
3468 "    xbytes = size;\n"
3469 "    if (cookie-E<gt>offset + size E<gt> cookie-E<gt>endpos)\n"
3470 "        xbytes = cookie-E<gt>endpos - cookie-E<gt>offset;\n"
3471 "    if (xbytes E<lt> 0)     /* offset may be past endpos */\n"
3472 "       xbytes = 0;\n"
3473 msgstr ""
3474 "    xbytes = size;\n"
3475 "    if (cookie-E<gt>offset + size E<gt> cookie-E<gt>endpos)\n"
3476 "        xbytes = cookie-E<gt>endpos - cookie-E<gt>offset;\n"
3477 "    if (xbytes E<lt> 0)     /* offset may be past endpos */\n"
3478 "       xbytes = 0;\n"
3479
3480 #. type: Plain text
3481 #: build/C/man3/fopencookie.3:332
3482 #, no-wrap
3483 msgid "    memcpy(buf, cookie-E<gt>buf + cookie-E<gt>offset, xbytes);\n"
3484 msgstr "    memcpy(buf, cookie-E<gt>buf + cookie-E<gt>offset, xbytes);\n"
3485
3486 #. type: Plain text
3487 #: build/C/man3/fopencookie.3:336
3488 #, no-wrap
3489 msgid ""
3490 "    cookie-E<gt>offset += xbytes;\n"
3491 "    return xbytes;\n"
3492 "}\n"
3493 msgstr ""
3494 "    cookie-E<gt>offset += xbytes;\n"
3495 "    return xbytes;\n"
3496 "}\n"
3497
3498 #. type: Plain text
3499 #: build/C/man3/fopencookie.3:342
3500 #, no-wrap
3501 msgid ""
3502 "int\n"
3503 "memfile_seek(void *c, off64_t *offset, int whence)\n"
3504 "{\n"
3505 "    off64_t new_offset;\n"
3506 "    struct memfile_cookie *cookie = c;\n"
3507 msgstr ""
3508 "int\n"
3509 "memfile_seek(void *c, off64_t *offset, int whence)\n"
3510 "{\n"
3511 "    off64_t new_offset;\n"
3512 "    struct memfile_cookie *cookie = c;\n"
3513
3514 #. type: Plain text
3515 #: build/C/man3/fopencookie.3:351
3516 #, no-wrap
3517 msgid ""
3518 "    if (whence == SEEK_SET)\n"
3519 "        new_offset = *offset;\n"
3520 "    else if (whence == SEEK_END)\n"
3521 "        new_offset = cookie-E<gt>endpos + *offset;\n"
3522 "    else if (whence == SEEK_CUR)\n"
3523 "        new_offset = cookie-E<gt>offset + *offset;\n"
3524 "    else\n"
3525 "        return -1;\n"
3526 msgstr ""
3527 "    if (whence == SEEK_SET)\n"
3528 "        new_offset = *offset;\n"
3529 "    else if (whence == SEEK_END)\n"
3530 "        new_offset = cookie-E<gt>endpos + *offset;\n"
3531 "    else if (whence == SEEK_CUR)\n"
3532 "        new_offset = cookie-E<gt>offset + *offset;\n"
3533 "    else\n"
3534 "        return -1;\n"
3535
3536 #. type: Plain text
3537 #: build/C/man3/fopencookie.3:354
3538 #, no-wrap
3539 msgid ""
3540 "    if (new_offset E<lt> 0)\n"
3541 "        return -1;\n"
3542 msgstr ""
3543 "    if (new_offset E<lt> 0)\n"
3544 "        return -1;\n"
3545
3546 #. type: Plain text
3547 #: build/C/man3/fopencookie.3:359
3548 #, no-wrap
3549 msgid ""
3550 "    cookie-E<gt>offset = new_offset;\n"
3551 "    *offset = new_offset;\n"
3552 "    return 0;\n"
3553 "}\n"
3554 msgstr ""
3555 "    cookie-E<gt>offset = new_offset;\n"
3556 "    *offset = new_offset;\n"
3557 "    return 0;\n"
3558 "}\n"
3559
3560 #. type: Plain text
3561 #: build/C/man3/fopencookie.3:364
3562 #, no-wrap
3563 msgid ""
3564 "int\n"
3565 "memfile_close(void *c)\n"
3566 "{\n"
3567 "    struct memfile_cookie *cookie = c;\n"
3568 msgstr ""
3569 "int\n"
3570 "memfile_close(void *c)\n"
3571 "{\n"
3572 "    struct memfile_cookie *cookie = c;\n"
3573
3574 #. type: Plain text
3575 #: build/C/man3/fopencookie.3:368
3576 #, no-wrap
3577 msgid ""
3578 "    free(cookie-E<gt>buf);\n"
3579 "    cookie-E<gt>allocated = 0;\n"
3580 "    cookie-E<gt>buf = NULL;\n"
3581 msgstr ""
3582 "    free(cookie-E<gt>buf);\n"
3583 "    cookie-E<gt>allocated = 0;\n"
3584 "    cookie-E<gt>buf = NULL;\n"
3585
3586 #. type: Plain text
3587 #: build/C/man3/fopencookie.3:371
3588 #, no-wrap
3589 msgid ""
3590 "    return 0;\n"
3591 "}\n"
3592 msgstr ""
3593 "    return 0;\n"
3594 "}\n"
3595
3596 #. type: Plain text
3597 #: build/C/man3/fopencookie.3:387
3598 #, no-wrap
3599 msgid ""
3600 "int\n"
3601 "main(int argc, char *argv[])\n"
3602 "{\n"
3603 "    cookie_io_functions_t  memfile_func = {\n"
3604 "        .read  = memfile_read,\n"
3605 "        .write = memfile_write,\n"
3606 "        .seek  = memfile_seek,\n"
3607 "        .close = memfile_close\n"
3608 "    };\n"
3609 "    FILE *fp;\n"
3610 "    struct memfile_cookie mycookie;\n"
3611 "    ssize_t nread;\n"
3612 "    long p;\n"
3613 "    int j;\n"
3614 "    char buf[1000];\n"
3615 msgstr ""
3616 "int\n"
3617 "main(int argc, char *argv[])\n"
3618 "{\n"
3619 "    cookie_io_functions_t  memfile_func = {\n"
3620 "        .read  = memfile_read,\n"
3621 "        .write = memfile_write,\n"
3622 "        .seek  = memfile_seek,\n"
3623 "        .close = memfile_close\n"
3624 "    };\n"
3625 "    FILE *fp;\n"
3626 "    struct memfile_cookie mycookie;\n"
3627 "    ssize_t nread;\n"
3628 "    long p;\n"
3629 "    int j;\n"
3630 "    char buf[1000];\n"
3631
3632 #. type: Plain text
3633 #: build/C/man3/fopencookie.3:389
3634 #, no-wrap
3635 msgid "    /* Set up the cookie before calling fopencookie() */\n"
3636 msgstr "    /* Set up the cookie before calling fopencookie() */\n"
3637
3638 #. type: Plain text
3639 #: build/C/man3/fopencookie.3:395
3640 #, no-wrap
3641 msgid ""
3642 "    mycookie.buf = malloc(INIT_BUF_SIZE);\n"
3643 "    if (mycookie.buf == NULL) {\n"
3644 "        perror(\"malloc\");\n"
3645 "        exit(EXIT_FAILURE);\n"
3646 "    }\n"
3647 msgstr ""
3648 "    mycookie.buf = malloc(INIT_BUF_SIZE);\n"
3649 "    if (mycookie.buf == NULL) {\n"
3650 "        perror(\"malloc\");\n"
3651 "        exit(EXIT_FAILURE);\n"
3652 "    }\n"
3653
3654 #. type: Plain text
3655 #: build/C/man3/fopencookie.3:399
3656 #, no-wrap
3657 msgid ""
3658 "    mycookie.allocated = INIT_BUF_SIZE;\n"
3659 "    mycookie.offset = 0;\n"
3660 "    mycookie.endpos = 0;\n"
3661 msgstr ""
3662 "    mycookie.allocated = INIT_BUF_SIZE;\n"
3663 "    mycookie.offset = 0;\n"
3664 "    mycookie.endpos = 0;\n"
3665
3666 #. type: Plain text
3667 #: build/C/man3/fopencookie.3:405
3668 #, no-wrap
3669 msgid ""
3670 "    fp = fopencookie(&mycookie,\"w+\", memfile_func);\n"
3671 "    if (fp == NULL) {\n"
3672 "        perror(\"fopencookie\");\n"
3673 "        exit(EXIT_FAILURE);\n"
3674 "    }\n"
3675 msgstr ""
3676 "    fp = fopencookie(&mycookie,\"w+\", memfile_func);\n"
3677 "    if (fp == NULL) {\n"
3678 "        perror(\"fopencookie\");\n"
3679 "        exit(EXIT_FAILURE);\n"
3680 "    }\n"
3681
3682 #. type: Plain text
3683 #: build/C/man3/fopencookie.3:407
3684 #, no-wrap
3685 msgid "    /* Write command-line arguments to our file */\n"
3686 msgstr "    /* Write command-line arguments to our file */\n"
3687
3688 #. type: Plain text
3689 #: build/C/man3/fopencookie.3:413
3690 #, no-wrap
3691 msgid ""
3692 "    for (j = 1; j E<lt> argc; j++)\n"
3693 "        if (fputs(argv[j], fp) == EOF) {\n"
3694 "            perror(\"fputs\");\n"
3695 "            exit(EXIT_FAILURE);\n"
3696 "        }\n"
3697 msgstr ""
3698 "    for (j = 1; j E<lt> argc; j++)\n"
3699 "        if (fputs(argv[j], fp) == EOF) {\n"
3700 "            perror(\"fputs\");\n"
3701 "            exit(EXIT_FAILURE);\n"
3702 "        }\n"
3703
3704 #. type: Plain text
3705 #: build/C/man3/fopencookie.3:415
3706 #, no-wrap
3707 msgid "    /* Read two bytes out of every five, until EOF */\n"
3708 msgstr "    /* Read two bytes out of every five, until EOF */\n"
3709
3710 #. type: Plain text
3711 #: build/C/man3/fopencookie.3:430
3712 #, no-wrap
3713 msgid ""
3714 "    for (p = 0; ; p += 5) {\n"
3715 "        if (fseek(fp, p, SEEK_SET) == -1) {\n"
3716 "            perror(\"fseek\");\n"
3717 "            exit(EXIT_FAILURE);\n"
3718 "        }\n"
3719 "        nread = fread(buf, 1, 2, fp);\n"
3720 "        if (nread == -1) {\n"
3721 "            perror(\"fread\");\n"
3722 "            exit(EXIT_FAILURE);\n"
3723 "        }\n"
3724 "        if (nread == 0) {\n"
3725 "            printf(\"Reached end of file\\en\");\n"
3726 "            break;\n"
3727 "        }\n"
3728 msgstr ""
3729 "    for (p = 0; ; p += 5) {\n"
3730 "        if (fseek(fp, p, SEEK_SET) == -1) {\n"
3731 "            perror(\"fseek\");\n"
3732 "            exit(EXIT_FAILURE);\n"
3733 "        }\n"
3734 "        nread = fread(buf, 1, 2, fp);\n"
3735 "        if (nread == -1) {\n"
3736 "            perror(\"fread\");\n"
3737 "            exit(EXIT_FAILURE);\n"
3738 "        }\n"
3739 "        if (nread == 0) {\n"
3740 "            printf(\"Reached end of file\\en\");\n"
3741 "            break;\n"
3742 "        }\n"
3743
3744 #. type: Plain text
3745 #: build/C/man3/fopencookie.3:433
3746 #, no-wrap
3747 msgid ""
3748 "        printf(\"/%.*s/\\en\", nread, buf);\n"
3749 "    }\n"
3750 msgstr ""
3751 "        printf(\"/%.*s/\\en\", nread, buf);\n"
3752 "    }\n"
3753
3754 #. type: Plain text
3755 #: build/C/man3/fopencookie.3:436 build/C/man2/readlink.2:213
3756 #, no-wrap
3757 msgid ""
3758 "    exit(EXIT_SUCCESS);\n"
3759 "}\n"
3760 msgstr ""
3761 "    exit(EXIT_SUCCESS);\n"
3762 "}\n"
3763
3764 #. type: Plain text
3765 #: build/C/man3/fopencookie.3:442
3766 msgid "B<fclose>(3), B<fmemopen>(3), B<fopen>(3), B<fseek>(3)"
3767 msgstr "B<fclose>(3), B<fmemopen>(3), B<fopen>(3), B<fseek>(3)"
3768
3769 #. type: TH
3770 #: build/C/man3/fpurge.3:25
3771 #, no-wrap
3772 msgid "FPURGE"
3773 msgstr "FPURGE"
3774
3775 #. type: TH
3776 #: build/C/man3/fpurge.3:25
3777 #, no-wrap
3778 msgid "2001-12-15"
3779 msgstr "2001-12-15"
3780
3781 #. type: Plain text
3782 #: build/C/man3/fpurge.3:28
3783 msgid "fpurge, __fpurge - purge a stream"
3784 msgstr "fpurge, __fpurge - ストリームを一掃 (purge) する"
3785
3786 #. type: Plain text
3787 #: build/C/man3/fpurge.3:32
3788 #, no-wrap
3789 msgid ""
3790 "/* unsupported */\n"
3791 "B<#include E<lt>stdio.hE<gt>>\n"
3792 msgstr ""
3793 "/* unsupported */\n"
3794 "B<#include E<lt>stdio.hE<gt>>\n"
3795
3796 #. type: Plain text
3797 #: build/C/man3/fpurge.3:34
3798 #, no-wrap
3799 msgid "B<int fpurge(FILE *>I<stream>B<);>\n"
3800 msgstr "B<int fpurge(FILE *>I<stream>B<);>\n"
3801
3802 #. type: Plain text
3803 #: build/C/man3/fpurge.3:37
3804 #, no-wrap
3805 msgid ""
3806 "/* supported */\n"
3807 "B<#include E<lt>stdio.hE<gt>>\n"
3808 msgstr ""
3809 "/* supported */\n"
3810 "B<#include E<lt>stdio.hE<gt>>\n"
3811
3812 #. type: Plain text
3813 #: build/C/man3/fpurge.3:39
3814 #, no-wrap
3815 msgid "B<#include E<lt>stdio_ext.hE<gt>>\n"
3816 msgstr "B<#include E<lt>stdio_ext.hE<gt>>\n"
3817
3818 #. type: Plain text
3819 #: build/C/man3/fpurge.3:41
3820 #, no-wrap
3821 msgid "B<void  __fpurge(FILE *>I<stream>B<);>\n"
3822 msgstr "B<void  __fpurge(FILE *>I<stream>B<);>\n"
3823
3824 #. type: Plain text
3825 #: build/C/man3/fpurge.3:54
3826 msgid ""
3827 "The function B<fpurge>()  clears the buffers of the given stream.  For "
3828 "output streams this discards any unwritten output.  For input streams this "
3829 "discards any input read from the underlying object but not yet obtained via "
3830 "B<getc>(3); this includes any text pushed back via B<ungetc>(3).  See also "
3831 "B<fflush>(3)."
3832 msgstr ""
3833 "B<fpurge>()  関数は、与えられたストリームのバッファをクリアする。 出力スト"
3834 "リームでこれを行うと、書き出されていない出力は捨てられる。 入力ストリームでこ"
3835 "れを行うと、 下層にあるオブジェクトから読み込まれ B<getc>(3)  による取得を"
3836 "待っている入力が、すべて捨てられる。 これには B<ungetc>(3)  によって戻された"
3837 "テキストも含まれる。 B<fflush>(3)  も参照のこと。"
3838
3839 #. type: Plain text
3840 #: build/C/man3/fpurge.3:58
3841 msgid ""
3842 "The function B<__fpurge>()  does precisely the same, but without returning a "
3843 "value."
3844 msgstr "B<__fpurge>()  関数も全く同じことを行うが、ただし返り値を返さない。"
3845
3846 #. type: Plain text
3847 #: build/C/man3/fpurge.3:65
3848 msgid ""
3849 "Upon successful completion B<fpurge>()  returns 0.  On error, it returns -1 "
3850 "and sets I<errno> appropriately."
3851 msgstr ""
3852 "成功すると B<fpurge>()  は 0 を返す。 エラーが起こると -1 を返し、 I<errno> "
3853 "を適切な値に設定する。"
3854
3855 #. type: Plain text
3856 #: build/C/man3/fpurge.3:70
3857 msgid "I<stream> is not an open stream."
3858 msgstr "I<stream> がオープンされていない。"
3859
3860 #. type: Plain text
3861 #: build/C/man3/fpurge.3:78
3862 msgid ""
3863 "These functions are nonstandard and not portable.  The function B<fpurge>()  "
3864 "was introduced in 4.4BSD and is not available under Linux.  The function "
3865 "B<__fpurge>()  was introduced in Solaris, and is present in glibc 2.1.95 and "
3866 "later."
3867 msgstr ""
3868 "これらの関数は標準ではなく、よって移植性もない。 B<fpurge>()  関数は 4.4BSD "
3869 "で導入されたが、Linux では利用できない。 B<__fpurge>()  関数は Solaris で導入"
3870 "され、glibc 2.1.95 以降には存在している。"
3871
3872 #. type: Plain text
3873 #: build/C/man3/fpurge.3:80
3874 msgid "Usually it is a mistake to want to discard input buffers."
3875 msgstr "通常は入力バッファを捨てようとするのは間違っている。"
3876
3877 #.  .BR fclean (3),
3878 #. type: Plain text
3879 #: build/C/man3/fpurge.3:85
3880 msgid "B<fflush>(3), B<setbuf>(3), B<stdio_ext>(3)"
3881 msgstr "B<fflush>(3), B<setbuf>(3), B<stdio_ext>(3)"
3882
3883 #. type: TH
3884 #: build/C/man3/fputwc.3:16
3885 #, no-wrap
3886 msgid "FPUTWC"
3887 msgstr "FPUTWC"
3888
3889 #. type: Plain text
3890 #: build/C/man3/fputwc.3:19
3891 msgid "fputwc, putwc - write a wide character to a FILE stream"
3892 msgstr "fputwc, putwc - ワイド文字を FILE ストリームに書き込む"
3893
3894 #. type: Plain text
3895 #: build/C/man3/fputwc.3:27
3896 #, no-wrap
3897 msgid ""
3898 "B<wint_t fputwc(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
3899 "B<wint_t putwc(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
3900 msgstr ""
3901 "B<wint_t fputwc(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
3902 "B<wint_t putwc(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
3903
3904 #. type: Plain text
3905 #: build/C/man3/fputwc.3:43
3906 msgid ""
3907 "The B<fputwc>()  function is the wide-character equivalent of the B<fputc>"
3908 "(3)  function.  It writes the wide character I<wc> to I<stream>.  If I<ferror"
3909 "(stream)> becomes true, it returns B<WEOF>.  If a wide-character conversion "
3910 "error occurs, it sets I<errno> to B<EILSEQ> and returns B<WEOF>.  Otherwise "
3911 "it returns I<wc>."
3912 msgstr ""
3913 "B<fputwc>()  関数は、 B<fputc>(3)  に対応するワイド文字関数である。この 関数"
3914 "は、ワイド文字 I<wc> を I<stream> に書き込む。 I<ferror(stream)> が真になる"
3915 "と、この関数は B<WEOF> を返す。 ワイド文字変換でエラーが発生した場合は、 "
3916 "I<errno> に B<EILSEQ> をセットし、 B<WEOF> を返す。 それ以外の場合では、この"
3917 "関数は I<wc> を返す。"
3918
3919 #. type: Plain text
3920 #: build/C/man3/fputwc.3:51
3921 msgid ""
3922 "The B<putwc>()  function or macro functions identically to B<fputwc>().  It "
3923 "may be implemented as a macro, and may evaluate its argument more than "
3924 "once.  There is no reason ever to use it."
3925 msgstr ""
3926 "B<putwc>()  関数あるいはマクロは、 B<fputwc>()  と全く同じ動作をする。 この関"
3927 "数はマクロとして実装されるかもしれないので、引き数が複数回評価さ れるかもしれ"
3928 "ない。この関数を使う理由はもはや存在しない。"
3929
3930 #. type: Plain text
3931 #: build/C/man3/fputwc.3:63
3932 msgid ""
3933 "The B<fputwc>()  function returns I<wc> if no error occurred, or B<WEOF> to "
3934 "indicate an error.  In the event of an error, I<errno> is set to indicate "
3935 "the cause."
3936 msgstr "B<fputwc>()  関数は、エラーが起きなければ I<wc> を返す。エラーの場合には B<WEOF> が返り、 I<errno> にエラーの原因を示す値が設定される。"
3937
3938 #. type: Plain text
3939 #: build/C/man3/fputwc.3:68
3940 msgid "Conversion of I<wc> to the stream's encoding fails."
3941 msgstr "I<wc> からストリームの符号への変換に失敗した。"
3942
3943 #. type: Plain text
3944 #: build/C/man3/fputwc.3:77
3945 msgid ""
3946 "The behavior of B<fputwc>()  depends on the B<LC_CTYPE> category of the "
3947 "current locale."
3948 msgstr "B<fputwc>()  の動作は現在のロケールの B<LC_CTYPE> カテゴリに依存する。"
3949
3950 #. type: Plain text
3951 #: build/C/man3/fputwc.3:85
3952 msgid ""
3953 "In the absence of additional information passed to the B<fopen>(3)  call, it "
3954 "is reasonable to expect that B<fputwc>()  will actually write the multibyte "
3955 "sequence corresponding to the wide character I<wc>."
3956 msgstr ""
3957 "B<fopen>(3)  システムコールに渡す追加情報がない場合には、 B<fputwc>()  は 実"
3958 "際にはワイド文字 I<wc> に対応するマルチバイトシーケンスを書き込むと 期待して"
3959 "よい。"
3960
3961 #. type: Plain text
3962 #: build/C/man3/fputwc.3:89
3963 msgid "B<fgetwc>(3), B<fputws>(3), B<unlocked_stdio>(3)"
3964 msgstr "B<fgetwc>(3), B<fputws>(3), B<unlocked_stdio>(3)"
3965
3966 #. type: TH
3967 #: build/C/man3/fread.3:45
3968 #, no-wrap
3969 msgid "FREAD"
3970 msgstr "FREAD"
3971
3972 #. type: TH
3973 #: build/C/man3/fread.3:45
3974 #, no-wrap
3975 msgid "2012-03-30"
3976 msgstr "2012-03-30"
3977
3978 #. type: Plain text
3979 #: build/C/man3/fread.3:48
3980 msgid "fread, fwrite - binary stream input/output"
3981 msgstr "fread, fwrite - バイナリストリームの入出力"
3982
3983 #. type: Plain text
3984 #: build/C/man3/fread.3:54
3985 #, no-wrap
3986 msgid "B<size_t fread(void *>I<ptr>B<, size_t >I<size>B<, size_t >I<nmemb>B<, FILE *>I<stream>B<);>\n"
3987 msgstr "B<size_t fread(void *>I<ptr>B<, size_t >I<size>B<, size_t >I<nmemb>B<, FILE *>I<stream>B<);>\n"
3988
3989 #. type: Plain text
3990 #: build/C/man3/fread.3:57
3991 #, no-wrap
3992 msgid ""
3993 "B<size_t fwrite(const void *>I<ptr>B<, size_t >I<size>B<, size_t >I<nmemb>B<,>\n"
3994 "B<              FILE *>I<stream>B<);>\n"
3995 msgstr ""
3996 "B<size_t fwrite(const void *>I<ptr>B<, size_t >I<size>B<, size_t >I<nmemb>B<,>\n"
3997 "B<              FILE *>I<stream>B<);>\n"
3998
3999 #. type: Plain text
4000 #: build/C/man3/fread.3:69
4001 msgid ""
4002 "The function B<fread>()  reads I<nmemb> elements of data, each I<size> bytes "
4003 "long, from the stream pointed to by I<stream>, storing them at the location "
4004 "given by I<ptr>."
4005 msgstr ""
4006 "B<fread>()  関数は I<stream> ポインタで指定されたストリームから I<nmemb> 個の"
4007 "データを読み込み、 I<ptr> で与えられた場所に格納する。 個々のデータは "
4008 "I<size> バイトの長さを持つ。"
4009
4010 #. type: Plain text
4011 #: build/C/man3/fread.3:80
4012 msgid ""
4013 "The function B<fwrite>()  writes I<nmemb> elements of data, each I<size> "
4014 "bytes long, to the stream pointed to by I<stream>, obtaining them from the "
4015 "location given by I<ptr>."
4016 msgstr ""
4017 "B<fwrite>()  関数は I<ptr> で指定された場所から得た I<nmemb> 個のデータを、 "
4018 "I<stream> ポインタで指定されたストリームに書き込む。 個々のデータは I<size> "
4019 "バイトの長さを持つ。"
4020
4021 #. type: Plain text
4022 #: build/C/man3/fread.3:96
4023 msgid ""
4024 "On success, B<fread>()  and B<fwrite>()  return the number of I<items> read "
4025 "or written.  This number equals the number of bytes transferred only when "
4026 "I<size> is 1.  If an error occurs, or the end of the file is reached, the "
4027 "return value is a short item count (or zero)."
4028 msgstr ""
4029 "成功すると、 B<fread>() と B<fwrite>() は読み書きを行った要素の個数を返す。\n"
4030 "I<size> が 1 の場合は、この数字は転送されたバイト数と等しい。\n"
4031 "エラーが生じた場合や、ファイルの末尾 (end-of-file) に達した場合、\n"
4032 "返り値は指定した個数よりも小さい値 (または 0) となる。"
4033
4034 #. type: Plain text
4035 #: build/C/man3/fread.3:103
4036 msgid ""
4037 "B<fread>()  does not distinguish between end-of-file and error, and callers "
4038 "must use B<feof>(3)  and B<ferror>(3)  to determine which occurred."
4039 msgstr ""
4040 "B<fread>()  は end-of-file とエラーを区別しないので、 どちらが生じたかを判断"
4041 "するためには、 呼び出し側で B<feof>(3)  と B<ferror>(3)  とを使用しなければな"
4042 "らない。"
4043
4044 #. type: Plain text
4045 #: build/C/man3/fread.3:105
4046 msgid "C89, POSIX.1-2001."
4047 msgstr "C89, POSIX.1-2001."
4048
4049 #. type: Plain text
4050 #: build/C/man3/fread.3:111
4051 msgid "B<read>(2), B<write>(2), B<feof>(3), B<ferror>(3), B<unlocked_stdio>(3)"
4052 msgstr ""
4053 "B<read>(2), B<write>(2), B<feof>(3), B<ferror>(3), B<unlocked_stdio>(3)"
4054
4055 #. type: TH
4056 #: build/C/man3/fseek.3:42
4057 #, no-wrap
4058 msgid "FSEEK"
4059 msgstr "FSEEK"
4060
4061 #. type: TH
4062 #: build/C/man3/fseek.3:42
4063 #, no-wrap
4064 msgid "1993-11-29"
4065 msgstr "1993-11-29"
4066
4067 #. type: Plain text
4068 #: build/C/man3/fseek.3:45
4069 msgid "fgetpos, fseek, fsetpos, ftell, rewind - reposition a stream"
4070 msgstr "fgetpos, fseek, fsetpos, ftell, rewind - ストリームの位置を変更する"
4071
4072 #. type: Plain text
4073 #: build/C/man3/fseek.3:49
4074 msgid "B<int fseek(FILE *>I<stream>B<, long >I<offset>B<, int >I<whence>B<);>"
4075 msgstr "B<int fseek(FILE *>I<stream>B<, long >I<offset>B<, int >I<whence>B<);>"
4076
4077 #. type: Plain text
4078 #: build/C/man3/fseek.3:51
4079 msgid "B<long ftell(FILE *>I<stream>B<);>"
4080 msgstr "B<long ftell(FILE *>I<stream>B<);>"
4081
4082 #. type: Plain text
4083 #: build/C/man3/fseek.3:53
4084 msgid "B<void rewind(FILE *>I<stream>B<);>"
4085 msgstr "B<void rewind(FILE *>I<stream>B<);>"
4086
4087 #. type: Plain text
4088 #: build/C/man3/fseek.3:55
4089 msgid "B<int fgetpos(FILE *>I<stream>B<, fpos_t *>I<pos>B<);>"
4090 msgstr "B<int fgetpos(FILE *>I<stream>B<, fpos_t *>I<pos>B<);>"
4091
4092 #. type: Plain text
4093 #: build/C/man3/fseek.3:57
4094 msgid "B<int fsetpos(FILE *>I<stream>B<, fpos_t *>I<pos>B<);>"
4095 msgstr "B<int fsetpos(FILE *>I<stream>B<, fpos_t *>I<pos>B<);>"
4096
4097 #. type: Plain text
4098 #: build/C/man3/fseek.3:81
4099 msgid ""
4100 "The B<fseek>()  function sets the file position indicator for the stream "
4101 "pointed to by I<stream>.  The new position, measured in bytes, is obtained "
4102 "by adding I<offset> bytes to the position specified by I<whence>.  If "
4103 "I<whence> is set to B<SEEK_SET>, B<SEEK_CUR>, or B<SEEK_END>, the offset is "
4104 "relative to the start of the file, the current position indicator, or end-of-"
4105 "file, respectively.  A successful call to the B<fseek>()  function clears "
4106 "the end-of-file indicator for the stream and undoes any effects of the "
4107 "B<ungetc>(3)  function on the same stream."
4108 msgstr ""
4109 "B<fseek>()  関数は I<stream> によって指定されたストリームにおいて、ファイル位"
4110 "置表示子 (file position indicator) をセットする。新たな位置 (バイト単位)  は "
4111 "I<whence> で指定された位置に I<offset> バイトを加えることによって与えられ"
4112 "る。 I<whence> が B<SEEK_SET>, B<SEEK_CUR>, B<SEEK_END> のどれかになっている"
4113 "場合は、それぞれファイルの先頭、現在の位置表示子、 ファイルの末尾からのオフ"
4114 "セットが取られる。 B<fseek>()  関数の呼び出しが成功すると、ストリームの end-"
4115 "of-file 表示子は クリアされ、それまでに B<ungetc>(3)  関数で戻したデータはな"
4116 "かったことになる。"
4117
4118 #. type: Plain text
4119 #: build/C/man3/fseek.3:87
4120 msgid ""
4121 "The B<ftell>()  function obtains the current value of the file position "
4122 "indicator for the stream pointed to by I<stream>."
4123 msgstr ""
4124 "B<ftell>()  関数は I<stream> によって指定されたストリームにおける、ファイル位"
4125 "置表示子 の現時点での値を与える。"
4126
4127 #. type: Plain text
4128 #: build/C/man3/fseek.3:94
4129 msgid ""
4130 "The B<rewind>()  function sets the file position indicator for the stream "
4131 "pointed to by I<stream> to the beginning of the file.  It is equivalent to:"
4132 msgstr ""
4133 "B<rewind>()  関数は I<stream> によって指定されたストリームにおいて、ファイル"
4134 "位置表示子 をファイルの先頭にセットする。この関数は以下と等価である。"
4135
4136 #. type: Plain text
4137 #: build/C/man3/fseek.3:97
4138 msgid "(void) fseek(stream, 0L, SEEK_SET)"
4139 msgstr "(void) fseek(stream, 0L, SEEK_SET)"
4140
4141 #. type: Plain text
4142 #: build/C/man3/fseek.3:101
4143 msgid ""
4144 "except that the error indicator for the stream is also cleared (see "
4145 "B<clearerr>(3))."
4146 msgstr ""
4147 "ただし B<rewind>()  ではストリームに対するエラー表示子 (error indicator) も同"
4148 "時に クリアされる ( B<clearerr>(3)  を見よ)。"
4149
4150 #. type: Plain text
4151 #: build/C/man3/fseek.3:121
4152 msgid ""
4153 "The B<fgetpos>()  and B<fsetpos>()  functions are alternate interfaces "
4154 "equivalent to B<ftell>()  and B<fseek>()  (with I<whence> set to "
4155 "B<SEEK_SET>), setting and storing the current value of the file offset into "
4156 "or from the object referenced by I<pos>.  On some non-UNIX systems, an "
4157 "I<fpos_t> object may be a complex object and these routines may be the only "
4158 "way to portably reposition a text stream."
4159 msgstr ""
4160 "B<fgetpos>()  関数と B<fsetpos>()  関数は、それぞれ B<ftell>()  と B<fseek>"
4161 "()  で I<whence> に B<SEEK_SET> を指定した場合と同様の機能を、異なるインター"
4162 "フェースで提供する。 B<fgetpos>()  はファイルオフセットの現在の値を I<pos> が"
4163 "参照するオブジェクトに保存し、 B<fsetpos>()  はファイルオフセットを I<pos> に"
4164 "設定する。 UNIX 以外のシステムにおいては、 I<fpos_t> が構造体などの複雑なオブ"
4165 "ジェクトになっていて、これらのルーチンがテキス トストリームでファイル位置を変"
4166 "更する方法のうち、移植性のある唯一のもの になっている場合もある。"
4167
4168 #. type: Plain text
4169 #: build/C/man3/fseek.3:136
4170 msgid ""
4171 "The B<rewind>()  function returns no value.  Upon successful completion, "
4172 "B<fgetpos>(), B<fseek>(), B<fsetpos>()  return 0, and B<ftell>()  returns "
4173 "the current offset.  Otherwise, -1 is returned and I<errno> is set to "
4174 "indicate the error."
4175 msgstr ""
4176 "B<rewind>()  は返り値を持たない。 B<fgetpos>(), B<fseek>(), B<fsetpos>()  は"
4177 "成功すると 0 を返す。 B<ftell>()  は現在のオフセットを返す。失敗した場合は返"
4178 "り値は -1 となり、 I<errno> にエラーを示す値がセットされる。"
4179
4180 #. type: Plain text
4181 #: build/C/man3/fseek.3:142
4182 msgid "The I<stream> specified is not a seekable stream."
4183 msgstr "指定した I<stream> がシークできない。"
4184
4185 #. type: Plain text
4186 #: build/C/man3/fseek.3:153
4187 msgid ""
4188 "The I<whence> argument to B<fseek>()  was not B<SEEK_SET>, B<SEEK_END>, or "
4189 "B<SEEK_CUR>."
4190 msgstr ""
4191 "B<fseek>()  関数に対して与えた I<whence> 引数が B<SEEK_SET>, B<SEEK_END>, "
4192 "B<SEEK_CUR> 以外の値であった。"
4193
4194 #. type: Plain text
4195 #: build/C/man3/fseek.3:168
4196 msgid ""
4197 "The functions B<fgetpos>(), B<fseek>(), B<fsetpos>(), and B<ftell>()  may "
4198 "also fail and set I<errno> for any of the errors specified for the routines "
4199 "B<fflush>(3), B<fstat>(2), B<lseek>(2), and B<malloc>(3)."
4200 msgstr ""
4201 "B<fgetpos>(), B<fseek>(), B<fsetpos>(), B<ftell>()  は、それぞれ B<fflush>"
4202 "(3), B<fstat>(2), B<lseek>(2), B<malloc>(3)  などのルーチンを呼び出す際に失敗"
4203 "する可能性がある。この場合は それぞれ対応した I<errno> が設定される。"
4204
4205 #. type: Plain text
4206 #: build/C/man3/fseek.3:173
4207 msgid "B<lseek>(2), B<fseeko>(3)"
4208 msgstr "B<lseek>(2), B<fseeko>(3)"
4209
4210 #. type: TH
4211 #: build/C/man3/fseeko.3:25
4212 #, no-wrap
4213 msgid "FSEEKO"
4214 msgstr "FSEEKO"
4215
4216 #. type: TH
4217 #: build/C/man3/fseeko.3:25
4218 #, no-wrap
4219 msgid "2001-11-05"
4220 msgstr "2001-11-05"
4221
4222 #. type: Plain text
4223 #: build/C/man3/fseeko.3:28
4224 msgid "fseeko, ftello - seek to or report file position"
4225 msgstr "fseeko, ftello - ファイル位置を探す/報告する"
4226
4227 #. type: Plain text
4228 #: build/C/man3/fseeko.3:33
4229 #, no-wrap
4230 msgid "B<int fseeko(FILE *>I<stream>B<, off_t >I<offset>B<, int >I<whence>B<);>\n"
4231 msgstr "B<int fseeko(FILE *>I<stream>B<, off_t >I<offset>B<, int >I<whence>B<);>\n"
4232
4233 #. type: Plain text
4234 #: build/C/man3/fseeko.3:36
4235 #, no-wrap
4236 msgid ""
4237 "B<off_t ftello(FILE *>I<stream>B<);>\n"
4238 "\n"
4239 msgstr ""
4240 "B<off_t ftello(FILE *>I<stream>B<);>\n"
4241 "\n"
4242
4243 #. type: Plain text
4244 #: build/C/man3/fseeko.3:58
4245 msgid ""
4246 "The B<fseeko>()  and B<ftello>()  functions are identical to B<fseek>(3)  "
4247 "and B<ftell>(3)  (see B<fseek>(3)), respectively, except that the I<offset> "
4248 "argument of B<fseeko>()  and the return value of B<ftello>()  is of type "
4249 "I<off_t> instead of I<long>."
4250 msgstr ""
4251 "B<fseeko>()  関数および B<ftello>()  関数は、 それぞれ B<fseek>(3)  および "
4252 "B<ftell>(3)  と同一の機能を持つ (B<fseek>(3)  を見よ) が、ただし B<fseeko>"
4253 "()  関数の I<offset> 引数と B<ftello>()  の返り値が、 I<long> ではなく "
4254 "I<off_t> になっている。"
4255
4256 #. type: Plain text
4257 #: build/C/man3/fseeko.3:65
4258 msgid ""
4259 "On many architectures both I<off_t> and I<long> are 32-bit types, but "
4260 "compilation with"
4261 msgstr ""
4262 "多くのアーキテクチャでは I<off_t> も I<long> も共に 32 ビットの型であるが、"
4263
4264 #. type: Plain text
4265 #: build/C/man3/fseeko.3:69 build/C/man3/lseek64.3:81
4266 #, no-wrap
4267 msgid "#define _FILE_OFFSET_BITS 64\n"
4268 msgstr "#define _FILE_OFFSET_BITS 64\n"
4269
4270 #. type: Plain text
4271 #: build/C/man3/fseeko.3:75
4272 msgid "will turn I<off_t> into a 64-bit type."
4273 msgstr "でコンパイルすると I<off_t> は 64 ビット型となる。"
4274
4275 #. type: Plain text
4276 #: build/C/man3/fseeko.3:84
4277 msgid ""
4278 "On successful completion, B<fseeko>()  returns 0, while B<ftello>()  returns "
4279 "the current offset.  Otherwise, -1 is returned and I<errno> is set to "
4280 "indicate the error."
4281 msgstr ""
4282 "成功した場合、 B<fseeko>()  は 0 を、 B<ftello>()  は現在のオフセットを返"
4283 "す。 失敗した場合、-1 を返し、 I<errno> にエラーを示す値をセットする。"
4284
4285 #. type: Plain text
4286 #: build/C/man3/fseeko.3:87
4287 msgid "See the ERRORS in B<fseek>(3)."
4288 msgstr "B<fseek>(3)  の「エラー」の節を参照。"
4289
4290 #. type: Plain text
4291 #: build/C/man3/fseeko.3:89
4292 msgid "SUSv2, POSIX.1-2001."
4293 msgstr "SUSv2, POSIX.1-2001."
4294
4295 #. type: Plain text
4296 #: build/C/man3/fseeko.3:93
4297 msgid ""
4298 "These functions are found on System V-like systems.  They are not present in "
4299 "libc4, libc5, glibc 2.0 but are available since glibc 2.1."
4300 msgstr ""
4301 "これらの関数は System V 的なシステムにある。 libc4, libc5, glibc 2.0 にはな"
4302 "かったが、 glibc 2.1 から使えるようになった。"
4303
4304 #. type: Plain text
4305 #: build/C/man3/fseeko.3:95
4306 msgid "B<fseek>(3)"
4307 msgstr "B<fseek>(3)"
4308
4309 #. type: TH
4310 #: build/C/man3/getline.3:26
4311 #, no-wrap
4312 msgid "GETLINE"
4313 msgstr "GETLINE"
4314
4315 #. type: Plain text
4316 #: build/C/man3/getline.3:29
4317 msgid "getline, getdelim - delimited string input"
4318 msgstr "getline, getdelim - 区切り文字までの文字列入力を読み込む"
4319
4320 #. type: Plain text
4321 #: build/C/man3/getline.3:34
4322 #, no-wrap
4323 msgid "B<ssize_t getline(char **>I<lineptr>B<, size_t *>I<n>B<, FILE *>I<stream>B<);>\n"
4324 msgstr "B<ssize_t getline(char **>I<lineptr>B<, size_t *>I<n>B<, FILE *>I<stream>B<);>\n"
4325
4326 #. type: Plain text
4327 #: build/C/man3/getline.3:37
4328 #, no-wrap
4329 msgid "B<ssize_t getdelim(char **>I<lineptr>B<, size_t *>I<n>B<, int >I<delim>B<, FILE *>I<stream>B<);>\n"
4330 msgstr "B<ssize_t getdelim(char **>I<lineptr>B<, size_t *>I<n>B<, int >I<delim>B<, FILE *>I<stream>B<);>\n"
4331
4332 #. type: Plain text
4333 #: build/C/man3/getline.3:47
4334 msgid "B<getline>(), B<getdelim>():"
4335 msgstr "B<getline>(), B<getdelim>():"
4336
4337 #. type: Plain text
4338 #: build/C/man3/getline.3:52
4339 msgid "_POSIX_C_SOURCE\\ E<gt>=\\ 200809L || _XOPEN_SOURCE\\ E<gt>=\\ 700"
4340 msgstr "_POSIX_C_SOURCE\\ E<gt>=\\ 200809L || _XOPEN_SOURCE\\ E<gt>=\\ 700"
4341
4342 #. type: Plain text
4343 #: build/C/man3/getline.3:65
4344 msgid ""
4345 "B<getline>()  reads an entire line from I<stream>, storing the address of "
4346 "the buffer containing the text into I<*lineptr>.  The buffer is null-"
4347 "terminated and includes the newline character, if one was found."
4348 msgstr ""
4349 "B<getline>()  は I<stream> から 1 行全てを読み込み、テキストが含まれている"
4350 "バッファのアドレスを I<*lineptr> に格納する。 バッファはヌル文字 (\\e0) で終"
4351 "端される。 改行文字が見つかった場合は、改行文字もバッファに格納される。"
4352
4353 #. type: Plain text
4354 #: build/C/man3/getline.3:75
4355 msgid ""
4356 "If I<*lineptr> is NULL, then B<getline>()  will allocate a buffer for "
4357 "storing the line, which should be freed by the user program.  (In this case, "
4358 "the value in I<*n> is ignored.)"
4359 msgstr ""
4360 "I<*lineptr> が NULL の場合、 B<getline>()  は行の内容を格納するためのバッファ"
4361 "を確保する。 このバッファはユーザーのプログラムで解放すべきである (この場"
4362 "合、 I<*n> の値は無視される)。"
4363
4364 #. type: Plain text
4365 #: build/C/man3/getline.3:93
4366 msgid ""
4367 "Alternatively, before calling B<getline>(), I<*lineptr> can contain a "
4368 "pointer to a B<malloc>(3)-allocated buffer I<*n> bytes in size.  If the "
4369 "buffer is not large enough to hold the line, B<getline>()  resizes it with "
4370 "B<realloc>(3), updating I<*lineptr> and I<*n> as necessary."
4371 msgstr ""
4372 "別の方法として、 B<getline>()  を呼び出す際に、 I<*lineptr> に B<malloc>(3)  "
4373 "で確保した大きさ I<*n> バイトのバッファへのポインタを入れて渡すこともでき"
4374 "る。 読み込んだ行を保持するのに十分なバッファがない場合、 B<getline>()  は "
4375 "B<realloc>(3)  を使ってバッファのサイズを変更し、必要に応じて I<*lineptr> と "
4376 "I<*n> を更新する。"
4377
4378 #. type: Plain text
4379 #: build/C/man3/getline.3:99
4380 msgid ""
4381 "In either case, on a successful call, I<*lineptr> and I<*n> will be updated "
4382 "to reflect the buffer address and allocated size respectively."
4383 msgstr ""
4384 "どちらの場合でも、呼び出しに成功したときには、 I<*lineptr> と I<*n> がバッ"
4385 "ファのアドレスと割り当てたサイズを反映した値に更新される。"
4386
4387 #. type: Plain text
4388 #: build/C/man3/getline.3:110
4389 msgid ""
4390 "B<getdelim>()  works like B<getline>(), except that a line delimiter other "
4391 "than newline can be specified as the I<delimiter> argument.  As with "
4392 "B<getline>(), a delimiter character is not added if one was not present in "
4393 "the input before end of file was reached."
4394 msgstr ""
4395 "B<getdelim>()  は B<getline>()  と同じように動作するが、改行文字以外の区切り"
4396 "文字を引き数 I<delim> に指定することができる。 B<getline>()  と同様に、ファイ"
4397 "ル終端に達するまでに入力行に区切り文字が見付からない場合は、 区切り文字をバッ"
4398 "ファに追加しない。"
4399
4400 #. type: Plain text
4401 #: build/C/man3/getline.3:119
4402 msgid ""
4403 "On success, B<getline>()  and B<getdelim>()  return the number of characters "
4404 "read, including the delimiter character, but not including the terminating "
4405 "null byte (\\(aq\\e0\\(aq).  This value can be used to handle embedded null "
4406 "bytes in the line read."
4407 msgstr "成功した場合、 B<getline>()  と B<getdelim>()  は読み込んだ文字数を返す。 文字数には区切り文字は含まれるが、終端に使う NULL バイト (\\(aq\\e0\\(aq) は含まれない。 この値によって、読み込んだ行に含まれる NULL バイトを操作することができる。"
4408
4409 #. type: Plain text
4410 #: build/C/man3/getline.3:125
4411 msgid ""
4412 "Both functions return -1 on failure to read a line (including end-of-file "
4413 "condition).  In the event of an error, I<errno> is set to indicate the cause."
4414 msgstr "どちらの関数も、行の読み込みに失敗した場合には -1 を返す (ファイルの終端に達した場合にも -1 を返す)。 エラーが発生した場合には、 I<errno> にエラーの原因を示す値が設定される。"
4415
4416 #. type: Plain text
4417 #: build/C/man3/getline.3:135
4418 msgid "Bad arguments (I<n> or I<lineptr> is NULL, or I<stream> is not valid)."
4419 msgstr ""
4420 "引き数が不正である (I<n> または I<lineptr> が NULL である。 もしくは "
4421 "I<stream> が有効でない)。"
4422
4423 #. type: Plain text
4424 #: build/C/man3/getline.3:137
4425 msgid "These functions are available since libc 4.6.27."
4426 msgstr "これらの関数は libc 4.6.27 以降で利用可能である。"
4427
4428 #. type: Plain text
4429 #: build/C/man3/getline.3:144
4430 msgid ""
4431 "Both B<getline>()  and B<getdelim>()  were originally GNU extensions.  They "
4432 "were standardized in POSIX.1-2008."
4433 msgstr ""
4434 "B<getline>()  と B<getdelim>()  は、どちらも元は GNU による拡張であったが、 "
4435 "POSIX.1-2008 で標準化された。"
4436
4437 #. type: Plain text
4438 #: build/C/man3/getline.3:149
4439 #, no-wrap
4440 msgid ""
4441 "#define _GNU_SOURCE\n"
4442 "#include E<lt>stdio.hE<gt>\n"
4443 "#include E<lt>stdlib.hE<gt>\n"
4444 msgstr ""
4445 "#define _GNU_SOURCE\n"
4446 "#include E<lt>stdio.hE<gt>\n"
4447 "#include E<lt>stdlib.hE<gt>\n"
4448
4449 #. type: Plain text
4450 #: build/C/man3/getline.3:157
4451 #, no-wrap
4452 msgid ""
4453 "int\n"
4454 "main(void)\n"
4455 "{\n"
4456 "    FILE *fp;\n"
4457 "    char *line = NULL;\n"
4458 "    size_t len = 0;\n"
4459 "    ssize_t read;\n"
4460 msgstr ""
4461 "int\n"
4462 "main(void)\n"
4463 "{\n"
4464 "    FILE *fp;\n"
4465 "    char *line = NULL;\n"
4466 "    size_t len = 0;\n"
4467 "    ssize_t read;\n"
4468
4469 #. type: Plain text
4470 #: build/C/man3/getline.3:161
4471 #, no-wrap
4472 msgid ""
4473 "    fp = fopen(\"/etc/motd\", \"r\");\n"
4474 "    if (fp == NULL)\n"
4475 "        exit(EXIT_FAILURE);\n"
4476 msgstr ""
4477 "    fp = fopen(\"/etc/motd\", \"r\");\n"
4478 "    if (fp == NULL)\n"
4479 "        exit(EXIT_FAILURE);\n"
4480
4481 #. type: Plain text
4482 #: build/C/man3/getline.3:166
4483 #, no-wrap
4484 msgid ""
4485 "    while ((read = getline(&line, &len, fp)) != -1) {\n"
4486 "        printf(\"Retrieved line of length %zu :\\en\", read);\n"
4487 "        printf(\"%s\", line);\n"
4488 "    }\n"
4489 msgstr ""
4490 "    while ((read = getline(&line, &len, fp)) != -1) {\n"
4491 "        printf(\"Retrieved line of length %zu :\\en\", read);\n"
4492 "        printf(\"%s\", line);\n"
4493 "    }\n"
4494
4495 #. type: Plain text
4496 #: build/C/man3/getline.3:170
4497 #, no-wrap
4498 msgid ""
4499 "    free(line);\n"
4500 "    exit(EXIT_SUCCESS);\n"
4501 "}\n"
4502 msgstr ""
4503 "    free(line);\n"
4504 "    exit(EXIT_SUCCESS);\n"
4505 "}\n"
4506
4507 #. type: Plain text
4508 #: build/C/man3/getline.3:178
4509 msgid ""
4510 "B<read>(2), B<fgets>(3), B<fopen>(3), B<fread>(3), B<gets>(3), B<scanf>(3)"
4511 msgstr ""
4512 "B<read>(2), B<fgets>(3), B<fopen>(3), B<fread>(3), B<gets>(3), B<scanf>(3)"
4513
4514 #. type: TH
4515 #: build/C/man3/gets.3:27
4516 #, no-wrap
4517 msgid "GETS"
4518 msgstr "GETS"
4519
4520 #. type: TH
4521 #: build/C/man3/gets.3:27
4522 #, no-wrap
4523 msgid "2012-01-18"
4524 msgstr "2012-01-18"
4525
4526 #. type: Plain text
4527 #: build/C/man3/gets.3:30
4528 msgid ""
4529 "fgetc, fgets, getc, getchar, gets, ungetc - input of characters and strings"
4530 msgstr "fgetc, fgets, getc, getchar, gets, ungetc - 文字と文字列の入力"
4531
4532 #. type: Plain text
4533 #: build/C/man3/gets.3:35
4534 #, no-wrap
4535 msgid "B<int fgetc(FILE *>I<stream>B<);>\n"
4536 msgstr "B<int fgetc(FILE *>I<stream>B<);>\n"
4537
4538 #. type: Plain text
4539 #: build/C/man3/gets.3:37
4540 #, no-wrap
4541 msgid "B<char *fgets(char *>I<s>B<, int >I<size>B<, FILE *>I<stream>B<);>\n"
4542 msgstr "B<char *fgets(char *>I<s>B<, int >I<size>B<, FILE *>I<stream>B<);>\n"
4543
4544 #. type: Plain text
4545 #: build/C/man3/gets.3:39
4546 #, no-wrap
4547 msgid "B<int getc(FILE *>I<stream>B<);>\n"
4548 msgstr "B<int getc(FILE *>I<stream>B<);>\n"
4549
4550 #. type: Plain text
4551 #: build/C/man3/gets.3:41
4552 #, no-wrap
4553 msgid "B<int getchar(void);>\n"
4554 msgstr "B<int getchar(void);>\n"
4555
4556 #. type: Plain text
4557 #: build/C/man3/gets.3:43
4558 #, no-wrap
4559 msgid "B<char *gets(char *>I<s>B<);>\n"
4560 msgstr "B<char *gets(char *>I<s>B<);>\n"
4561
4562 #. type: Plain text
4563 #: build/C/man3/gets.3:45
4564 #, no-wrap
4565 msgid "B<int ungetc(int >I<c>B<, FILE *>I<stream>B<);>\n"
4566 msgstr "B<int ungetc(int >I<c>B<, FILE *>I<stream>B<);>\n"
4567
4568 #. type: Plain text
4569 #: build/C/man3/gets.3:57
4570 msgid ""
4571 "B<fgetc>()  reads the next character from I<stream> and returns it as an "
4572 "I<unsigned char> cast to an I<int>, or B<EOF> on end of file or error."
4573 msgstr ""
4574 "B<fgetc>()  は、 I<stream> から次の文字を I<unsigned char> として読み、 "
4575 "I<int> にキャストして返す。ファイルの終わりやエラーとなった場合は B<EOF> を返"
4576 "す。"
4577
4578 #. type: Plain text
4579 #: build/C/man3/gets.3:64
4580 msgid ""
4581 "B<getc>()  is equivalent to B<fgetc>()  except that it may be implemented as "
4582 "a macro which evaluates I<stream> more than once."
4583 msgstr ""
4584 "B<getc>()  は B<fgetc>()  と同様だが、 I<stream> を複数回評価するマクロとして"
4585 "実装されているかもしれない。"
4586
4587 #. type: Plain text
4588 #: build/C/man3/gets.3:68
4589 msgid "B<getchar>()  is equivalent to B<getc(>I<stdin>B<)>."
4590 msgstr "B<getchar>()  は B<getc(>I<stdin>B<)> と同じである。"
4591
4592 #. type: Plain text
4593 #: build/C/man3/gets.3:78
4594 msgid ""
4595 "B<gets>()  reads a line from I<stdin> into the buffer pointed to by I<s> "
4596 "until either a terminating newline or B<EOF>, which it replaces with a null "
4597 "byte (\\(aq\\e0\\(aq).  No check for buffer overrun is performed (see BUGS "
4598 "below)."
4599 msgstr ""
4600 "B<gets>()  は、改行文字か B<EOF> までの 1行を I<stdin> から読み込み I<s> が指"
4601 "すバッファに格納する (末尾の改行文字や B<EOF> は NULL バイト (\\(aq"
4602 "\\e0\\(aq) に置き換えられる)。 バッファオーバーランのチェックは行われない (下"
4603 "記の「バグ」を参照)。"
4604
4605 #. type: Plain text
4606 #: build/C/man3/gets.3:92
4607 msgid ""
4608 "B<fgets>()  reads in at most one less than I<size> characters from I<stream> "
4609 "and stores them into the buffer pointed to by I<s>.  Reading stops after an "
4610 "B<EOF> or a newline.  If a newline is read, it is stored into the buffer.  A "
4611 "terminating null byte (\\(aq\\e0\\(aq)  is stored after the last character "
4612 "in the buffer."
4613 msgstr ""
4614 "B<fgets>()  は I<stream> から最大で I<size> - 1 個の文字を読み込み、 I<s> が"
4615 "指すバッファに格納する。読み込みは B<EOF> または改行文字を読み込んだ後で停止"
4616 "する。 読み込まれた改行文字はバッファに格納される。 終端の NULL バイト (\\(aq"
4617 "\\e0\\(aq)  が一つバッファの中の最後の文字の後に書き込まれる。"
4618
4619 #. type: Plain text
4620 #: build/C/man3/gets.3:103
4621 msgid ""
4622 "B<ungetc>()  pushes I<c> back to I<stream>, cast to I<unsigned char>, where "
4623 "it is available for subsequent read operations.  Pushed-back characters will "
4624 "be returned in reverse order; only one pushback is guaranteed."
4625 msgstr ""
4626 "B<ungetc>()  は、後の read 操作で読めるように、 I<c> を I<unsigned char> に"
4627 "キャストして I<stream> に書き戻す。 書き戻された文字は逆順に戻される; 書き戻"
4628 "しとして保証されているのは、一文字だけである。"
4629
4630 #. type: Plain text
4631 #: build/C/man3/gets.3:108
4632 msgid ""
4633 "Calls to the functions described here can be mixed with each other and with "
4634 "calls to other input functions from the I<stdio> library for the same input "
4635 "stream."
4636 msgstr ""
4637 "ここで述べた関数や I<stdio> ライブラリの入力関数を同じ入力ストリームに対して"
4638 "互いに混ぜて使うことができる。"
4639
4640 #. type: Plain text
4641 #: build/C/man3/gets.3:123
4642 msgid ""
4643 "B<fgetc>(), B<getc>()  and B<getchar>()  return the character read as an "
4644 "I<unsigned char> cast to an I<int> or B<EOF> on end of file or error."
4645 msgstr ""
4646 "B<fgetc>(), B<getc>(), B<getchar>()  は、文字を I<unsigned char> として読ん"
4647 "で I<int> にキャストして返す。ファイルの終わりやエラーの場合は B<EOF> を返"
4648 "す。"
4649
4650 #. type: Plain text
4651 #: build/C/man3/gets.3:131
4652 msgid ""
4653 "B<gets>()  and B<fgets>()  return I<s> on success, and NULL on error or when "
4654 "end of file occurs while no characters have been read."
4655 msgstr ""
4656 "B<gets>()  と B<fgets>()  は、成功すると I<s> を返し、エラーや 1 文字も読み込"
4657 "んでいないのにファイルの終わりになった 場合に NULL を返す。"
4658
4659 #. type: Plain text
4660 #: build/C/man3/gets.3:138
4661 msgid "B<ungetc>()  returns I<c> on success, or B<EOF> on error."
4662 msgstr "B<ungetc>()  は成功すると I<c> を返し、エラーの場合は B<EOF> を返す。"
4663
4664 #. type: Plain text
4665 #: build/C/man3/gets.3:140
4666 msgid "C89, C99, POSIX.1-2001."
4667 msgstr "C89, C99, POSIX.1-2001."
4668
4669 #. type: Plain text
4670 #: build/C/man3/gets.3:152
4671 msgid ""
4672 "LSB deprecates B<gets>().  POSIX.1-2008 marks B<gets>()  obsolescent.  ISO "
4673 "C11 removes the specification of B<gets>()  from the C language, and since "
4674 "version 2.16, glibc header files don't expose the function declaration if "
4675 "the B<_ISOC11_SOURCE> feature test macro is defined."
4676 msgstr ""
4677 "LSB は B<gets>() を非推奨としている。\n"
4678 "POSIX.1-2008 では B<gets>() に廃止予定の印が付けられている。\n"
4679 "ISO C11 では B<gets>)() の規定が C 言語から削除されている。\n"
4680 "glibc バージョン 2.16 以降では、機能検査マシン B<_ISOC11_SOURCE> が定義され"
4681 "た\n"
4682 "場合、glibc ヘッダファイルでは B<gets>)() の宣言が公開されない。"
4683
4684 #. type: Plain text
4685 #: build/C/man3/gets.3:166
4686 msgid ""
4687 "Never use B<gets>().  Because it is impossible to tell without knowing the "
4688 "data in advance how many characters B<gets>()  will read, and because B<gets>"
4689 "()  will continue to store characters past the end of the buffer, it is "
4690 "extremely dangerous to use.  It has been used to break computer security.  "
4691 "Use B<fgets>()  instead."
4692 msgstr ""
4693 "B<gets>()  は絶対に使用してはならない。 前もってデータを知ることなしに "
4694 "B<gets>()  が何文字読むかを知ることはできず、 B<gets>()  がバッファの終わりを"
4695 "越えて書き込み続けるため、 B<gets>()  を使うのは極めて危険である。 これを利用"
4696 "してコンピュータのセキュリティが破られてきた。 代わりに B<fgets>()  を使うこ"
4697 "と。"
4698
4699 #. type: Plain text
4700 #: build/C/man3/gets.3:173
4701 msgid ""
4702 "It is not advisable to mix calls to input functions from the I<stdio> "
4703 "library with low-level calls to B<read>(2)  for the file descriptor "
4704 "associated with the input stream; the results will be undefined and very "
4705 "probably not what you want."
4706 msgstr ""
4707 "入力ストリームのファイルディスクリプタに対して、 I<stdio> ライブラリの入力関"
4708 "数と、低レベル呼び出しの B<read>(2)  を混ぜて呼び出す事は勧められない。 結果"
4709 "がどうなるかは分からず、おそらくあなたの 望んでいる結果にはならないだろう。"
4710
4711 #. type: Plain text
4712 #: build/C/man3/gets.3:189
4713 msgid ""
4714 "B<read>(2), B<write>(2), B<ferror>(3), B<fgetwc>(3), B<fgetws>(3), B<fopen>"
4715 "(3), B<fread>(3), B<fseek>(3), B<getline>(3), B<getwchar>(3), B<puts>(3), "
4716 "B<scanf>(3), B<ungetwc>(3), B<unlocked_stdio>(3), B<feature_test_macros>(7)"
4717 msgstr ""
4718 "B<read>(2), B<write>(2), B<ferror>(3), B<fgetwc>(3), B<fgetws>(3),\n"
4719 "B<fopen>(3), B<fread>(3), B<fseek>(3), B<getline>(3), B<getwchar>(3),\n"
4720 "B<puts>(3), B<scanf>(3), B<ungetwc>(3), B<unlocked_stdio>(3),\n"
4721 "B<feature_test_macros>(7)"
4722
4723 #. type: TH
4724 #: build/C/man3/getw.3:25
4725 #, no-wrap
4726 msgid "GETW"
4727 msgstr "GETW"
4728
4729 #. type: TH
4730 #: build/C/man3/getw.3:25
4731 #, no-wrap
4732 msgid "2010-09-26"
4733 msgstr "2010-09-26"
4734
4735 #. type: Plain text
4736 #: build/C/man3/getw.3:28
4737 msgid "getw, putw - input and output of words (ints)"
4738 msgstr "getw, putw - ワード(int)の入出力"
4739
4740 #. type: Plain text
4741 #: build/C/man3/getw.3:33
4742 #, no-wrap
4743 msgid "B<int getw(FILE *>I<stream>B<);>\n"
4744 msgstr "B<int getw(FILE *>I<stream>B<);>\n"
4745
4746 #. type: Plain text
4747 #: build/C/man3/getw.3:35
4748 #, no-wrap
4749 msgid "B<int putw(int >I<w>B<, FILE *>I<stream>B<);>\n"
4750 msgstr "B<int putw(int >I<w>B<, FILE *>I<stream>B<);>\n"
4751
4752 #. type: Plain text
4753 #: build/C/man3/getw.3:44
4754 msgid "B<getw>(), B<putw>():"
4755 msgstr "B<getw>(), B<putw>():"
4756
4757 #. type: TP
4758 #: build/C/man3/getw.3:47
4759 #, no-wrap
4760 msgid "Since glibc 2.3.3:"
4761 msgstr "glibc 2.3.3 以降:"
4762
4763 #. type: Plain text
4764 #: build/C/man3/getw.3:50
4765 msgid "_SVID_SOURCE || _BSD_SOURCE ||"
4766 msgstr "_SVID_SOURCE || _BSD_SOURCE ||"
4767
4768 #. type: Plain text
4769 #: build/C/man3/getw.3:53
4770 #, no-wrap
4771 msgid ""
4772 "(_XOPEN_SOURCE &&\n"
4773 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600))\n"
4774 msgstr ""
4775 "(_XOPEN_SOURCE &&\n"
4776 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600))\n"
4777
4778 #. type: TP
4779 #: build/C/man3/getw.3:53
4780 #, no-wrap
4781 msgid "Before glibc 2.3.3:"
4782 msgstr "glibc 2.3.3 より前:"
4783
4784 #. type: Plain text
4785 #: build/C/man3/getw.3:56
4786 msgid "_SVID_SOURCE || _BSD_SOURCE || _XOPEN_SOURCE"
4787 msgstr "_SVID_SOURCE || _BSD_SOURCE || _XOPEN_SOURCE"
4788
4789 #. type: Plain text
4790 #: build/C/man3/getw.3:66
4791 msgid ""
4792 "B<getw>()  reads a word (that is, an I<int>) from I<stream>.  It's provided "
4793 "for compatibility with SVr4.  We recommend you use B<fread>(3)  instead."
4794 msgstr ""
4795 "B<getw>()  は I<stream> からワード (I<int>型) を読み込む。 この関数は、SVr4 "
4796 "との互換性のために提供されている。 この関数の代わりに B<fread>(3)  を使用する"
4797 "ことを勧める。"
4798
4799 #. type: Plain text
4800 #: build/C/man3/getw.3:73
4801 msgid ""
4802 "B<putw>()  writes the word I<w> (that is, an I<int>) to I<stream>.  It is "
4803 "provided for compatibility with SVr4, but we recommend you use B<fwrite>(3)  "
4804 "instead."
4805 msgstr ""
4806 "B<putw>()  は I<stream> にワード I<w> (I<int>型) を書き込む。 この関数は "
4807 "SVr4 との互換性のために提供されているが、この関数の代わりに B<fwrite>(3)  を"
4808 "使用することを勧める。"
4809
4810 #. type: Plain text
4811 #: build/C/man3/getw.3:80
4812 msgid ""
4813 "Normally, B<getw>()  returns the word read, and B<putw>()  returns 0.  On "
4814 "error, they return B<EOF>."
4815 msgstr ""
4816 "通常、 B<getw>()  は読み込んだワードを返し、 B<putw>()  は 0 を返す。 エラー"
4817 "が発生した場合、これらの関数は B<EOF> を返す。"
4818
4819 #. type: Plain text
4820 #: build/C/man3/getw.3:82
4821 msgid "SVr4, SUSv2.  Not present in POSIX.1-2001."
4822 msgstr "SVr4, SUSv2.  POSIX.1-2001 には存在しない。"
4823
4824 #. type: Plain text
4825 #: build/C/man3/getw.3:86
4826 msgid ""
4827 "The value returned on error is also a legitimate data value.  B<ferror>(3)  "
4828 "can be used to distinguish between the two cases."
4829 msgstr ""
4830 "エラーの時に返される値は、正しいデータとして返されることもある。 B<ferror>"
4831 "(3)  を用いると、この二つの場合を区別することが出来る。"
4832
4833 #. type: Plain text
4834 #: build/C/man3/getw.3:92
4835 msgid "B<ferror>(3), B<fread>(3), B<fwrite>(3), B<getc>(3), B<putc>(3)"
4836 msgstr "B<ferror>(3), B<fread>(3), B<fwrite>(3), B<getc>(3), B<putc>(3)"
4837
4838 #. type: TH
4839 #: build/C/man2/link.2:31
4840 #, no-wrap
4841 msgid "LINK"
4842 msgstr "LINK"
4843
4844 #. type: TH
4845 #: build/C/man2/link.2:31 build/C/man2/rename.2:32 build/C/man2/symlink.2:32
4846 #: build/C/man2/write.2:39
4847 #, no-wrap
4848 msgid "2013-01-27"
4849 msgstr "2013-01-27"
4850
4851 #. type: Plain text
4852 #: build/C/man2/link.2:34
4853 msgid "link - make a new name for a file"
4854 msgstr "link - ファイルの新しい名前を作成する"
4855
4856 #. type: Plain text
4857 #: build/C/man2/link.2:36 build/C/man2/lseek.2:54 build/C/man3/lseek64.3:34
4858 #: build/C/man2/readlink.2:48 build/C/man2/rmdir.2:35
4859 #: build/C/man2/symlink.2:37 build/C/man2/unlink.2:37 build/C/man2/write.2:44
4860 msgid "B<#include E<lt>unistd.hE<gt>>"
4861 msgstr "B<#include E<lt>unistd.hE<gt>>"
4862
4863 #. type: Plain text
4864 #: build/C/man2/link.2:38
4865 msgid "B<int link(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
4866 msgstr "B<int link(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
4867
4868 #. type: Plain text
4869 #: build/C/man2/link.2:41
4870 msgid ""
4871 "B<link>()  creates a new link (also known as a hard link) to an existing "
4872 "file."
4873 msgstr ""
4874 "B<link>()  は存在するファイルへの新しいリンク (link)  (ハードリンク (hard "
4875 "link) ともいう) を作成する。"
4876
4877 #. type: Plain text
4878 #: build/C/man2/link.2:47 build/C/man2/symlink.2:84
4879 msgid "If I<newpath> exists it will I<not> be overwritten."
4880 msgstr "I<newpath> が存在する場合には上書きはI<されない>。"
4881
4882 #. type: Plain text
4883 #: build/C/man2/link.2:52
4884 msgid ""
4885 "This new name may be used exactly as the old one for any operation; both "
4886 "names refer to the same file (and so have the same permissions and "
4887 "ownership) and it is impossible to tell which name was the \"original\"."
4888 msgstr ""
4889 "この新しい名前は全ての操作において古い名前と完全に同じように使用される; 両方"
4890 "の名前は同じファイルを参照しており (それで同じ許可 (permission) や所有者 "
4891 "(ownership) となるので)、 どちらの名前が本来のものであるか判別できない。"
4892
4893 #. type: Plain text
4894 #: build/C/man2/link.2:57 build/C/man2/pipe.2:97 build/C/man3/remove.3:65
4895 #: build/C/man2/rename.2:96 build/C/man2/rmdir.2:45 build/C/man2/symlink.2:89
4896 #: build/C/man2/unlink.2:60
4897 msgid ""
4898 "On success, zero is returned.  On error, -1 is returned, and I<errno> is set "
4899 "appropriately."
4900 msgstr ""
4901 "成功した場合は 0 が返される。エラーの場合は -1 が返され、 I<errno> が適切に設"
4902 "定される。"
4903
4904 #. type: TP
4905 #: build/C/man2/link.2:58 build/C/man2/open.2:486 build/C/man2/readlink.2:86
4906 #: build/C/man2/rename.2:97 build/C/man2/rmdir.2:46 build/C/man2/symlink.2:90
4907 #: build/C/man3/tmpfile.3:57 build/C/man2/unlink.2:61
4908 #, no-wrap
4909 msgid "B<EACCES>"
4910 msgstr "B<EACCES>"
4911
4912 #. type: Plain text
4913 #: build/C/man2/link.2:69
4914 msgid ""
4915 "Write access to the directory containing I<newpath> is denied, or search "
4916 "permission is denied for one of the directories in the path prefix of "
4917 "I<oldpath> or I<newpath>.  (See also B<path_resolution>(7).)"
4918 msgstr ""
4919 "I<newpath> を含んでいるディレクトリへの書き込みが許されていないか、 "
4920 "I<oldpath> または I<newpath> へのディレクトリのどれかに検索許可がない "
4921 "(B<path_resolution>(7)  を参照)。"
4922
4923 #. type: TP
4924 #: build/C/man2/link.2:69 build/C/man2/open.2:495 build/C/man2/rename.2:133
4925 #: build/C/man2/symlink.2:99 build/C/man2/write.2:135
4926 #, no-wrap
4927 msgid "B<EDQUOT>"
4928 msgstr "B<EDQUOT>"
4929
4930 #. type: Plain text
4931 #: build/C/man2/link.2:72 build/C/man2/rename.2:136
4932 msgid "The user's quota of disk blocks on the file system has been exhausted."
4933 msgstr ""
4934 "ディスクブロックか inode がそのファイルシステムのユーザクォータに達していた。"
4935
4936 #. type: TP
4937 #: build/C/man2/link.2:72 build/C/man2/open.2:501 build/C/man2/symlink.2:104
4938 #: build/C/man3/tmpfile.3:60
4939 #, no-wrap
4940 msgid "B<EEXIST>"
4941 msgstr "B<EEXIST>"
4942
4943 #. type: Plain text
4944 #: build/C/man2/link.2:76 build/C/man2/symlink.2:108
4945 msgid "I<newpath> already exists."
4946 msgstr "I<newpath> が既に存在する。"
4947
4948 #. type: TP
4949 #: build/C/man2/link.2:76 build/C/man2/llseek.2:74 build/C/man2/open.2:507
4950 #: build/C/man2/pipe.2:98 build/C/man2/read.2:118 build/C/man2/readlink.2:91
4951 #: build/C/man2/rename.2:136 build/C/man2/rmdir.2:64
4952 #: build/C/man2/symlink.2:108 build/C/man2/unlink.2:80
4953 #: build/C/man2/write.2:141
4954 #, no-wrap
4955 msgid "B<EFAULT>"
4956 msgstr "B<EFAULT>"
4957
4958 #. type: Plain text
4959 #: build/C/man2/link.2:79 build/C/man2/rename.2:139 build/C/man2/symlink.2:111
4960 msgid "I<oldpath> or I<newpath> points outside your accessible address space."
4961 msgstr ""
4962 "I<oldpath> や I<newpath> がアクセス可能なアドレス空間の外を指している。"
4963
4964 #. type: TP
4965 #: build/C/man2/link.2:79 build/C/man2/read.2:147 build/C/man2/readlink.2:107
4966 #: build/C/man2/symlink.2:111 build/C/man2/unlink.2:84
4967 #: build/C/man2/write.2:165
4968 #, no-wrap
4969 msgid "B<EIO>"
4970 msgstr "B<EIO>"
4971
4972 #. type: Plain text
4973 #: build/C/man2/link.2:82 build/C/man2/symlink.2:114 build/C/man2/unlink.2:87
4974 msgid "An I/O error occurred."
4975 msgstr "I/O エラーが発生した。"
4976
4977 #. type: TP
4978 #: build/C/man2/link.2:82 build/C/man2/open.2:531 build/C/man2/readlink.2:110
4979 #: build/C/man2/rename.2:149 build/C/man2/rmdir.2:73
4980 #: build/C/man2/symlink.2:114 build/C/man2/unlink.2:92
4981 #, no-wrap
4982 msgid "B<ELOOP>"
4983 msgstr "B<ELOOP>"
4984
4985 #. type: Plain text
4986 #: build/C/man2/link.2:86 build/C/man2/rename.2:153
4987 msgid ""
4988 "Too many symbolic links were encountered in resolving I<oldpath> or "
4989 "I<newpath>."
4990 msgstr ""
4991 "I<oldpath> または I<newpath> を解決する際に遭遇したシンボリックリンクが多過ぎ"
4992 "る。"
4993
4994 #. type: TP
4995 #: build/C/man2/link.2:86 build/C/man2/rename.2:153
4996 #, no-wrap
4997 msgid "B<EMLINK>"
4998 msgstr "B<EMLINK>"
4999
5000 #. type: Plain text
5001 #: build/C/man2/link.2:91
5002 msgid ""
5003 "The file referred to by I<oldpath> already has the maximum number of links "
5004 "to it."
5005 msgstr ""
5006 "I<oldpath> によって参照されるファイルは 既に最大数までのリンクを持っている。"
5007
5008 #. type: TP
5009 #: build/C/man2/link.2:91 build/C/man2/open.2:541 build/C/man2/readlink.2:113
5010 #: build/C/man2/rename.2:160 build/C/man2/rmdir.2:77
5011 #: build/C/man2/symlink.2:118 build/C/man2/unlink.2:96
5012 #, no-wrap
5013 msgid "B<ENAMETOOLONG>"
5014 msgstr "B<ENAMETOOLONG>"
5015
5016 #. type: Plain text
5017 #: build/C/man2/link.2:94 build/C/man2/rename.2:163 build/C/man2/symlink.2:121
5018 msgid "I<oldpath> or I<newpath> was too long."
5019 msgstr "I<oldpath> または I<newpath> が長過ぎる。"
5020
5021 #. type: TP
5022 #: build/C/man2/link.2:94 build/C/man2/open.2:555 build/C/man2/readlink.2:116
5023 #: build/C/man2/rename.2:163 build/C/man2/rmdir.2:80
5024 #: build/C/man2/symlink.2:121 build/C/man2/unlink.2:99
5025 #, no-wrap
5026 msgid "B<ENOENT>"
5027 msgstr "B<ENOENT>"
5028
5029 #. type: Plain text
5030 #: build/C/man2/link.2:99
5031 msgid ""
5032 "A directory component in I<oldpath> or I<newpath> does not exist or is a "
5033 "dangling symbolic link."
5034 msgstr ""
5035 "I<oldpath> または I<newpath> のディレクトリ部分が存在しないか、 壊れた"
5036 "(dangling)シンボリックリンクである。"
5037
5038 #. type: TP
5039 #: build/C/man2/link.2:99 build/C/man2/open.2:562 build/C/man2/readlink.2:119
5040 #: build/C/man2/rename.2:176 build/C/man2/rmdir.2:85 build/C/man3/scanf.3:570
5041 #: build/C/man2/symlink.2:128 build/C/man3/tempnam.3:95
5042 #: build/C/man2/unlink.2:106
5043 #, no-wrap
5044 msgid "B<ENOMEM>"
5045 msgstr "B<ENOMEM>"
5046
5047 #. type: Plain text
5048 #: build/C/man2/link.2:102 build/C/man2/open.2:565 build/C/man2/readlink.2:122
5049 #: build/C/man2/rename.2:179 build/C/man2/rmdir.2:88
5050 #: build/C/man2/symlink.2:131 build/C/man2/unlink.2:109
5051 msgid "Insufficient kernel memory was available."
5052 msgstr "十分なカーネルメモリーがない。"
5053
5054 #. type: TP
5055 #: build/C/man2/link.2:102 build/C/man2/open.2:565 build/C/man2/rename.2:179
5056 #: build/C/man2/symlink.2:131 build/C/man3/tmpfile.3:72
5057 #: build/C/man2/write.2:168
5058 #, no-wrap
5059 msgid "B<ENOSPC>"
5060 msgstr "B<ENOSPC>"
5061
5062 #. type: Plain text
5063 #: build/C/man2/link.2:106 build/C/man2/rename.2:183
5064 #: build/C/man2/symlink.2:135
5065 msgid "The device containing the file has no room for the new directory entry."
5066 msgstr ""
5067 "そのファイルを含んでいるデバイスに新しいディレクトリエントリを 作成するための"
5068 "空きがない。"
5069
5070 #. type: TP
5071 #: build/C/man2/link.2:106 build/C/man2/open.2:571 build/C/man2/readlink.2:122
5072 #: build/C/man2/rename.2:183 build/C/man2/rmdir.2:88
5073 #: build/C/man2/symlink.2:135 build/C/man2/unlink.2:109
5074 #, no-wrap
5075 msgid "B<ENOTDIR>"
5076 msgstr "B<ENOTDIR>"
5077
5078 #. type: Plain text
5079 #: build/C/man2/link.2:111
5080 msgid ""
5081 "A component used as a directory in I<oldpath> or I<newpath> is not, in fact, "
5082 "a directory."
5083 msgstr ""
5084 "I<oldpath> または I<newpath> のディレクトリ部分が、実際には、ディレクトリでな"
5085 "い。"
5086
5087 #. type: TP
5088 #: build/C/man2/link.2:111 build/C/man2/link.2:115 build/C/man2/open.2:604
5089 #: build/C/man2/rmdir.2:107 build/C/man2/rmdir.2:118
5090 #: build/C/man2/symlink.2:140 build/C/man2/unlink.2:114
5091 #, no-wrap
5092 msgid "B<EPERM>"
5093 msgstr "B<EPERM>"
5094
5095 #. type: Plain text
5096 #: build/C/man2/link.2:115
5097 msgid "I<oldpath> is a directory."
5098 msgstr "I<oldpath> がディレクトリである。"
5099
5100 #. type: Plain text
5101 #: build/C/man2/link.2:120
5102 msgid ""
5103 "The file system containing I<oldpath> and I<newpath> does not support the "
5104 "creation of hard links."
5105 msgstr ""
5106 "I<oldpath> と I<newpath> を含んでいるファイルシステムがハードリンクをサポート"
5107 "していない。"
5108
5109 #. type: TP
5110 #: build/C/man2/link.2:120
5111 #, no-wrap
5112 msgid "B<EPERM> (since Linux 3.6)"
5113 msgstr "B<EPERM> (Linux 3.6 以降)"
5114
5115 #. type: Plain text
5116 #: build/C/man2/link.2:127
5117 msgid ""
5118 "The caller does not have permission to create a hard link to this file (see "
5119 "the description of I</proc/sys/fs/protected_hardlink> in B<proc>(5))."
5120 msgstr ""
5121 "呼び出し元にこのファイルへのハードリンクを作成する許可がなかった (B<proc>(5) "
5122 "の I</proc/sys/fs/protected_hardlink> の説明を参照)。"
5123
5124 #. type: TP
5125 #: build/C/man2/link.2:127 build/C/man2/open.2:612 build/C/man2/rename.2:221
5126 #: build/C/man2/rmdir.2:123 build/C/man2/symlink.2:145
5127 #: build/C/man3/tmpfile.3:75 build/C/man2/unlink.2:137
5128 #, no-wrap
5129 msgid "B<EROFS>"
5130 msgstr "B<EROFS>"
5131
5132 #. type: Plain text
5133 #: build/C/man2/link.2:130 build/C/man2/rename.2:224
5134 msgid "The file is on a read-only file system."
5135 msgstr "ファイルが読み込み専用のファイルシステムに存在する。"
5136
5137 #. type: TP
5138 #: build/C/man2/link.2:130 build/C/man2/rename.2:224
5139 #, no-wrap
5140 msgid "B<EXDEV>"
5141 msgstr "B<EXDEV>"
5142
5143 #. type: Plain text
5144 #: build/C/man2/link.2:138
5145 msgid ""
5146 "I<oldpath> and I<newpath> are not on the same mounted file system.  (Linux "
5147 "permits a file system to be mounted at multiple points, but B<link>()  does "
5148 "not work across different mount points, even if the same file system is "
5149 "mounted on both.)"
5150 msgstr ""
5151 "I<oldpath> と I<newpath> が同じマウントされたファイルシステムに存在しない。 "
5152 "(Linux は 1 つのファイルシステムを複数のマウント位置に マウントすることを許可"
5153 "している。 しかし B<link>()  は、たとえ同じファイルシステムであっても、 別々"
5154 "のマウント位置を跨いでは動作しない。)"
5155
5156 #.  SVr4 documents additional ENOLINK and
5157 #.  EMULTIHOP error conditions; POSIX.1 does not document ELOOP.
5158 #.  X/OPEN does not document EFAULT, ENOMEM or EIO.
5159 #. type: Plain text
5160 #: build/C/man2/link.2:143
5161 msgid "SVr4, 4.3BSD, POSIX.1-2001 (but see NOTES)."
5162 msgstr "SVr4, 4.3BSD, POSIX.1-2001 (但し「注意」を参照)。"
5163
5164 #. type: Plain text
5165 #: build/C/man2/link.2:150
5166 msgid ""
5167 "Hard links, as created by B<link>(), cannot span file systems.  Use "
5168 "B<symlink>(2)  if this is required."
5169 msgstr ""
5170 "B<link>()  でファイルシステムを超えてハードリンクを作成することはできない。 "
5171 "このような場合は B<symlink>(2)  を使用すること。"
5172
5173 #.  more precisely: since kernel 1.3.56
5174 #.  For example, the default Solaris compilation environment
5175 #.  behaves like Linux, and contributors to a March 2005
5176 #.  thread in the Austin mailing list reported that some
5177 #.  other (System V) implementations did/do the same -- MTK, Apr 05
5178 #. type: Plain text
5179 #: build/C/man2/link.2:181
5180 msgid ""
5181 "POSIX.1-2001 says that B<link>()  should dereference I<oldpath> if it is a "
5182 "symbolic link.  However, since kernel 2.0, Linux does not do so: if "
5183 "I<oldpath> is a symbolic link, then I<newpath> is created as a (hard) link "
5184 "to the same symbolic link file (i.e., I<newpath> becomes a symbolic link to "
5185 "the same file that I<oldpath> refers to).  Some other implementations behave "
5186 "in the same manner as Linux.  POSIX.1-2008 changes the specification of "
5187 "B<link>(), making it implementation-dependent whether or not I<oldpath> is "
5188 "dereferenced if it is a symbolic link.  For precise control over the "
5189 "treatment of symbolic links when creating a link, see B<linkat>(2)."
5190 msgstr ""
5191 "POSIX.1-2001 では、 I<oldpath> がシンボリックリンクである場合、 B<link>()  "
5192 "は I<oldpath> の参照を解決すべきであると記述されている。 しかし、カーネル "
5193 "2.0 以降の Linux ではそのようになっていない。 I<oldpath> がシンボリックリンク"
5194 "である場合、 I<newpath> は同じシンボリックリンクファイルへの (ハード) リンク"
5195 "として作成される (つまり I<newpath> は I<oldpath> が参照していた同じファイル"
5196 "へのシンボリックリンクになる)。 他のいくつかの実装でも Linux と同じように動作"
5197 "する。 POSIX.1-2008 では B<link>()  の仕様が変更され、 I<oldpath> がシンボ"
5198 "リックリンクの場合にシンボリックリンクの参照を 解決するかどうかは実装依存と"
5199 "なった。 リンク作成時のシンボリックリンクの扱いについての詳細な制御に 関して"
5200 "は B<linkat>(2)  を参照のこと。"
5201
5202 #. type: Plain text
5203 #: build/C/man2/link.2:187
5204 msgid ""
5205 "On NFS file systems, the return code may be wrong in case the NFS server "
5206 "performs the link creation and dies before it can say so.  Use B<stat>(2)  "
5207 "to find out if the link got created."
5208 msgstr ""
5209 "NFS ファイルシステムでは、NFS サーバーがリンクを作成した後に、 それを伝える前"
5210 "に死んだ場合には返り値が不正な場合がある。 リンクが作成できたかどうか見つける"
5211 "ためには B<stat>(2)  を使用すること。"
5212
5213 #. type: Plain text
5214 #: build/C/man2/link.2:197
5215 msgid ""
5216 "B<ln>(1), B<linkat>(2), B<open>(2), B<rename>(2), B<stat>(2), B<symlink>(2), "
5217 "B<unlink>(2), B<path_resolution>(7), B<symlink>(7)"
5218 msgstr ""
5219 "B<ln>(1), B<linkat>(2), B<open>(2), B<rename>(2), B<stat>(2), B<symlink>(2), "
5220 "B<unlink>(2), B<path_resolution>(7), B<symlink>(7)"
5221
5222 #. type: TH
5223 #: build/C/man2/llseek.2:28
5224 #, no-wrap
5225 msgid "LLSEEK"
5226 msgstr "LLSEEK"
5227
5228 #. type: TH
5229 #: build/C/man2/llseek.2:28
5230 #, no-wrap
5231 msgid "2012-07-13"
5232 msgstr "2012-07-13"
5233
5234 #. type: Plain text
5235 #: build/C/man2/llseek.2:31
5236 msgid "_llseek - reposition read/write file offset"
5237 msgstr "_llseek - ファイルの読み書きオフセットの位置を変える"
5238
5239 #. type: Plain text
5240 #: build/C/man2/llseek.2:35
5241 #, no-wrap
5242 msgid ""
5243 "B<#include E<lt>sys/types.hE<gt>>\n"
5244 "B<#include E<lt>unistd.hE<gt>>\n"
5245 msgstr ""
5246 "B<#include E<lt>sys/types.hE<gt>>\n"
5247 "B<#include E<lt>unistd.hE<gt>>\n"
5248
5249 #. type: Plain text
5250 #: build/C/man2/llseek.2:39
5251 #, no-wrap
5252 msgid ""
5253 "B<int _llseek(unsigned int >I<fd>B<, unsigned long >I<offset_high>B<,>\n"
5254 "B<            unsigned long >I<offset_low>B<, loff_t *>I<result>B<,>\n"
5255 "B<            unsigned int >I<whence>B<);>\n"
5256 msgstr ""
5257 "B<int _llseek(unsigned int >I<fd>B<, unsigned long >I<offset_high>B<,>\n"
5258 "B<            unsigned long >I<offset_low>B<, loff_t *>I<result>B<,>\n"
5259 "B<            unsigned int >I<whence>B<);>\n"
5260
5261 #. type: Plain text
5262 #: build/C/man2/llseek.2:43
5263 msgid "I<Note>: There is no glibc wrapper for this system call; see NOTES."
5264 msgstr ""
5265 "I<注>: このシステムコールには glibc のラッパー関数は存在しない。「注意」の節"
5266 "を参照。"
5267
5268 #. type: Plain text
5269 #: build/C/man2/llseek.2:62
5270 msgid ""
5271 "The B<_llseek>()  function repositions the offset of the open file "
5272 "associated with the file descriptor I<fd> to I<(offset_highE<lt>E<lt>32) | "
5273 "offset_low> bytes relative to the beginning of the file, the current "
5274 "position in the file, or the end of the file, depending on whether I<whence> "
5275 "is B<SEEK_SET>, B<SEEK_CUR>, or B<SEEK_END>, respectively.  It returns the "
5276 "resulting file position in the argument I<result>."
5277 msgstr ""
5278 "B<_llseek>()  関数は、ファイルディスクリプタ (descriptor)  I<fd> に関連づけら"
5279 "れたオープンされたファイルのオフセットの位置を、相対的に I<"
5280 "(offset_highE<lt>E<lt>32) | offset_low> バイトだけ変更する。 基準となる位置を"
5281 "表す I<whence> には B<SEEK_SET>, B<SEEK_CUR>, B<SEEK_END> のいずれかを指定"
5282 "し、それぞれ ファイルの先頭、ファイルの現在位置、 ファイルの最後を表す。 結果"
5283 "のファイル位置を I<result> 引き数に返す。"
5284
5285 #. type: Plain text
5286 #: build/C/man2/llseek.2:69
5287 msgid ""
5288 "Upon successful completion, B<_llseek>()  returns 0.  Otherwise, a value of "
5289 "-1 is returned and I<errno> is set to indicate the error."
5290 msgstr ""
5291 "成功した場合は、 B<_llseek>()  は 0 を返す。 そうでなれば -1 という値が返り、"
5292 "エラーを示す I<errno> が設定される。"
5293
5294 #. type: Plain text
5295 #: build/C/man2/llseek.2:74 build/C/man2/lseek.2:175
5296 msgid "I<fd> is not an open file descriptor."
5297 msgstr "I<fd> がオープンされたファイルディスクリプタでない。"
5298
5299 #. type: Plain text
5300 #: build/C/man2/llseek.2:77
5301 msgid "Problem with copying results to user space."
5302 msgstr "結果をユーザ空間にコピーするときに問題があった。"
5303
5304 #. type: Plain text
5305 #: build/C/man2/llseek.2:81
5306 msgid "I<whence> is invalid."
5307 msgstr "I<whence> が不正である。"
5308
5309 #. type: Plain text
5310 #: build/C/man2/llseek.2:84
5311 msgid ""
5312 "This function is Linux-specific, and should not be used in programs intended "
5313 "to be portable."
5314 msgstr ""
5315 "この関数は Linux 特有であり、移植性の必要なプログラムでは使用してはいけない。"
5316
5317 #. type: Plain text
5318 #: build/C/man2/llseek.2:87
5319 msgid ""
5320 "Glibc does not provide a wrapper for this system call; call it using "
5321 "B<syscall>(2)."
5322 msgstr ""
5323 "glibc はこのシステムコールに対するラッパー関数を提供していない。 B<syscall>"
5324 "(2)  を使って呼び出すこと。"
5325
5326 #. type: Plain text
5327 #: build/C/man2/llseek.2:90
5328 msgid "B<lseek>(2), B<lseek64>(3)"
5329 msgstr "B<lseek>(2), B<lseek64>(3)"
5330
5331 #. type: TH
5332 #: build/C/man2/lseek.2:47
5333 #, no-wrap
5334 msgid "LSEEK"
5335 msgstr "LSEEK"
5336
5337 #. type: TH
5338 #: build/C/man2/lseek.2:47
5339 #, no-wrap
5340 msgid "2013-03-27"
5341 msgstr "2013-03-27"
5342
5343 #. type: Plain text
5344 #: build/C/man2/lseek.2:50
5345 msgid "lseek - reposition read/write file offset"
5346 msgstr "lseek - ファイルの読み書きオフセットの位置を変える"
5347
5348 #. type: Plain text
5349 #: build/C/man2/lseek.2:52 build/C/man3/lseek64.3:32
5350 msgid "B<#include E<lt>sys/types.hE<gt>>"
5351 msgstr "B<#include E<lt>sys/types.hE<gt>>"
5352
5353 #. type: Plain text
5354 #: build/C/man2/lseek.2:56
5355 msgid "B<off_t lseek(int >I<fd>B<, off_t >I<offset>B<, int >I<whence>B<);>"
5356 msgstr "B<off_t lseek(int >I<fd>B<, off_t >I<offset>B<, int >I<whence>B<);>"
5357
5358 #. type: Plain text
5359 #: build/C/man2/lseek.2:67
5360 msgid ""
5361 "The B<lseek>()  function repositions the offset of the open file associated "
5362 "with the file descriptor I<fd> to the argument I<offset> according to the "
5363 "directive I<whence> as follows:"
5364 msgstr ""
5365 "B<lseek>()  関数は、ファイルディスクリプタ (descriptor)  I<fd> に対応するオー"
5366 "プンされたファイルのオフセットを、 I<whence> に基づき I<offset> 引き数の位置"
5367 "へ以下のように変更する:"
5368
5369 #. type: Plain text
5370 #: build/C/man2/lseek.2:72
5371 msgid "The offset is set to I<offset> bytes."
5372 msgstr "オフセットは I<offset> バイトに設定される。"
5373
5374 #. type: Plain text
5375 #: build/C/man2/lseek.2:77
5376 msgid "The offset is set to its current location plus I<offset> bytes."
5377 msgstr "オフセットは現在位置に I<offset> バイトを足した位置になる。"
5378
5379 #. type: Plain text
5380 #: build/C/man2/lseek.2:82
5381 msgid "The offset is set to the size of the file plus I<offset> bytes."
5382 msgstr "オフセットはファイルのサイズに I<offset> バイトを足した位置になる。"
5383
5384 #. type: Plain text
5385 #: build/C/man2/lseek.2:90
5386 msgid ""
5387 "The B<lseek>()  function allows the file offset to be set beyond the end of "
5388 "the file (but this does not change the size of the file).  If data is later "
5389 "written at this point, subsequent reads of the data in the gap (a \"hole\") "
5390 "return null bytes (\\(aq\\e0\\(aq) until data is actually written into the "
5391 "gap."
5392 msgstr ""
5393 "B<lseek>()  関数は、オフセットをファイルの末尾を越えた位置に設定できる (但"
5394 "し、これによりファイルのサイズが変わらない)。 もしデータがこのオフセット位置"
5395 "以降に書き込まれた場合、 間の空隙の部分 (\"穴 (hole)\") の読み出しがあると、 "
5396 "実際にそこにデータを書き込まれるまでは NULL バイト (\\(aq\\e0\\(aq) の列が返"
5397 "される。"
5398
5399 #. type: SS
5400 #: build/C/man2/lseek.2:90
5401 #, no-wrap
5402 msgid "Seeking file data and holes"
5403 msgstr "ファイルのデータとホールの探索"
5404
5405 #. type: Plain text
5406 #: build/C/man2/lseek.2:93
5407 msgid ""
5408 "Since version 3.1, Linux supports the following additional values for "
5409 "I<whence>:"
5410 msgstr ""
5411 "Linux バージョン 3.1 以降では、 I<whence> に以下の値も指定することができる。"
5412
5413 #. type: TP
5414 #: build/C/man2/lseek.2:93
5415 #, no-wrap
5416 msgid "B<SEEK_DATA>"
5417 msgstr "B<SEEK_DATA>"
5418
5419 #. type: Plain text
5420 #: build/C/man2/lseek.2:104
5421 msgid ""
5422 "Adjust the file offset to the next location in the file greater than or "
5423 "equal to I<offset> containing data.  If I<offset> points to data, then the "
5424 "file offset is set to I<offset>."
5425 msgstr ""
5426 "ファイルオフセットを I<offset> 以上で次にデータがある位置に設定する。 "
5427 "I<offset> がデータを指している場合には、 ファイルオフセットは I<offset> に設"
5428 "定される。"
5429
5430 #. type: TP
5431 #: build/C/man2/lseek.2:104
5432 #, no-wrap
5433 msgid "B<SEEK_HOLE>"
5434 msgstr "B<SEEK_HOLE>"
5435
5436 #. type: Plain text
5437 #: build/C/man2/lseek.2:118
5438 msgid ""
5439 "Adjust the file offset to the next hole in the file greater than or equal to "
5440 "I<offset>.  If I<offset> points into the middle of a hole, then the file "
5441 "offset is set to I<offset>.  If there is no hole past I<offset>, then the "
5442 "file offset is adjusted to the end of the file (i.e., there is an implicit "
5443 "hole at the end of any file)."
5444 msgstr ""
5445 "ファイルオフセットを、 位置が I<offset> 以上の次のホール (hole) に設定する。 "
5446 "I<offset> がホールの内部にある場合は、ファイルシステムは I<offset> に設定され"
5447 "る。 I<offset> 以降にホールがない場合は、 ファイルオフセットはファイル末尾に"
5448 "設定される (つまり、 どのファイルの末尾にも暗黙のホールが存在するということ"
5449 "だ)。"
5450
5451 #. type: Plain text
5452 #: build/C/man2/lseek.2:124
5453 msgid ""
5454 "In both of the above cases, B<lseek>()  fails if I<offset> points past the "
5455 "end of the file."
5456 msgstr ""
5457 "上記のどちらの場合も、 I<offset> がファイル末尾よりも先を指している場合には "
5458 "B<lseek>() は失敗する。"
5459
5460 #. type: Plain text
5461 #: build/C/man2/lseek.2:130
5462 msgid ""
5463 "These operations allow applications to map holes in a sparsely allocated "
5464 "file.  This can be useful for applications such as file backup tools, which "
5465 "can save space when creating backups and preserve holes, if they have a "
5466 "mechanism for discovering holes."
5467 msgstr ""
5468 "これらの操作を使うことで、 アプリケーションが、 まばら (sparse ) にページが割"
5469 "り当てられたファイルでホールをマップすることができる。 この機能はファイルバッ"
5470 "クアップツールなどのアプリケーションで有用である。 ホールを見つける仕組みがあ"
5471 "れば、 ファイルバックアップツールで、 バックアップを作成する際に保存領域を節"
5472 "約し、ホールを保持することができる。"
5473
5474 #.  https://lkml.org/lkml/2011/4/22/79
5475 #.  http://lwn.net/Articles/440255/
5476 #.  http://blogs.oracle.com/bonwick/entry/seek_hole_and_seek_data
5477 #. type: Plain text
5478 #: build/C/man2/lseek.2:153
5479 msgid ""
5480 "For the purposes of these operations, a hole is a sequence of zeros that "
5481 "(normally) has not been allocated in the underlying file storage.  However, "
5482 "a file system is not obliged to report holes, so these operations are not a "
5483 "guaranteed mechanism for mapping the storage space actually allocated to a "
5484 "file.  (Furthermore, a sequence of zeros that actually has been written to "
5485 "the underlying storage may not be reported as a hole.)  In the simplest "
5486 "implementation, a file system can support the operations by making "
5487 "B<SEEK_HOLE> always return the offset of the end of the file, and making "
5488 "B<SEEK_DATA> always return I<offset> (i.e., even if the location referred to "
5489 "by I<offset> is a hole, it can be considered to consist of data that is a "
5490 "sequence of zeros)."
5491 msgstr ""
5492 "これらの操作の目的としては、 ホールは (通常は) バックエンドのファイルストレー"
5493 "ジには割り当てられていない連続する 0 の列である。 しかし、ファイルシステムに"
5494 "はホールを報告する義務はなく、 そのため、 これらの操作は、 ファイルに実際に割"
5495 "り当てられたストレージ領域をマッピングする方法としては確実性のある仕組みでは"
5496 "ない。 (また、バックエンドのストレージに実際に書き込まれた連続する 0 の列は"
5497 "ホールとして報告されないこともある。) 最も単純な実装としては、 B<SEEK_HOLE> "
5498 "は常にファイル末尾のオフセットを返すようにし、 B<SEEK_DATA> は常に I<offset> "
5499 "を返すようにすることで、 ファイルシステムはこれらの操作をサポートすることがで"
5500 "きる (B<SEEK_DATA> は常に I<offset> を返すというのは、 I<offset> が参照する場"
5501 "所がホールであったとしても、 連続する 0 の列のデータで構成されているとみなす"
5502 "ということである)。"
5503
5504 #. type: Plain text
5505 #: build/C/man2/lseek.2:162
5506 msgid ""
5507 "The B<_GNU_SOURCE> feature test macro must be defined in order to obtain the "
5508 "definitions of B<SEEK_DATA> and B<SEEK_HOLE> from I<E<lt>unistd.hE<gt>>."
5509 msgstr ""
5510 "I<E<lt>unistd.hE<gt>> から B<SEEK_DATA> と B<SEEK_HOLE> の定義を得るには、 機"
5511 "能検査マクロ B<_GNU_SOURCE> を定義しなければならない。"
5512
5513 #. type: Plain text
5514 #: build/C/man2/lseek.2:170
5515 msgid ""
5516 "Upon successful completion, B<lseek>()  returns the resulting offset "
5517 "location as measured in bytes from the beginning of the file.  On error, the "
5518 "value I<(off_t)\\ -1> is returned and I<errno> is set to indicate the error."
5519 msgstr ""
5520 "成功した場合、 B<lseek>()  は結果のファイル位置をファイルの先頭からのバイト数"
5521 "で返す。 エラーの場合、値 I<(off_t)\\ -1> が返され、 I<errno> にエラーが指示"
5522 "される。"
5523
5524 #.  Some systems may allow negative offsets for character devices
5525 #.  and/or for remote file systems.
5526 #. type: Plain text
5527 #: build/C/man2/lseek.2:183
5528 msgid ""
5529 "I<whence> is not valid.  Or: the resulting file offset would be negative, or "
5530 "beyond the end of a seekable device."
5531 msgstr ""
5532 "I<whence> が有効な値ではない。または、seek の結果、ファイルオフセットが負に\n"
5533 "なってしまうか、 seek 可能なデバイスの末尾を越えてしまう。"
5534
5535 #. type: TP
5536 #: build/C/man2/lseek.2:183 build/C/man2/open.2:584
5537 #, no-wrap
5538 msgid "B<EOVERFLOW>"
5539 msgstr "B<EOVERFLOW>"
5540
5541 #.  HP-UX 11 says EINVAL for this case (but POSIX.1 says EOVERFLOW)
5542 #. type: Plain text
5543 #: build/C/man2/lseek.2:188
5544 msgid "The resulting file offset cannot be represented in an I<off_t>."
5545 msgstr "結果のファイルオフセットを I<off_t> 型で表現することができない。"
5546
5547 #. type: TP
5548 #: build/C/man2/lseek.2:188
5549 #, no-wrap
5550 msgid "B<ESPIPE>"
5551 msgstr "B<ESPIPE>"
5552
5553 #. type: Plain text
5554 #: build/C/man2/lseek.2:192
5555 msgid "I<fd> is associated with a pipe, socket, or FIFO."
5556 msgstr "I<fd> がパイプ、ソケット、FIFO を参照している。"
5557
5558 #. type: TP
5559 #: build/C/man2/lseek.2:192 build/C/man2/open.2:578
5560 #, no-wrap
5561 msgid "B<ENXIO>"
5562 msgstr "B<ENXIO>"
5563
5564 #. type: Plain text
5565 #: build/C/man2/lseek.2:200
5566 msgid ""
5567 "I<whence> is B<SEEK_DATA> or B<SEEK_HOLE>, and the current file offset is "
5568 "beyond the end of the file."
5569 msgstr ""
5570 "I<whence> が B<SEEK_DATA> か B<SEEK_HOLE> で、\n"
5571 "現在のファイルオフセットがファイルの末尾を超えた位置である。"
5572
5573 #.  SVr4 documents additional error
5574 #.  conditions EDEADLK, ENOLCK, ENOLNK, ENOSR, ENXIO, or ERANGE.
5575 #. type: Plain text
5576 #: build/C/man2/lseek.2:202 build/C/man2/read.2:175 build/C/man2/rmdir.2:129
5577 #: build/C/man2/symlink.2:155 build/C/man2/unlink.2:145
5578 #: build/C/man2/write.2:189
5579 msgid "SVr4, 4.3BSD, POSIX.1-2001."
5580 msgstr "SVr4, 4.3BSD, POSIX.1-2001."
5581
5582 #.  FIXME . Review http://austingroupbugs.net/view.php?id=415 in the future
5583 #. type: Plain text
5584 #: build/C/man2/lseek.2:210
5585 msgid ""
5586 "B<SEEK_DATA> and B<SEEK_HOLE> are nonstandard extensions also present in "
5587 "Solaris, FreeBSD, and DragonFly BSD; they are proposed for inclusion in the "
5588 "next POSIX revision (Issue 8)."
5589 msgstr ""
5590 "B<SEEK_DATA> と B<SEEK_HOLE> は非標準の拡張で、 Solaris, FreeBSD, DragonFly "
5591 "BSD にも存在する。 これらは POSIX の次の版 (Issue 8) に入れるよう提案されてい"
5592 "る。"
5593
5594 #. type: Plain text
5595 #: build/C/man2/lseek.2:214
5596 msgid ""
5597 "Some devices are incapable of seeking and POSIX does not specify which "
5598 "devices must support B<lseek>()."
5599 msgstr ""
5600 "いくつかのデバイスでは seek ができない。 POSIX はどのデバイスが B<lseek>()  "
5601 "に対応すべきかは規定していない。"
5602
5603 #.  Other systems return the number of written characters,
5604 #.  using SEEK_SET to set the counter. (Of written characters.)
5605 #. type: Plain text
5606 #: build/C/man2/lseek.2:221
5607 msgid "On Linux, using B<lseek>()  on a terminal device returns B<ESPIPE>."
5608 msgstr ""
5609 "Linux では、端末 (terminal) デバイスに B<lseek>() を使用すると B<ESPIPE> が返"
5610 "る。"
5611
5612 #. type: Plain text
5613 #: build/C/man2/lseek.2:224
5614 msgid ""
5615 "When converting old code, substitute values for I<whence> with the following "
5616 "macros:"
5617 msgstr "古いコードを変換する時は I<whence> の値を以下のマクロに置き換えること:"
5618
5619 #. type: tbl table
5620 #: build/C/man2/lseek.2:227
5621 #, no-wrap
5622 msgid "old\tnew\n"
5623 msgstr "old \tnew\n"
5624
5625 #. type: tbl table
5626 #: build/C/man2/lseek.2:228
5627 #, no-wrap
5628 msgid "0\tSEEK_SET\n"
5629 msgstr "0\tSEEK_SET\n"
5630
5631 #. type: tbl table
5632 #: build/C/man2/lseek.2:229
5633 #, no-wrap
5634 msgid "1\tSEEK_CUR\n"
5635 msgstr "1\tSEEK_CUR\n"
5636
5637 #. type: tbl table
5638 #: build/C/man2/lseek.2:230
5639 #, no-wrap
5640 msgid "2\tSEEK_END\n"
5641 msgstr "2\tSEEK_END\n"
5642
5643 #. type: tbl table
5644 #: build/C/man2/lseek.2:231
5645 #, no-wrap
5646 msgid "L_SET\tSEEK_SET\n"
5647 msgstr "L_SET\tSEEK_SET\n"
5648
5649 #. type: tbl table
5650 #: build/C/man2/lseek.2:232
5651 #, no-wrap
5652 msgid "L_INCR\tSEEK_CUR\n"
5653 msgstr "L_INCR\tSEEK_CUR\n"
5654
5655 #. type: tbl table
5656 #: build/C/man2/lseek.2:233
5657 #, no-wrap
5658 msgid "L_XTND\tSEEK_END\n"
5659 msgstr "L_XTND\tSEEK_END\n"
5660
5661 #. type: Plain text
5662 #: build/C/man2/lseek.2:245
5663 msgid ""
5664 "Note that file descriptors created by B<dup>(2)  or B<fork>(2)  share the "
5665 "current file position pointer, so seeking on such files may be subject to "
5666 "race conditions."
5667 msgstr ""
5668 "B<dup>(2)  や B<fork>(2)  で作成されたファイルディスクリプタは、現在のファイ"
5669 "ル位置ポインタ (current file position pointer) を共有しているので、 このよう"
5670 "なファイルで移動を行うと競合状態を引き起こす可能性がある。"
5671
5672 #. type: Plain text
5673 #: build/C/man2/lseek.2:252
5674 msgid ""
5675 "B<dup>(2), B<fork>(2), B<open>(2), B<fseek>(3), B<lseek64>(3), "
5676 "B<posix_fallocate>(3)"
5677 msgstr ""
5678 "B<dup>(2), B<fork>(2), B<open>(2), B<fseek>(3), B<lseek64>(3), "
5679 "B<posix_fallocate>(3)"
5680
5681 #. type: TH
5682 #: build/C/man3/lseek64.3:25
5683 #, no-wrap
5684 msgid "LSEEK64"
5685 msgstr "LSEEK64"
5686
5687 #. type: TH
5688 #: build/C/man3/lseek64.3:25
5689 #, no-wrap
5690 msgid "2004-12-11"
5691 msgstr "2004-12-11"
5692
5693 #. type: Plain text
5694 #: build/C/man3/lseek64.3:28
5695 msgid "lseek64 - reposition 64-bit read/write file offset"
5696 msgstr "lseek64 - ファイルの 64 ビットの読み書きオフセットの位置を変える"
5697
5698 #. type: Plain text
5699 #: build/C/man3/lseek64.3:30
5700 msgid "B<#define _LARGEFILE64_SOURCE> /* See feature_test_macros(7) */"
5701 msgstr "B<#define _LARGEFILE64_SOURCE> /* feature_test_macros(7) 参照 */"
5702
5703 #. type: Plain text
5704 #: build/C/man3/lseek64.3:36
5705 msgid ""
5706 "B<off64_t lseek64(int >I<fd>B<, off64_t >I<offset>B<, int >I<whence>B<);>"
5707 msgstr ""
5708 "B<off64_t lseek64(int >I<fd>B<, off64_t >I<offset>B<, int >I<whence>B<);>"
5709
5710 #. type: Plain text
5711 #: build/C/man3/lseek64.3:53
5712 msgid ""
5713 "The B<lseek>(2)  family of functions reposition the offset of the open file "
5714 "associated with the file descriptor I<fd> to I<offset> bytes relative to the "
5715 "start, current position, or end of the file, when I<whence> has the value "
5716 "B<SEEK_SET>, B<SEEK_CUR>, or B<SEEK_END>, respectively."
5717 msgstr ""
5718 "B<lseek>(2)  関数ファミリーは、ファイルディスクリプタ I<fd> に関連するオープ"
5719 "ンされたファイルのオフセットを、 ファイルの開始位置・現在位置・終端から "
5720 "I<offset> の位置へ変更する。 これは I<whence> がそれぞれ B<SEEK_SET>, "
5721 "B<SEEK_CUR>, B<SEEK_END> の場合に対応する。"
5722
5723 #. type: Plain text
5724 #: build/C/man3/lseek64.3:56
5725 msgid "For more details, return value, and errors, see B<lseek>(2)."
5726 msgstr "更に詳しい説明・返り値・エラーは、 B<lseek>(2)  を参照すること。"
5727
5728 #. type: Plain text
5729 #: build/C/man3/lseek64.3:63
5730 msgid ""
5731 "Four interfaces are available: B<lseek>(2), B<lseek64>(), B<llseek>(2), and "
5732 "the raw system call B<_llseek>(2)."
5733 msgstr ""
5734 "4 つのインタフェースが使用可能である: B<lseek>(2), B<lseek64>(), B<llseek>"
5735 "(2)  と元となるシステムコール B<_llseek>(2)  である。"
5736
5737 #. type: SS
5738 #: build/C/man3/lseek64.3:63
5739 #, no-wrap
5740 msgid "lseek"
5741 msgstr "lseek"
5742
5743 #. type: Plain text
5744 #: build/C/man3/lseek64.3:65 build/C/man3/lseek64.3:87
5745 #: build/C/man3/lseek64.3:116
5746 msgid "Prototype:"
5747 msgstr "プロトタイプ:"
5748
5749 #. type: Plain text
5750 #: build/C/man3/lseek64.3:69
5751 #, no-wrap
5752 msgid "B<off_t lseek(int >I<fd>B<, off_t >I<offset>B<, int >I<whence>B<);>\n"
5753 msgstr "B<off_t lseek(int >I<fd>B<, off_t >I<offset>B<, int >I<whence>B<);>\n"
5754
5755 #. type: Plain text
5756 #: build/C/man3/lseek64.3:77
5757 msgid ""
5758 "B<lseek>(2)  uses the type I<off_t>.  This is a 32-bit signed type on 32-bit "
5759 "architectures, unless one compiles with"
5760 msgstr ""
5761 "B<lseek>(2)  は型 I<off_t> を使う。 これは 32 ビットアーキテクチャ上では 32 "
5762 "ビット符号付き型である。 ただし、"
5763
5764 #. type: Plain text
5765 #: build/C/man3/lseek64.3:85
5766 msgid "in which case it is a 64-bit signed type."
5767 msgstr "を定義してコンパイルした場合は 64 ビット符号付き型である。"
5768
5769 #. type: SS
5770 #: build/C/man3/lseek64.3:85
5771 #, no-wrap
5772 msgid "lseek64"
5773 msgstr "lseek64"
5774
5775 #. type: Plain text
5776 #: build/C/man3/lseek64.3:91
5777 #, no-wrap
5778 msgid "B<off64_t lseek64(int >I<fd>B<, off64_t >I<offset>B<, int >I<whence>B<);>\n"
5779 msgstr "B<off64_t lseek64(int >I<fd>B<, off64_t >I<offset>B<, int >I<whence>B<);>\n"
5780
5781 #. type: Plain text
5782 #: build/C/man3/lseek64.3:102
5783 msgid ""
5784 "The library routine B<lseek64>()  uses a 64-bit type even when I<off_t> is a "
5785 "32-bit type.  Its prototype (and the type I<off64_t>)  is available only "
5786 "when one compiles with"
5787 msgstr ""
5788 "ライブラリルーチン B<lseek64>()  は I<off_t> が 32 ビット型であっても 64 ビッ"
5789 "ト型を使う。 このプロトタイプ (と型 I<off64_t>)  は、以下の定義をしてコンパイ"
5790 "ルした場合にのみ使用可能である。"
5791
5792 #. type: Plain text
5793 #: build/C/man3/lseek64.3:106
5794 #, no-wrap
5795 msgid "#define _LARGEFILE64_SOURCE\n"
5796 msgstr "#define _LARGEFILE64_SOURCE\n"
5797
5798 #.  in glibc 2.0.94, not in 2.0.6
5799 #. type: Plain text
5800 #: build/C/man3/lseek64.3:114
5801 msgid ""
5802 "The function B<lseek64>()  is available since glibc 2.1, and is defined to "
5803 "be an alias for B<llseek>()."
5804 msgstr ""
5805 "関数 B<lseek64>()  は glibc 2.1 以降で使用可能であり、 B<llseek>()  のエイリ"
5806 "アスとして定義されている。"
5807
5808 #. type: SS
5809 #: build/C/man3/lseek64.3:114
5810 #, no-wrap
5811 msgid "llseek"
5812 msgstr "llseek"
5813
5814 #. type: Plain text
5815 #: build/C/man3/lseek64.3:120
5816 #, no-wrap
5817 msgid "B<loff_t llseek(int >I<fd>B<, loff_t >I<offset>B<, int >I<whence>B<);>\n"
5818 msgstr "B<loff_t llseek(int >I<fd>B<, loff_t >I<offset>B<, int >I<whence>B<);>\n"
5819
5820 #.  in libc 5.0.9, not in 4.7.6
5821 #. type: Plain text
5822 #: build/C/man3/lseek64.3:139
5823 msgid ""
5824 "The type I<loff_t> is a 64-bit signed type.  The library routine B<llseek>"
5825 "()  is available in libc5 and glibc and works without special defines.  Its "
5826 "prototype was given in I<E<lt>unistd.hE<gt>> with libc5, but glibc does not "
5827 "provide a prototype.  This is bad, since a prototype is needed.  Users "
5828 "should add the above prototype, or something equivalent, to their own "
5829 "source.  When users complained about data loss caused by a miscompilation of "
5830 "B<e2fsck>(8), glibc 2.1.3 added the link-time warning"
5831 msgstr ""
5832 "型 I<loff_t> は 64 ビット符号付き型である。 ライブラリルーチン B<llseek>()  "
5833 "は libc5 と glibc で使用可能であり、特別な定義なしに動作する。 このプロトタイ"
5834 "プは、libc5 では I<E<lt>unistd.hE<gt>> で与えられるが、glibc はプロトタイプを"
5835 "提供しない。 これはプロトタイプが必要になるので良くない。 ユーザは上記のプロ"
5836 "トタイプまたはそれと同等のものを、 自身のソースに追加しなければならない。 こ"
5837 "のデータがないことによって B<e2fsck>(8)  のコンパイルが失敗するという苦情が"
5838 "ユーザから出たので、 glibc 2.1.3 では以下のようなリンク時の警告が追加された。"
5839
5840 #. type: Plain text
5841 #: build/C/man3/lseek64.3:142
5842 msgid "the \\`llseek\\' function may be dangerous; use \\`lseek64\\' instead."
5843 msgstr "the \\`llseek\\' function may be dangerous; use \\`lseek64\\' instead."
5844
5845 #. type: Plain text
5846 #: build/C/man3/lseek64.3:146
5847 msgid ""
5848 "This makes this function unusable if one desires a warning-free compilation."
5849 msgstr ""
5850 "これにより、警告なしでコンパイルしたい場合には、この関数を使用不可にできる。"
5851
5852 #. type: SS
5853 #: build/C/man3/lseek64.3:146
5854 #, no-wrap
5855 msgid "_llseek"
5856 msgstr "_llseek"
5857
5858 #. type: Plain text
5859 #: build/C/man3/lseek64.3:149
5860 msgid ""
5861 "All the above functions are implemented in terms of this system call.  The "
5862 "prototype is:"
5863 msgstr ""
5864 "上記の全ての関数は、このシステムコールに基づいて実装される。 プロトタイプは以"
5865 "下の通り:"
5866
5867 #. type: Plain text
5868 #: build/C/man3/lseek64.3:154
5869 #, no-wrap
5870 msgid ""
5871 "B<int _llseek(int >I<fd>B<, off_t >I<offset_hi>B<, off_t >I<offset_lo>B<,>\n"
5872 "B<            loff_t *>I<result>B<, int >I<whence>B<);>\n"
5873 msgstr ""
5874 "B<int _llseek(int >I<fd>B<, off_t >I<offset_hi>B<, off_t >I<offset_lo>B<,>\n"
5875 "B<            loff_t *>I<result>B<, int >I<whence>B<);>\n"
5876
5877 #. type: Plain text
5878 #: build/C/man3/lseek64.3:159
5879 msgid "For more details, see B<llseek>(2)."
5880 msgstr "更に詳しい情報は、 B<llseek>(2)  を参照すること。"
5881
5882 #. type: Plain text
5883 #: build/C/man3/lseek64.3:162
5884 msgid "B<llseek>(2), B<lseek>(2)"
5885 msgstr "B<llseek>(2), B<lseek>(2)"
5886
5887 #. type: TH
5888 #: build/C/man2/open.2:52
5889 #, no-wrap
5890 msgid "OPEN"
5891 msgstr "OPEN"
5892
5893 #. type: TH
5894 #: build/C/man2/open.2:52
5895 #, no-wrap
5896 msgid "2013-02-18"
5897 msgstr "2013-02-18"
5898
5899 #. type: Plain text
5900 #: build/C/man2/open.2:55
5901 msgid "open, creat - open and possibly create a file or device"
5902 msgstr "open, creat - ファイルやデバイスのオープン、作成を行う"
5903
5904 #. type: Plain text
5905 #: build/C/man2/open.2:60
5906 #, no-wrap
5907 msgid ""
5908 "B<#include E<lt>sys/types.hE<gt>>\n"
5909 "B<#include E<lt>sys/stat.hE<gt>>\n"
5910 "B<#include E<lt>fcntl.hE<gt>>\n"
5911 msgstr ""
5912 "B<#include E<lt>sys/types.hE<gt>>\n"
5913 "B<#include E<lt>sys/stat.hE<gt>>\n"
5914 "B<#include E<lt>fcntl.hE<gt>>\n"
5915
5916 #. type: Plain text
5917 #: build/C/man2/open.2:63
5918 #, no-wrap
5919 msgid ""
5920 "B<int open(const char *>I<pathname>B<, int >I<flags>B<);>\n"
5921 "B<int open(const char *>I<pathname>B<, int >I<flags>B<, mode_t >I<mode>B<);>\n"
5922 msgstr ""
5923 "B<int open(const char *>I<pathname>B<, int >I<flags>B<);>\n"
5924 "B<int open(const char *>I<pathname>B<, int >I<flags>B<, mode_t >I<mode>B<);>\n"
5925
5926 #. type: Plain text
5927 #: build/C/man2/open.2:65
5928 #, no-wrap
5929 msgid "B<int creat(const char *>I<pathname>B<, mode_t >I<mode>B<);>\n"
5930 msgstr "B<int creat(const char *>I<pathname>B<, mode_t >I<mode>B<);>\n"
5931
5932 #. type: Plain text
5933 #: build/C/man2/open.2:76
5934 msgid ""
5935 "Given a I<pathname> for a file, B<open>()  returns a file descriptor, a "
5936 "small, nonnegative integer for use in subsequent system calls (B<read>(2), "
5937 "B<write>(2), B<lseek>(2), B<fcntl>(2), etc.).  The file descriptor returned "
5938 "by a successful call will be the lowest-numbered file descriptor not "
5939 "currently open for the process."
5940 msgstr ""
5941 "ファイルの I<pathname> を与えると、 B<open>()  はファイルディスクリプタを返"
5942 "す。 ファイルディスクリプタは、この後に続くシステムコール (B<read>(2), "
5943 "B<write>(2), B<lseek>(2), B<fcntl>(2) など)  で使用される小さな非負の整数であ"
5944 "る。 このシステムコールが成功した場合に返されるファイルディスクリプタは その"
5945 "プロセスがその時点でオープンしていないファイルディスクリプタの うち最小の数字"
5946 "のものとなる。"
5947
5948 #. type: Plain text
5949 #: build/C/man2/open.2:88
5950 msgid ""
5951 "By default, the new file descriptor is set to remain open across an B<execve>"
5952 "(2)  (i.e., the B<FD_CLOEXEC> file descriptor flag described in B<fcntl>(2)  "
5953 "is initially disabled; the B<O_CLOEXEC> flag, described below, can be used "
5954 "to change this default).  The file offset is set to the beginning of the "
5955 "file (see B<lseek>(2))."
5956 msgstr ""
5957 "デフォルトでは、新しいファイルディスクリプタは B<execve>(2) を実行した後も\n"
5958 "オープンされたままとなる (つまり、 B<fcntl>(2) に説明がある B<FD_CLOEXEC> \n"
5959 "ファイルディスクリプタフラグは最初は無効である; 後述の B<O_CLOEXEC> フラグ\n"
5960 "を使うとこのデフォルトを変更することができる)。 ファイルオフセット \n"
5961 "(file offset) はファイルの先頭に設定される (B<lseek>(2) 参照)。"
5962
5963 #. type: Plain text
5964 #: build/C/man2/open.2:107
5965 msgid ""
5966 "A call to B<open>()  creates a new I<open file description>, an entry in the "
5967 "system-wide table of open files.  This entry records the file offset and the "
5968 "file status flags (modifiable via the B<fcntl>(2)  B<F_SETFL> operation).  A "
5969 "file descriptor is a reference to one of these entries; this reference is "
5970 "unaffected if I<pathname> is subsequently removed or modified to refer to a "
5971 "different file.  The new open file description is initially not shared with "
5972 "any other process, but sharing may arise via B<fork>(2)."
5973 msgstr ""
5974 "B<open>()  を呼び出すと、「オープンファイル記述」 I<(open file description)> "
5975 "が作成される。ファイル記述とは、システム全体の オープン中のファイルのテーブル"
5976 "のエントリである。 このエントリは、ファイルオフセットとファイル状態フラグ "
5977 "(B<fcntl>(2)  B<F_SETFL> 操作により変更可能) が保持する。 ファイルディスクリ"
5978 "プタはこれらのエントリの一つへの参照である。 この後で I<pathname> が削除され"
5979 "たり、他のファイルを参照するように変更されたりしても、 この参照は影響を受けな"
5980 "い。 新しいオープンファイル記述は最初は他のどのプロセスとも 共有されていない"
5981 "が、 B<fork>(2)  で共有が起こる場合がある。"
5982
5983 #. type: Plain text
5984 #: build/C/man2/open.2:115
5985 msgid ""
5986 "The argument I<flags> must include one of the following I<access modes>: "
5987 "B<O_RDONLY>, B<O_WRONLY>, or B<O_RDWR>.  These request opening the file read-"
5988 "only, write-only, or read/write, respectively."
5989 msgstr ""
5990 "引き数 I<flags> には、アクセスモード B<O_RDONLY>, B<O_WRONLY>, B<O_RDWR> のど"
5991 "れかひとつが入っていなければならない。 これらはそれぞれ読み込み専用、書き込み"
5992 "専用、読み書き用に ファイルをオープンすることを要求するものである。"
5993
5994 #.  SUSv4 divides the flags into:
5995 #.  * Access mode
5996 #.  * File creation
5997 #.  * File status
5998 #.  * Other (O_CLOEXEC, O_DIRECTORY, O_NOFOLLOW)
5999 #.  though it's not clear what the difference between "other" and
6000 #.  "File creation" flags is.  I raised an Aardvark to see if this
6001 #.  can be clarified in SUSv4; 10 Oct 2008.
6002 #.  http://thread.gmane.org/gmane.comp.standards.posix.austin.general/64/focus=67
6003 #.  TC1 (balloted in 2013), resolved this, so that those three constants
6004 #.  are also categorized" as file status flags.
6005 #. type: Plain text
6006 #: build/C/man2/open.2:153
6007 msgid ""
6008 "In addition, zero or more file creation flags and file status flags can be "
6009 "bitwise-I<or>'d in I<flags>.  The I<file creation flags> are B<O_CLOEXEC>, "
6010 "B<O_CREAT>, B<O_DIRECTORY>, B<O_EXCL>, B<O_NOCTTY>, B<O_NOFOLLOW>, "
6011 "B<O_TRUNC>, and B<O_TTY_INIT>.  The I<file status flags> are all of the "
6012 "remaining flags listed below.  The distinction between these two groups of "
6013 "flags is that the file status flags can be retrieved and (in some cases)  "
6014 "modified using B<fcntl>(2).  The full list of file creation flags and file "
6015 "status flags is as follows:"
6016 msgstr ""
6017 "さらに、 I<flags> には、ファイル作成フラグ (file creation flag) とファイル状"
6018 "態フラグ (file status flag) を 0 個以上「ビット単位の OR (bitwise-or)」で 指"
6019 "定することができる。 I<ファイル作成フラグ> は B<O_CLOEXEC>, B<O_CREAT>, "
6020 "B<O_DIRECTORY>, B<O_EXCL>, B<O_NOCTTY>, B<O_NOFOLLOW>, B<O_TRUNC>, "
6021 "B<O_TTY_INIT> である。 I<ファイル状態フラグ> は以下のリストのうち上記以外の残"
6022 "りのものである。 二種類のフラグの違いは、ファイル状態フラグの方は B<fcntl>"
6023 "(2)  を使ってその内容を取得したり (場合によっては) 変更したりできる点にあ"
6024 "る。 ファイル作成フラグとファイル状態フラグの全リストを以下に示す:"
6025
6026 #. type: TP
6027 #: build/C/man2/open.2:153
6028 #, no-wrap
6029 msgid "B<O_APPEND>"
6030 msgstr "B<O_APPEND>"
6031
6032 #.  For more background, see
6033 #.  http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=453946
6034 #.  http://nfs.sourceforge.net/
6035 #. type: Plain text
6036 #: build/C/man2/open.2:170
6037 msgid ""
6038 "The file is opened in append mode.  Before each B<write>(2), the file offset "
6039 "is positioned at the end of the file, as if with B<lseek>(2).  B<O_APPEND> "
6040 "may lead to corrupted files on NFS file systems if more than one process "
6041 "appends data to a file at once.  This is because NFS does not support "
6042 "appending to a file, so the client kernel has to simulate it, which can't be "
6043 "done without a race condition."
6044 msgstr ""
6045 "ファイルを追加 (append) モードでオープンする。 毎回の B<write>(2)  の前に "
6046 "B<lseek>(2)  を行ったかのように、ファイルポインタをファイルの最後に移動す"
6047 "る。 NFS ファイルシステムで、 B<O_APPEND> を使用すると、複数のプロセスがひと"
6048 "つのファイルに同時にデータを追加した場合、 ファイルが壊れてしまうことがあ"
6049 "る。 これは NFS が追加モードをサポートしていないため、 クライアントのカーネ"
6050 "ル (kernel) がそれをシミュレートしなければならないのだが、 競合状態を避けるこ"
6051 "とはできないからである。"
6052
6053 #. type: TP
6054 #: build/C/man2/open.2:170
6055 #, no-wrap
6056 msgid "B<O_ASYNC>"
6057 msgstr "B<O_ASYNC>"
6058
6059 #. type: Plain text
6060 #: build/C/man2/open.2:183
6061 msgid ""
6062 "Enable signal-driven I/O: generate a signal (B<SIGIO> by default, but this "
6063 "can be changed via B<fcntl>(2))  when input or output becomes possible on "
6064 "this file descriptor.  This feature is available only for terminals, "
6065 "pseudoterminals, sockets, and (since Linux 2.6) pipes and FIFOs.  See "
6066 "B<fcntl>(2)  for further details."
6067 msgstr ""
6068 "シグナル駆動 I/O (signal-driven I/O) を有効にする: このファイルディスクリプタ"
6069 "への 入力または出力が可能になった場合に、シグナルを生成する (デフォルトは "
6070 "B<SIGIO> であるが、 B<fcntl>(2)  によって変更可能である)。 この機能が使用可能"
6071 "なのは端末、疑似端末、ソケットのみであり、 (Linux 2.6 以降では) パイプと "
6072 "FIFO に対しても使用できる。 さらに詳しい説明は B<fcntl>(2)  を参照すること。"
6073
6074 #. type: TP
6075 #: build/C/man2/open.2:183
6076 #, no-wrap
6077 msgid "B<O_CLOEXEC> (Since Linux 2.6.23)"
6078 msgstr "B<O_CLOEXEC> (Linux 2.6.23 以降)"
6079
6080 #.  This flag fixes only one form of the race condition;
6081 #.  The race can also occur with, for example, descriptors
6082 #.  returned by accept(), pipe(), etc.
6083 #. type: Plain text
6084 #: build/C/man2/open.2:208
6085 msgid ""
6086 "Enable the close-on-exec flag for the new file descriptor.  Specifying this "
6087 "flag permits a program to avoid additional B<fcntl>(2)  B<F_SETFD> "
6088 "operations to set the B<FD_CLOEXEC> flag.  Additionally, use of this flag is "
6089 "essential in some multithreaded programs since using a separate B<fcntl>(2)  "
6090 "B<F_SETFD> operation to set the B<FD_CLOEXEC> flag does not suffice to avoid "
6091 "race conditions where one thread opens a file descriptor at the same time as "
6092 "another thread does a B<fork>(2)  plus B<execve>(2)."
6093 msgstr ""
6094 "新しいファイルディスクリプタに対して close-on-exec フラグを有効にする。 この"
6095 "フラグを指定することで、プログラムは B<FD_CLOEXEC> フラグをセットするための "
6096 "B<fcntl>(2)  B<F_SETFD> 操作を別途呼び出す必要がなくなる。 また、ある種のマル"
6097 "チスレッドのプログラムはこのフラグの使用は 不可欠である。なぜなら、個別に "
6098 "B<FD_CLOEXEC> フラグを設定する B<fcntl>(2)  B<F_SETFD> 操作を呼び出したとして"
6099 "も、あるスレッドがファイルディスクリプタを オープンするのと同時に別のスレッド"
6100 "が B<fork>(2)  と B<execve>(2)  を実行するという競合条件を避けるのには十分で"
6101 "はないからである。"
6102
6103 #. type: TP
6104 #: build/C/man2/open.2:208
6105 #, no-wrap
6106 msgid "B<O_CREAT>"
6107 msgstr "B<O_CREAT>"
6108
6109 #.  As at 2.6.25, bsdgroups is supported by ext2, ext3, ext4, and
6110 #.  XFS (since 2.6.14).
6111 #. type: Plain text
6112 #: build/C/man2/open.2:224
6113 msgid ""
6114 "If the file does not exist it will be created.  The owner (user ID) of the "
6115 "file is set to the effective user ID of the process.  The group ownership "
6116 "(group ID) is set either to the effective group ID of the process or to the "
6117 "group ID of the parent directory (depending on file system type and mount "
6118 "options, and the mode of the parent directory, see the mount options "
6119 "I<bsdgroups> and I<sysvgroups> described in B<mount>(8))."
6120 msgstr ""
6121 "ファイルが存在しなかった場合は作成 (create) する。 ファイルの所有者 (ユー"
6122 "ザー ID) は、プロセスの実効ユーザー ID に設定される。 グループ所有権 (グルー"
6123 "プ ID) は、プロセスの実効グループ ID または親ディレクトリのグループ ID に設定"
6124 "される (これは、ファイルシステムタイプ、マウントオプション、 親ディレクトリの"
6125 "モードに依存する。 B<mount>(8)  で説明されているマウントオプション "
6126 "I<bsdgroups> と I<sysvgroups> を参照)。"
6127
6128 #. type: Plain text
6129 #: build/C/man2/open.2:247
6130 msgid ""
6131 "I<mode> specifies the permissions to use in case a new file is created.  "
6132 "This argument must be supplied when B<O_CREAT> is specified in I<flags>; if "
6133 "B<O_CREAT> is not specified, then I<mode> is ignored.  The effective "
6134 "permissions are modified by the process's I<umask> in the usual way: The "
6135 "permissions of the created file are I<(mode\\ &\\ ~umask)>.  Note that this "
6136 "mode applies only to future accesses of the newly created file; the B<open>"
6137 "()  call that creates a read-only file may well return a read/write file "
6138 "descriptor."
6139 msgstr ""
6140 "I<mode> は新しいファイルを作成する場合に使用するアクセス許可 (permission) を"
6141 "指定する。 I<flags> に B<O_CREAT> が指定されている場合、 I<mode> を指定しなけ"
6142 "ればならない。 B<O_CREAT> が指定されていない場合、 I<mode> は無視される。 有"
6143 "効なアクセス許可は、普段と同じようにプロセスの I<umask> によって修正され、作"
6144 "成されたファイルの許可は I<(mode\\ &\\ ~umask)> となる。 このモードは、新しく"
6145 "作成されたファイルに対するそれ以降のアクセス にのみ適用される点に注意するこ"
6146 "と。 読み取り専用のファイルを作成する B<open>()  コールであっても、 読み書き"
6147 "可能なファイルディスクリプタを返すことがありうる。"
6148
6149 #. type: Plain text
6150 #: build/C/man2/open.2:250
6151 msgid "The following symbolic constants are provided for I<mode>:"
6152 msgstr "I<mode> のために以下のシンボル定数が提供されている :"
6153
6154 #. type: TP
6155 #: build/C/man2/open.2:250
6156 #, no-wrap
6157 msgid "B<S_IRWXU>"
6158 msgstr "B<S_IRWXU>"
6159
6160 #. type: Plain text
6161 #: build/C/man2/open.2:253
6162 msgid "00700 user (file owner) has read, write and execute permission"
6163 msgstr ""
6164 "00700 ユーザー (ファイルの所有者) に読み込み、書き込み、 実行の許可がある。"
6165
6166 #. type: TP
6167 #: build/C/man2/open.2:253
6168 #, no-wrap
6169 msgid "B<S_IRUSR>"
6170 msgstr "B<S_IRUSR>"
6171
6172 #. type: Plain text
6173 #: build/C/man2/open.2:256
6174 msgid "00400 user has read permission"
6175 msgstr "00400 ユーザーに読み込みの許可がある。"
6176
6177 #. type: TP
6178 #: build/C/man2/open.2:256
6179 #, no-wrap
6180 msgid "B<S_IWUSR>"
6181 msgstr "B<S_IWUSR>"
6182
6183 #. type: Plain text
6184 #: build/C/man2/open.2:259
6185 msgid "00200 user has write permission"
6186 msgstr "00200 ユーザーに書き込みの許可がある。"
6187
6188 #. type: TP
6189 #: build/C/man2/open.2:259
6190 #, no-wrap
6191 msgid "B<S_IXUSR>"
6192 msgstr "B<S_IXUSR>"
6193
6194 #. type: Plain text
6195 #: build/C/man2/open.2:262
6196 msgid "00100 user has execute permission"
6197 msgstr "00100 ユーザーに実行の許可がある。"
6198
6199 #. type: TP
6200 #: build/C/man2/open.2:262
6201 #, no-wrap
6202 msgid "B<S_IRWXG>"
6203 msgstr "B<S_IRWXG>"
6204
6205 #. type: Plain text
6206 #: build/C/man2/open.2:265
6207 msgid "00070 group has read, write and execute permission"
6208 msgstr "00070 グループに読み込み、書き込み、実行の許可がある。"
6209
6210 #. type: TP
6211 #: build/C/man2/open.2:265
6212 #, no-wrap
6213 msgid "B<S_IRGRP>"
6214 msgstr "B<S_IRGRP>"
6215
6216 #. type: Plain text
6217 #: build/C/man2/open.2:268
6218 msgid "00040 group has read permission"
6219 msgstr "00040 グループに読み込みの許可がある。"
6220
6221 #. type: TP
6222 #: build/C/man2/open.2:268
6223 #, no-wrap
6224 msgid "B<S_IWGRP>"
6225 msgstr "B<S_IWGRP>"
6226
6227 #. type: Plain text
6228 #: build/C/man2/open.2:271
6229 msgid "00020 group has write permission"
6230 msgstr "00020 グループに書き込みの許可がある。"
6231
6232 #. type: TP
6233 #: build/C/man2/open.2:271
6234 #, no-wrap
6235 msgid "B<S_IXGRP>"
6236 msgstr "B<S_IXGRP>"
6237
6238 #. type: Plain text
6239 #: build/C/man2/open.2:274
6240 msgid "00010 group has execute permission"
6241 msgstr "00010 グループに実行の許可がある。"
6242
6243 #. type: TP
6244 #: build/C/man2/open.2:274
6245 #, no-wrap
6246 msgid "B<S_IRWXO>"
6247 msgstr "B<S_IRWXO>"
6248
6249 #. type: Plain text
6250 #: build/C/man2/open.2:277
6251 msgid "00007 others have read, write and execute permission"
6252 msgstr "00007 他人 (others) に読み込み、書き込み、実行の許可がある。"
6253
6254 #. type: TP
6255 #: build/C/man2/open.2:277
6256 #, no-wrap
6257 msgid "B<S_IROTH>"
6258 msgstr "B<S_IROTH>"
6259
6260 #. type: Plain text
6261 #: build/C/man2/open.2:280
6262 msgid "00004 others have read permission"
6263 msgstr "00004 他人に読み込みの許可がある。"
6264
6265 #. type: TP
6266 #: build/C/man2/open.2:280
6267 #, no-wrap
6268 msgid "B<S_IWOTH>"
6269 msgstr "B<S_IWOTH>"
6270
6271 #. type: Plain text
6272 #: build/C/man2/open.2:283
6273 msgid "00002 others have write permission"
6274 msgstr "00002 他人に書き込みの許可がある。"
6275
6276 #. type: TP
6277 #: build/C/man2/open.2:283
6278 #, no-wrap
6279 msgid "B<S_IXOTH>"
6280 msgstr "B<S_IXOTH>"
6281
6282 #. type: Plain text
6283 #: build/C/man2/open.2:286
6284 msgid "00001 others have execute permission"
6285 msgstr "00001 他人に実行の許可がある。"
6286
6287 #. type: TP
6288 #: build/C/man2/open.2:287
6289 #, no-wrap
6290 msgid "B<O_DIRECT> (Since Linux 2.4.10)"
6291 msgstr "B<O_DIRECT> (Linux 2.4.10 以降)"
6292
6293 #. type: Plain text
6294 #: build/C/man2/open.2:304
6295 msgid ""
6296 "Try to minimize cache effects of the I/O to and from this file.  In general "
6297 "this will degrade performance, but it is useful in special situations, such "
6298 "as when applications do their own caching.  File I/O is done directly to/"
6299 "from user-space buffers.  The B<O_DIRECT> flag on its own makes an effort to "
6300 "transfer data synchronously, but does not give the guarantees of the "
6301 "B<O_SYNC> flag that data and necessary metadata are transferred.  To "
6302 "guarantee synchronous I/O, B<O_SYNC> must be used in addition to "
6303 "B<O_DIRECT>.  See NOTES below for further discussion."
6304 msgstr ""
6305 "このファイルに対する I/O のキャッシュの効果を最小化しようとする。このフラグを"
6306 "使うと、一般的に性能が低下する。 しかしアプリケーションが独自にキャッシングを"
6307 "行っているような 特別な場合には役に立つ。 ファイルの I/O はユーザー空間バッ"
6308 "ファに対して直接行われる。 B<O_DIRECT> フラグ自身はデータを同期で転送しようと"
6309 "はするが、 B<O_SYNC> フラグのようにデータと必要なメタデータの転送が保証される"
6310 "わけではない。同期 I/O を保証するためには、 B<O_DIRECT> に加えて B<O_SYNC> を"
6311 "使用しなければならない。下記の「注意」の節の議論も参照。"
6312
6313 #. type: Plain text
6314 #: build/C/man2/open.2:308
6315 msgid ""
6316 "A semantically similar (but deprecated) interface for block devices is "
6317 "described in B<raw>(8)."
6318 msgstr ""
6319 "ブロックデバイスに対する似通った意味のインターフェースが B<raw>(8)  で説明さ"
6320 "れている (但し、このインタフェースは非推奨である)。"
6321
6322 #. type: TP
6323 #: build/C/man2/open.2:308
6324 #, no-wrap
6325 msgid "B<O_DIRECTORY>"
6326 msgstr "B<O_DIRECTORY>"
6327
6328 #.  But see the following and its replies:
6329 #.  http://marc.theaimsgroup.com/?t=112748702800001&r=1&w=2
6330 #.  [PATCH] open: O_DIRECTORY and O_CREAT together should fail
6331 #.  O_DIRECTORY | O_CREAT causes O_DIRECTORY to be ignored.
6332 #. type: Plain text
6333 #: build/C/man2/open.2:322
6334 msgid ""
6335 "If I<pathname> is not a directory, cause the open to fail.  This flag is "
6336 "Linux-specific, and was added in kernel version 2.1.126, to avoid denial-of-"
6337 "service problems if B<opendir>(3)  is called on a FIFO or tape device, but "
6338 "should not be used outside of the implementation of B<opendir>(3)."
6339 msgstr ""
6340 "I<pathname> がディレクトリでなければオープンは失敗する。 このフラグは Linux "
6341 "特有であり、 B<opendir>(3)  が FIFO やテープデバイスに対してコールされた場合"
6342 "の サービス不能 (denial-of-service) 攻撃を避けるために カーネル 2.1.126 で追"
6343 "加された。 しかしこれは B<opendir>(3)  の実装以外では使用するべきではない。"
6344
6345 #. type: TP
6346 #: build/C/man2/open.2:322
6347 #, no-wrap
6348 msgid "B<O_EXCL>"
6349 msgstr "B<O_EXCL>"
6350
6351 #. type: Plain text
6352 #: build/C/man2/open.2:332
6353 msgid ""
6354 "Ensure that this call creates the file: if this flag is specified in "
6355 "conjunction with B<O_CREAT>, and I<pathname> already exists, then B<open>()  "
6356 "will fail."
6357 msgstr ""
6358 "この呼び出しでファイルが作成されることを保証する。このフラグが B<O_CREAT> "
6359 "と\n"
6360 "一緒に指定され、 I<pathname> のファイルが既に存在した場合、 B<open>() は失"
6361 "敗\n"
6362 "する。"
6363
6364 #.  POSIX.1-2001 explicitly requires this behavior.
6365 #. type: Plain text
6366 #: build/C/man2/open.2:340
6367 msgid ""
6368 "When these two flags are specified, symbolic links are not followed: if "
6369 "I<pathname> is a symbolic link, then B<open>()  fails regardless of where "
6370 "the symbolic link points to."
6371 msgstr ""
6372 "これら二つのフラグが指定された際、シンボリックリンクは辿られない。 "
6373 "I<pathname> がシンボリックリンクの場合、 シンボリックリンクがどこを指している"
6374 "かに関わらず B<open>()  は失敗する。"
6375
6376 #. type: Plain text
6377 #: build/C/man2/open.2:356
6378 msgid ""
6379 "In general, the behavior of B<O_EXCL> is undefined if it is used without "
6380 "B<O_CREAT>.  There is one exception: on Linux 2.6 and later, B<O_EXCL> can "
6381 "be used without B<O_CREAT> if I<pathname> refers to a block device.  If the "
6382 "block device is in use by the system (e.g., mounted), B<open>()  fails with "
6383 "the error B<EBUSY>."
6384 msgstr ""
6385 "一般的には、 B<O_CREAT> を指定せずに B<O_EXCL> を使用した場合の\n"
6386 "B<O_EXCL> の動作は規定されていない。\n"
6387 "これには一つ例外があり、Linux 2.6 以降では、\n"
6388 "I<pathname> がブロックデバイスを参照している場合、\n"
6389 "B<O_CREAT> なしで B<O_EXCL> を使用することができる。\n"
6390 "システムがそのブロックデバイスを使用中の場合 (例えば、\n"
6391 "マウントされているなど)、 B<open>() はエラー B<EBUSY> で失敗する。"
6392
6393 #. type: Plain text
6394 #: build/C/man2/open.2:378
6395 msgid ""
6396 "On NFS, B<O_EXCL> is supported only when using NFSv3 or later on kernel 2.6 "
6397 "or later.  In NFS environments where B<O_EXCL> support is not provided, "
6398 "programs that rely on it for performing locking tasks will contain a race "
6399 "condition.  Portable programs that want to perform atomic file locking using "
6400 "a lockfile, and need to avoid reliance on NFS support for B<O_EXCL>, can "
6401 "create a unique file on the same file system (e.g., incorporating hostname "
6402 "and PID), and use B<link>(2)  to make a link to the lockfile.  If B<link>"
6403 "(2)  returns 0, the lock is successful.  Otherwise, use B<stat>(2)  on the "
6404 "unique file to check if its link count has increased to 2, in which case the "
6405 "lock is also successful."
6406 msgstr ""
6407 "NFS では、 B<O_EXCL> は、Linux 2.6 以降で NFSv3 以降を使っている場合でのみサ"
6408 "ポートされる。 B<O_EXCL> サポートが提供されていない NFS 環境では、このフラグ"
6409 "に頼って ロック処理を実行するプログラムは競合状態 (race condition) に出会う "
6410 "可能性がある。 ロックファイルを使用して不可分 (atomic) なファイルロックを実現"
6411 "し、 NFS が B<O_EXCL> をサポートしているかに依存しないようにしたい場合、 移植"
6412 "性のある方法は、同じファイルシステム上に他と名前の重ならない ファイル (例えば"
6413 "ホスト名と PID を組み合わせた名前) を作成し、 B<link>(2)  を使用してそのロッ"
6414 "クファイルへのリンクを作成することである。 B<link>(2)  コールの返り値が 0 な"
6415 "らばロックに成功している。 あるいは、そのファイルに B<stat>(2)  を使用してリ"
6416 "ンク数 (link count) が 2 になっているかをチェックする。 そうなっていれば、同"
6417 "じくロックに成功しているということである。"
6418
6419 #. type: TP
6420 #: build/C/man2/open.2:378
6421 #, no-wrap
6422 msgid "B<O_LARGEFILE>"
6423 msgstr "B<O_LARGEFILE>"
6424
6425 #. type: Plain text
6426 #: build/C/man2/open.2:400
6427 msgid ""
6428 "(LFS)  Allow files whose sizes cannot be represented in an I<off_t> (but can "
6429 "be represented in an I<off64_t>)  to be opened.  The B<_LARGEFILE64_SOURCE> "
6430 "macro must be defined (before including I<any> header files)  in order to "
6431 "obtain this definition.  Setting the B<_FILE_OFFSET_BITS> feature test macro "
6432 "to 64 (rather than using B<O_LARGEFILE>)  is the preferred method of "
6433 "accessing large files on 32-bit systems (see B<feature_test_macros>(7))."
6434 msgstr ""
6435 "(LFS) I<off_t> ではサイズを表せない (だだし I<off64_t> ではサイズを表せる)"
6436 "ファ\n"
6437 "イルをオープン可能にする。この定義を有効にするためには、(I<どの>ヘッダファ"
6438 "イ\n"
6439 "ルをインクルードするよりも前に) B<_LARGEFILE64_SOURCE> マクロを定義しなけれ"
6440 "ば\n"
6441 "ならない。\n"
6442 "32 ビットシステムにおいて大きなファイルにアクセスしたい場合、\n"
6443 "(B<O_LARGEFILE> を使うよりも) B<_FILE_OFFSET_BITS> 機能検査マクロを 64 に\n"
6444 "セットする方が望ましい方法である (B<feature_test_macros>(7) を参照)。"
6445
6446 #. type: TP
6447 #: build/C/man2/open.2:400
6448 #, no-wrap
6449 msgid "B<O_NOATIME> (Since Linux 2.6.8)"
6450 msgstr "B<O_NOATIME> (Linux 2.6.8 以降)"
6451
6452 #.  The O_NOATIME flag also affects the treatment of st_atime
6453 #.  by mmap() and readdir(2), MTK, Dec 04.
6454 #. type: Plain text
6455 #: build/C/man2/open.2:413
6456 msgid ""
6457 "Do not update the file last access time (I<st_atime> in the inode)  when the "
6458 "file is B<read>(2).  This flag is intended for use by indexing or backup "
6459 "programs, where its use can significantly reduce the amount of disk "
6460 "activity.  This flag may not be effective on all file systems.  One example "
6461 "is NFS, where the server maintains the access time."
6462 msgstr ""
6463 "ファイルに対して B<read>(2)  が実行されたときに、最終アクセス時刻 (inode の "
6464 "I<st_atime>) を更新しない。 このフラグはインデックス作成やバックアッププログ"
6465 "ラムで使うことを意図している。 これを使うとディスクに対する操作を大幅に減らす"
6466 "ことができる。 このフラグは全てのファイルシステムに対して有効であるわけではな"
6467 "い。 その一例が NFS であり、サーバがアクセス時刻を管理している。"
6468
6469 #. type: TP
6470 #: build/C/man2/open.2:413
6471 #, no-wrap
6472 msgid "B<O_NOCTTY>"
6473 msgstr "B<O_NOCTTY>"
6474
6475 #. type: Plain text
6476 #: build/C/man2/open.2:421
6477 msgid ""
6478 "If I<pathname> refers to a terminal device\\(emsee B<tty>(4)\\(emit will not "
6479 "become the process's controlling terminal even if the process does not have "
6480 "one."
6481 msgstr ""
6482 "I<pathname> が端末 (terminal) デバイス \\(em B<tty>(4) 参照 \\(em を指してい"
6483 "る\n"
6484 "場合に、たとえそのプロセスが制御端末を持っていなくても、オープンしたファイ"
6485 "ル\n"
6486 "は制御端末にはならない。"
6487
6488 #. type: TP
6489 #: build/C/man2/open.2:421
6490 #, no-wrap
6491 msgid "B<O_NOFOLLOW>"
6492 msgstr "B<O_NOFOLLOW>"
6493
6494 #.  The headers from glibc 2.0.100 and later include a
6495 #.  definition of this flag; \fIkernels before 2.1.126 will ignore it if
6496 #.  used\fP.
6497 #. type: Plain text
6498 #: build/C/man2/open.2:430
6499 msgid ""
6500 "If I<pathname> is a symbolic link, then the open fails.  This is a FreeBSD "
6501 "extension, which was added to Linux in version 2.1.126.  Symbolic links in "
6502 "earlier components of the pathname will still be followed."
6503 msgstr ""
6504 "I<pathname> がシンボリックリンクだった場合、オープンは失敗する。 これは "
6505 "FreeBSD の拡張で、Linux には 2.1.126 より追加された。 pathname の前のコンポー"
6506 "ネント (earlier component; 訳註: 最後のディレクトリセパレータより前の部分) "
6507 "が シンボリックリンクである場合には、それが指す先が参照される。"
6508
6509 #. type: TP
6510 #: build/C/man2/open.2:430
6511 #, no-wrap
6512 msgid "B<O_NONBLOCK> or B<O_NDELAY>"
6513 msgstr "B<O_NONBLOCK> または B<O_NDELAY>"
6514
6515 #. type: Plain text
6516 #: build/C/man2/open.2:443
6517 msgid ""
6518 "When possible, the file is opened in nonblocking mode.  Neither the B<open>"
6519 "()  nor any subsequent operations on the file descriptor which is returned "
6520 "will cause the calling process to wait.  For the handling of FIFOs (named "
6521 "pipes), see also B<fifo>(7).  For a discussion of the effect of "
6522 "B<O_NONBLOCK> in conjunction with mandatory file locks and with file leases, "
6523 "see B<fcntl>(2)."
6524 msgstr ""
6525 "可能ならば、ファイルは非停止 (nonblocking) モードでオープンされる。\n"
6526 "B<open>() も、返したファイルディスクリプタに対する以後のすべての操作も呼び"
6527 "出\n"
6528 "したプロセスを待たせることはない。 FIFO (名前付きパイプ) を扱う場合には\n"
6529 "B<fifo>(7) も参照すること。 強制ファイルロック (mandatory file lock) やファ"
6530 "イ\n"
6531 "ルリース (file lease) と組み合わせた場合の、 B<O_NONBLOCK> の効果についての\n"
6532 "議論は、 B<fcntl>(2) を参照すること。"
6533
6534 #. type: TP
6535 #: build/C/man2/open.2:443
6536 #, no-wrap
6537 msgid "B<O_SYNC>"
6538 msgstr "B<O_SYNC>"
6539
6540 #. type: Plain text
6541 #: build/C/man2/open.2:451
6542 msgid ""
6543 "The file is opened for synchronous I/O.  Any B<write>(2)s on the resulting "
6544 "file descriptor will block the calling process until the data has been "
6545 "physically written to the underlying hardware.  I<But see NOTES below>."
6546 msgstr ""
6547 "ファイルは同期 (synchronous) I/O モードでオープンされる。 B<open>()  が返した"
6548 "ファイルディスクリプタに対して B<write>(2)  を行うと、必ず呼び出したプロセス"
6549 "をブロックし、 該当ハードウェアに物理的に書き込まれるまで返らない。 I<以下の"
6550 "「注意」の章も参照。>"
6551
6552 #. type: TP
6553 #: build/C/man2/open.2:451
6554 #, no-wrap
6555 msgid "B<O_TRUNC>"
6556 msgstr "B<O_TRUNC>"
6557
6558 #. type: Plain text
6559 #: build/C/man2/open.2:465
6560 msgid ""
6561 "If the file already exists and is a regular file and the open mode allows "
6562 "writing (i.e., is B<O_RDWR> or B<O_WRONLY>)  it will be truncated to length "
6563 "0.  If the file is a FIFO or terminal device file, the B<O_TRUNC> flag is "
6564 "ignored.  Otherwise the effect of B<O_TRUNC> is unspecified."
6565 msgstr ""
6566 "ファイルが既に存在し、通常ファイルであり、 書き込み可モードでオープンされてい"
6567 "る (つまり、 B<O_RDWR>またはB<O_WRONLY> の) 場合、長さ 0 に切り詰め "
6568 "(truncate) られる。 ファイルが FIFO または端末デバイスファイルの場合、 "
6569 "B<O_TRUNC> フラグは無視される。 それ以外の場合、 B<O_TRUNC> の効果は未定義で"
6570 "ある。"
6571
6572 #. type: Plain text
6573 #: build/C/man2/open.2:469
6574 msgid ""
6575 "Some of these optional flags can be altered using B<fcntl>(2)  after the "
6576 "file has been opened."
6577 msgstr ""
6578 "これらの選択フラグのいくつかはファイルをオープンした後でも B<fcntl>(2)  を使"
6579 "用して変更することができる。"
6580
6581 #. type: Plain text
6582 #: build/C/man2/open.2:477
6583 msgid ""
6584 "B<creat>()  is equivalent to B<open>()  with I<flags> equal to B<O_CREAT|"
6585 "O_WRONLY|O_TRUNC>."
6586 msgstr ""
6587 "B<creat>()  は I<flags> に B<O_CREAT|O_WRONLY|O_TRUNC> を指定して B<open>()  "
6588 "を行うのと等価である。"
6589
6590 #. type: Plain text
6591 #: build/C/man2/open.2:485
6592 msgid ""
6593 "B<open>()  and B<creat>()  return the new file descriptor, or -1 if an error "
6594 "occurred (in which case, I<errno> is set appropriately)."
6595 msgstr ""
6596 "B<open>()  と B<creat>()  は新しいファイルディスクリプタを返す。 エラーが発生"
6597 "した場合は -1 を返す (その場合は I<errno> が適切に設定される)。"
6598
6599 #. type: Plain text
6600 #: build/C/man2/open.2:495
6601 msgid ""
6602 "The requested access to the file is not allowed, or search permission is "
6603 "denied for one of the directories in the path prefix of I<pathname>, or the "
6604 "file did not exist yet and write access to the parent directory is not "
6605 "allowed.  (See also B<path_resolution>(7).)"
6606 msgstr ""
6607 "ファイルに対する要求されたアクセスが許されていないか、 I<pathname> のディレク"
6608 "トリ部分の何れかのディレクトリに検索許可がなかった。 またはファイルが存在せ"
6609 "ず、親ディレクトリへの書き込み許可がなかった。 (B<path_resolution>(7)  も参照"
6610 "すること。)"
6611
6612 #. type: Plain text
6613 #: build/C/man2/open.2:501
6614 msgid ""
6615 "Where B<O_CREAT> is specified, the file does not exist, and the user's quota "
6616 "of disk blocks or inodes on the file system has been exhausted."
6617 msgstr ""
6618 "B<O_CREAT> が指定された場合で、そのファイルが存在せず、ディスクブロックか "
6619 "inode がそのファイルシステムのユーザクォータに達していた。"
6620
6621 #. type: Plain text
6622 #: build/C/man2/open.2:507
6623 msgid "I<pathname> already exists and B<O_CREAT> and B<O_EXCL> were used."
6624 msgstr "I<pathname> は既に存在し、 B<O_CREAT> と B<O_EXCL> が使用された。"
6625
6626 #. type: Plain text
6627 #: build/C/man2/open.2:511 build/C/man2/rmdir.2:67 build/C/man2/unlink.2:84
6628 msgid "I<pathname> points outside your accessible address space."
6629 msgstr "I<pathname> がアクセス可能なアドレス空間の外を指している。"
6630
6631 #. type: TP
6632 #: build/C/man2/open.2:511 build/C/man2/write.2:145
6633 #, no-wrap
6634 msgid "B<EFBIG>"
6635 msgstr "B<EFBIG>"
6636
6637 #. type: Plain text
6638 #: build/C/man2/open.2:515
6639 msgid "See B<EOVERFLOW>."
6640 msgstr "B<EOVERFLOW> 参照。"
6641
6642 #. type: TP
6643 #: build/C/man2/open.2:515 build/C/man2/read.2:122 build/C/man3/scanf.3:561
6644 #: build/C/man3/tmpfile.3:63 build/C/man2/write.2:150
6645 #, no-wrap
6646 msgid "B<EINTR>"
6647 msgstr "B<EINTR>"
6648
6649 #. type: Plain text
6650 #: build/C/man2/open.2:522
6651 msgid ""
6652 "While blocked waiting to complete an open of a slow device (e.g., a FIFO; "
6653 "see B<fifo>(7)), the call was interrupted by a signal handler; see B<signal>"
6654 "(7)."
6655 msgstr ""
6656 "遅いデバイス (例えば FIFO、 B<fifo>(7)  参照) のオープンが完了するのを待って"
6657 "停止している間に システムコールがシグナルハンドラにより割り込まれた。 "
6658 "B<signal>(7)  参照。"
6659
6660 #. type: TP
6661 #: build/C/man2/open.2:522 build/C/man2/read.2:158 build/C/man2/rename.2:143
6662 #: build/C/man2/unlink.2:87
6663 #, no-wrap
6664 msgid "B<EISDIR>"
6665 msgstr "B<EISDIR>"
6666
6667 #. type: Plain text
6668 #: build/C/man2/open.2:531
6669 msgid ""
6670 "I<pathname> refers to a directory and the access requested involved writing "
6671 "(that is, B<O_WRONLY> or B<O_RDWR> is set)."
6672 msgstr ""
6673 "I<pathname> はディレクトリを参照しており、書き込み要求が含まれていた (つまり "
6674 "B<O_WRONLY> または B<O_RDWR> が設定されている)。"
6675
6676 #. type: Plain text
6677 #: build/C/man2/open.2:538
6678 msgid ""
6679 "Too many symbolic links were encountered in resolving I<pathname>, or "
6680 "B<O_NOFOLLOW> was specified but I<pathname> was a symbolic link."
6681 msgstr ""
6682 "I<pathname> を解決する際に遭遇したシンボリックリンクが多過ぎる。 または "
6683 "B<O_NOFOLLOW> が指定されており、 I<pathname> がシンボリックリンクだった。"
6684
6685 #. type: TP
6686 #: build/C/man2/open.2:538 build/C/man2/pipe.2:107 build/C/man3/tmpfile.3:66
6687 #, no-wrap
6688 msgid "B<EMFILE>"
6689 msgstr "B<EMFILE>"
6690
6691 #. type: Plain text
6692 #: build/C/man2/open.2:541
6693 msgid "The process already has the maximum number of files open."
6694 msgstr "プロセスがオープンしているファイル数がすでに最大数に達している。"
6695
6696 #. type: Plain text
6697 #: build/C/man2/open.2:545 build/C/man2/rmdir.2:80 build/C/man2/unlink.2:99
6698 msgid "I<pathname> was too long."
6699 msgstr "I<pathname> が長過ぎる。"
6700
6701 #. type: TP
6702 #: build/C/man2/open.2:545 build/C/man2/pipe.2:110 build/C/man3/tmpfile.3:69
6703 #, no-wrap
6704 msgid "B<ENFILE>"
6705 msgstr "B<ENFILE>"
6706
6707 #. type: Plain text
6708 #: build/C/man2/open.2:548 build/C/man2/pipe.2:113
6709 msgid "The system limit on the total number of open files has been reached."
6710 msgstr "オープンされているファイルの総数がシステムの制限に達している。"
6711
6712 #. type: TP
6713 #: build/C/man2/open.2:548
6714 #, no-wrap
6715 msgid "B<ENODEV>"
6716 msgstr "B<ENODEV>"
6717
6718 #. type: Plain text
6719 #: build/C/man2/open.2:555
6720 msgid ""
6721 "I<pathname> refers to a device special file and no corresponding device "
6722 "exists.  (This is a Linux kernel bug; in this situation B<ENXIO> must be "
6723 "returned.)"
6724 msgstr ""
6725 "I<pathname> がデバイススペシャルファイルを参照しており、対応するデバイスが存"
6726 "在しない。 (これは Linux カーネルのバグであり、この場合には B<ENXIO> が返され"
6727 "るべきである)"
6728
6729 #. type: Plain text
6730 #: build/C/man2/open.2:562
6731 msgid ""
6732 "B<O_CREAT> is not set and the named file does not exist.  Or, a directory "
6733 "component in I<pathname> does not exist or is a dangling symbolic link."
6734 msgstr ""
6735 "B<O_CREAT> が設定されておらず、かつ指定されたファイルが存在しない。 または、 "
6736 "I<pathname> のディレクトリ部分が存在しないか壊れた (dangling) シンボリックリ"
6737 "ンクである。"
6738
6739 #. type: Plain text
6740 #: build/C/man2/open.2:571
6741 msgid ""
6742 "I<pathname> was to be created but the device containing I<pathname> has no "
6743 "room for the new file."
6744 msgstr ""
6745 "I<pathname> を作成する必要があるが、 I<pathname> を含んでいるデバイスに新しい"
6746 "ファイルのための空き容量がない。"
6747
6748 #. type: Plain text
6749 #: build/C/man2/open.2:578
6750 msgid ""
6751 "A component used as a directory in I<pathname> is not, in fact, a directory, "
6752 "or B<O_DIRECTORY> was specified and I<pathname> was not a directory."
6753 msgstr ""
6754 "I<pathname> に含まれるディレクトリ部分のどれかが実際にはディレクトリでない。 "
6755 "または B<O_DIRECTORY> が指定されており、 I<pathname> がディレクトリでない。"
6756
6757 #. type: Plain text
6758 #: build/C/man2/open.2:584
6759 msgid ""
6760 "B<O_NONBLOCK> | B<O_WRONLY> is set, the named file is a FIFO and no process "
6761 "has the file open for reading.  Or, the file is a device special file and no "
6762 "corresponding device exists."
6763 msgstr ""
6764 "B<O_NONBLOCK> | B<O_WRONLY> が設定されており、指定したファイルが FIFO で その"
6765 "ファイルを読み込みのためにオープンしているプロセスが存在しない。 または、ファ"
6766 "イルがデバイススペシャルファイルで 対応するデバイスが存在しない。"
6767
6768 #.  See http://bugzilla.kernel.org/show_bug.cgi?id=7253
6769 #.  "Open of a large file on 32-bit fails with EFBIG, should be EOVERFLOW"
6770 #.  Reported 2006-10-03
6771 #. type: Plain text
6772 #: build/C/man2/open.2:604
6773 msgid ""
6774 "I<pathname> refers to a regular file that is too large to be opened.  The "
6775 "usual scenario here is that an application compiled on a 32-bit platform "
6776 "without I<-D_FILE_OFFSET_BITS=64> tried to open a file whose size exceeds I<"
6777 "(2E<lt>E<lt>31)-1> bits; see also B<O_LARGEFILE> above.  This is the error "
6778 "specified by POSIX.1-2001; in kernels before 2.6.24, Linux gave the error "
6779 "B<EFBIG> for this case."
6780 msgstr ""
6781 "I<pathname> が参照しているのが、大き過ぎてオープンできない通常のファイルであ"
6782 "る。 通常、このエラーが発生するは、32 ビットプラットフォーム上で I<-"
6783 "D_FILE_OFFSET_BITS=64> を指定せずにコンパイルされたアプリケーションが、ファイ"
6784 "ルサイズが I<(2E<lt>31)-1> ビットを超えるファイルを開こうとした場合である。 "
6785 "上記の B<O_LARGEFILE> も参照。 これは POSIX.1-2001 で規定されているエラーであ"
6786 "る。 2.6.24 より前のカーネルでは、Linux はこの場合にエラー B<EFBIG> を返して"
6787 "いた。"
6788
6789 #.  Strictly speaking, it's the file system UID... (MTK)
6790 #. type: Plain text
6791 #: build/C/man2/open.2:612
6792 msgid ""
6793 "The B<O_NOATIME> flag was specified, but the effective user ID of the caller "
6794 "did not match the owner of the file and the caller was not privileged "
6795 "(B<CAP_FOWNER>)."
6796 msgstr ""
6797 "B<O_NOATIME> フラグが指定されたが、呼び出し元の実効ユーザー ID が ファイルの"
6798 "所有者と一致せず、かつ呼び出し元に特権 (B<CAP_FOWNER>)  がない。"
6799
6800 #. type: Plain text
6801 #: build/C/man2/open.2:617
6802 msgid ""
6803 "I<pathname> refers to a file on a read-only file system and write access was "
6804 "requested."
6805 msgstr ""
6806 "I<pathname> が読み込み専用のファイルシステム上のファイルを参照しており、 書き"
6807 "込みアクセスが要求された。"
6808
6809 #. type: TP
6810 #: build/C/man2/open.2:617
6811 #, no-wrap
6812 msgid "B<ETXTBSY>"
6813 msgstr "B<ETXTBSY>"
6814
6815 #. type: Plain text
6816 #: build/C/man2/open.2:622
6817 msgid ""
6818 "I<pathname> refers to an executable image which is currently being executed "
6819 "and write access was requested."
6820 msgstr ""
6821 "I<pathname> が現在実行中の実行イメージを参照しており、書き込みが要求された。"
6822
6823 #. type: TP
6824 #: build/C/man2/open.2:622
6825 #, no-wrap
6826 msgid "B<EWOULDBLOCK>"
6827 msgstr "B<EWOULDBLOCK>"
6828
6829 #. type: Plain text
6830 #: build/C/man2/open.2:629
6831 msgid ""
6832 "The B<O_NONBLOCK> flag was specified, and an incompatible lease was held on "
6833 "the file (see B<fcntl>(2))."
6834 msgstr ""
6835 "B<O_NONBLOCK> フラグが指定されたが、そのファイルには矛盾するリースが設定され"
6836 "ていた (B<fcntl>(2)  参照)。"
6837
6838 #. type: Plain text
6839 #: build/C/man2/open.2:642
6840 msgid ""
6841 "SVr4, 4.3BSD, POSIX.1-2001.  The B<O_DIRECTORY>, B<O_NOATIME>, and "
6842 "B<O_NOFOLLOW> flags are Linux-specific, and one may need to define "
6843 "B<_GNU_SOURCE> (before including I<any> header files)  to obtain their "
6844 "definitions."
6845 msgstr ""
6846 "SVr4, 4.3BSD, POSIX.1-2001.  フラグ B<O_DIRECTORY>, B<O_NOATIME>, "
6847 "B<O_NOFOLLOW> は Linux 特有のものであり、 これらのフラグの定義を得るために"
6848 "は、 (「どの」ヘッダファイルをインクルードするよりも前に)  B<_GNU_SOURCE> を"
6849 "定義する必要があるかもしれない。"
6850
6851 #. type: Plain text
6852 #: build/C/man2/open.2:647
6853 msgid ""
6854 "The B<O_CLOEXEC> flag is not specified in POSIX.1-2001, but is specified in "
6855 "POSIX.1-2008."
6856 msgstr ""
6857 "B<O_CLOEXEC> フラグは POSIX.1-2001 では規定されていないが、 POSIX.1-2008 で規"
6858 "定されている。"
6859
6860 #. type: Plain text
6861 #: build/C/man2/open.2:655
6862 msgid ""
6863 "B<O_DIRECT> is not specified in POSIX; one has to define B<_GNU_SOURCE> "
6864 "(before including I<any> header files)  to get its definition."
6865 msgstr ""
6866 "B<O_DIRECT> は POSIX では規定されていない。 B<O_DIRECT> の定義を得るには "
6867 "(「どの」ヘッダファイルをインクルードするよりも前に)  B<_GNU_SOURCE> を定義し"
6868 "なければならない。"
6869
6870 #. type: Plain text
6871 #: build/C/man2/open.2:663
6872 msgid ""
6873 "Under Linux, the B<O_NONBLOCK> flag indicates that one wants to open but "
6874 "does not necessarily have the intention to read or write.  This is typically "
6875 "used to open devices in order to get a file descriptor for use with B<ioctl>"
6876 "(2)."
6877 msgstr ""
6878 "Linux では、 B<O_NONBLOCK> フラグは、 open を実行したいが read または write "
6879 "を実行する意図は 必ずしもないことを意味する。 これは B<ioctl>(2)  のための"
6880 "ファイルディスクリプタを取得するために、 デバイスをオープンするときによく用い"
6881 "られる。"
6882
6883 #.  See for example util-linux's disk-utils/setfdprm.c
6884 #.  For some background on access mode 3, see
6885 #.  http://thread.gmane.org/gmane.linux.kernel/653123
6886 #.  "[RFC] correct flags to f_mode conversion in __dentry_open"
6887 #.  LKML, 12 Mar 2008
6888 #. type: Plain text
6889 #: build/C/man2/open.2:692
6890 msgid ""
6891 "Unlike the other values that can be specified in I<flags>, the I<access "
6892 "mode> values B<O_RDONLY>, B<O_WRONLY>, and B<O_RDWR>, do not specify "
6893 "individual bits.  Rather, they define the low order two bits of I<flags>, "
6894 "and are defined respectively as 0, 1, and 2.  In other words, the "
6895 "combination B<O_RDONLY | O_WRONLY> is a logical error, and certainly does "
6896 "not have the same meaning as B<O_RDWR>.  Linux reserves the special, "
6897 "nonstandard access mode 3 (binary 11) in I<flags> to mean: check for read "
6898 "and write permission on the file and return a descriptor that can't be used "
6899 "for reading or writing.  This nonstandard access mode is used by some Linux "
6900 "drivers to return a descriptor that is to be used only for device-specific "
6901 "B<ioctl>(2)  operations."
6902 msgstr ""
6903 "「アクセスモード」の値 B<O_RDONLY>, B<O_WRONLY>, B<O_RDWR> は、 I<flags> に指"
6904 "定できる他の値と違い、個々のビットを指定するものではなく、 これらの値は "
6905 "I<flags> の下位 2 ビットを定義する。 B<O_RDONLY>, B<O_WRONLY>, B<O_RDWR> はそ"
6906 "れぞれ 0, 1, 2 に定義されている。 言い換えると、 B<O_RDONLY | O_WRONLY> の組"
6907 "み合わせは論理的に間違いであり、確かに B<O_RDWR> と同じ意味ではない。 Linux "
6908 "では、特別な、非標準なアクセスモードとして 3 (バイナリでは 11) が 予約されて"
6909 "おり I<flags> に指定できる。 このアクセスモードを指定すると、ファイルの読み出"
6910 "し/書き込み許可をチェックし、 読み出しにも書き込みにも使用できないディスクリ"
6911 "プタを返す。 この非標準のアクセスモードはいくつかの Linux ドライバで、デバイ"
6912 "ス固有の B<ioctl>(2) 操作にのみ使用されるディスクリプタを返すために使われてい"
6913 "る。"
6914
6915 #.  Linux 2.0, 2.5: truncate
6916 #.  Solaris 5.7, 5.8: truncate
6917 #.  Irix 6.5: truncate
6918 #.  Tru64 5.1B: truncate
6919 #.  HP-UX 11.22: truncate
6920 #.  FreeBSD 4.7: truncate
6921 #. type: Plain text
6922 #: build/C/man2/open.2:703
6923 msgid ""
6924 "The (undefined) effect of B<O_RDONLY | O_TRUNC> varies among "
6925 "implementations.  On many systems the file is actually truncated."
6926 msgstr ""
6927 "B<O_RDONLY | O_TRUNC> の影響は未定義であり、その動作は実装によって異なる。 多"
6928 "くのシステムではファイルは実際に切り詰められる。"
6929
6930 #. type: Plain text
6931 #: build/C/man2/open.2:707
6932 msgid ""
6933 "There are many infelicities in the protocol underlying NFS, affecting "
6934 "amongst others B<O_SYNC> and B<O_NDELAY>."
6935 msgstr ""
6936 "NFS を実現しているプロトコルには多くの不備があり、特に B<O_SYNC> と "
6937 "B<O_NDELAY> に影響する。"
6938
6939 #. type: Plain text
6940 #: build/C/man2/open.2:729
6941 msgid ""
6942 "POSIX provides for three different variants of synchronized I/O, "
6943 "corresponding to the flags B<O_SYNC>, B<O_DSYNC>, and B<O_RSYNC>.  Currently "
6944 "(2.6.31), Linux implements only B<O_SYNC>, but glibc maps B<O_DSYNC> and "
6945 "B<O_RSYNC> to the same numerical value as B<O_SYNC>.  Most Linux file "
6946 "systems don't actually implement the POSIX B<O_SYNC> semantics, which "
6947 "require all metadata updates of a write to be on disk on returning to user "
6948 "space, but only the B<O_DSYNC> semantics, which require only actual file "
6949 "data and metadata necessary to retrieve it to be on disk by the time the "
6950 "system call returns."
6951 msgstr ""
6952 "POSIX では、3 種類の同期 I/O が提供されており、 B<O_SYNC>, B<O_DSYNC>, "
6953 "B<O_RSYNC> フラグがこれに対応するものである。 今のところ (カーネル 2.6.31)、 "
6954 "Linux では B<O_SYNC> だけが実装されているが、 glibc は B<O_DSYNC> と "
6955 "B<O_RSYNC> に B<O_SYNC> と同じ数値を割り当てている。 ほとんどの Linux のファ"
6956 "イルシステムは、実際には POSIX の B<O_SYNC> の動作ではなく B<O_DSYNC> の動作"
6957 "だけを実装している。 POSIX の B<O_SYNC> では、 B<open>()  がユーザ空間に返る"
6958 "際に、書き込みに関する全てのメタデータの 更新がディスクに書き込まれている必要"
6959 "がある。 一方、 B<O_DSYNC> では、 B<open>()  が返るまでに、実際のファイルの"
6960 "データとそのデータを取得するために 必要なメタデータだけがディスクに書き込まれ"
6961 "ていればよい。"
6962
6963 #. type: Plain text
6964 #: build/C/man2/open.2:737
6965 msgid ""
6966 "Note that B<open>()  can open device special files, but B<creat>()  cannot "
6967 "create them; use B<mknod>(2)  instead."
6968 msgstr ""
6969 "B<open>()  はスペシャルファイルをオープンすることができるが、 B<creat>()  で"
6970 "スペシャルファイルを作成できない点に注意すること。 代わりに B<mknod>(2)  を使"
6971 "用する。"
6972
6973 #. type: Plain text
6974 #: build/C/man2/open.2:750
6975 msgid ""
6976 "On NFS file systems with UID mapping enabled, B<open>()  may return a file "
6977 "descriptor but, for example, B<read>(2)  requests are denied with "
6978 "B<EACCES>.  This is because the client performs B<open>()  by checking the "
6979 "permissions, but UID mapping is performed by the server upon read and write "
6980 "requests."
6981 msgstr ""
6982 "UID マッピングを使用している NFS ファイルシステムでは、 B<open>()  がファイル"
6983 "ディスクリプタを返した場合でも B<read>(2)  が B<EACCES> で拒否される場合があ"
6984 "る。 これはクライアントがアクセス許可のチェックを行って B<open>()  を実行する"
6985 "が、読み込みや書き込みの際には サーバーで UID マッピングが行われるためであ"
6986 "る。"
6987
6988 #. type: Plain text
6989 #: build/C/man2/open.2:769
6990 msgid ""
6991 "If the file is newly created, its I<st_atime>, I<st_ctime>, I<st_mtime> "
6992 "fields (respectively, time of last access, time of last status change, and "
6993 "time of last modification; see B<stat>(2))  are set to the current time, and "
6994 "so are the I<st_ctime> and I<st_mtime> fields of the parent directory.  "
6995 "Otherwise, if the file is modified because of the B<O_TRUNC> flag, its "
6996 "st_ctime and st_mtime fields are set to the current time."
6997 msgstr ""
6998 "ファイルが新しく作成されると、 ファイルの I<st_atime>, I<st_ctime>, "
6999 "I<st_mtime> フィールド (それぞれ最終アクセス時刻、最終状態変更時刻、最終修正"
7000 "時刻である。 B<stat>(2)  参照) が現在時刻に設定される。 さらに親ディレクトリ"
7001 "の I<st_ctime> と I<st_mtime> も現在時刻に設定される。 それ以外の場合で、"
7002 "O_TRUNC フラグでファイルが修正されたときは、 ファイルの I<st_ctime> と "
7003 "I<st_mtime> フィールドが現在時刻に設定される。"
7004
7005 #. type: SS
7006 #: build/C/man2/open.2:769
7007 #, no-wrap
7008 msgid "O_DIRECT"
7009 msgstr "O_DIRECT"
7010
7011 #. type: Plain text
7012 #: build/C/man2/open.2:786
7013 msgid ""
7014 "The B<O_DIRECT> flag may impose alignment restrictions on the length and "
7015 "address of user-space buffers and the file offset of I/Os.  In Linux "
7016 "alignment restrictions vary by file system and kernel version and might be "
7017 "absent entirely.  However there is currently no file system-independent "
7018 "interface for an application to discover these restrictions for a given file "
7019 "or file system.  Some file systems provide their own interfaces for doing "
7020 "so, for example the B<XFS_IOC_DIOINFO> operation in B<xfsctl>(3)."
7021 msgstr ""
7022 "B<O_DIRECT> フラグを使用する場合、ユーザ空間バッファの長さやアドレス、 I/O の"
7023 "ファイルオフセットに関してアラインメントの制限が課されることがある。 Linux で"
7024 "は、アラインメントの制限はファイルシステムやカーネルのバージョンに よって異な"
7025 "り、全く制限が存在しない場合もある。 しかしながら、現在のところ、指定された"
7026 "ファイルやファイルシステムに対して こうした制限があるかを見つけるための、アプ"
7027 "リケーション向けのインタフェースで ファイルシステム非依存のものは存在しな"
7028 "い。 いくつかのファイルシステムでは、制限を確認するための独自のインタフェース"
7029 "が 提供されている。例えば、 B<xfsctl>(3)  の B<XFS_IOC_DIOINFO> 命令である。"
7030
7031 #. type: Plain text
7032 #: build/C/man2/open.2:791
7033 msgid ""
7034 "Under Linux 2.4, transfer sizes, and the alignment of the user buffer and "
7035 "the file offset must all be multiples of the logical block size of the file "
7036 "system.  Under Linux 2.6, alignment to 512-byte boundaries suffices."
7037 msgstr ""
7038 "Linux 2.4 では、転送サイズ、 ユーザーバッファのアラインメント、ファイルオフ"
7039 "セットは、 ファイルシステムの論理ブロックサイズの倍数でなければならない。 "
7040 "Linux 2.6 では、512 バイトごとの境界に配置されていれば充分である。"
7041
7042 #. type: Plain text
7043 #: build/C/man2/open.2:825
7044 msgid ""
7045 "B<O_DIRECT> I/Os should never be run concurrently with the B<fork>(2)  "
7046 "system call, if the memory buffer is a private mapping (i.e., any mapping "
7047 "created with the B<mmap>(2)  B<MAP_PRIVATE> flag; this includes memory "
7048 "allocated on the heap and statically allocated buffers).  Any such I/Os, "
7049 "whether submitted via an asynchronous I/O interface or from another thread "
7050 "in the process, should be completed before B<fork>(2)  is called.  Failure "
7051 "to do so can result in data corruption and undefined behavior in parent and "
7052 "child processes.  This restriction does not apply when the memory buffer for "
7053 "the B<O_DIRECT> I/Os was created using B<shmat>(2)  or B<mmap>(2)  with the "
7054 "B<MAP_SHARED> flag.  Nor does this restriction apply when the memory buffer "
7055 "has been advised as B<MADV_DONTFORK> with B<madvise>(2), ensuring that it "
7056 "will not be available to the child after B<fork>(2)."
7057 msgstr ""
7058 "メモリバッファがプライベートマッピング (B<mmap>(2) の B<MAP_PRIVATE>\n"
7059 "フラグで作成されたマッピング) の場合には、B<O_DIRECT> I/O は\n"
7060 "B<fork>(2) システムコールと同時に決して実行すべきではない \n"
7061 "(プライベートマッピングには、ヒープ領域に割り当てられたメモリや静的に\n"
7062 "割り当てたバッファも含まれる)。非同期 I/O インターフェース (AIO) 経由\n"
7063 "やプロセス内の他のスレッドから発行された、このような I/O は、\n"
7064 "B<fork>(2) が呼び出される前に完了されるべきである。\n"
7065 "そうしなかった場合、データ破壊や、親プロセスや子プロセスでの予期しない\n"
7066 "動作が起こる可能性がある。\n"
7067 "B<O_DIRECT> I/O 用のメモリバッファが B<shmat>(2) やB<MAP_SHARED> フラグ\n"
7068 "付きの B<mmap>(2) で作成された場合には、この制限はあてはまらない。\n"
7069 "B<madvise>(2) でメモリバッファにアドバイス B<MADV_DONTFORK> が設定され\n"
7070 "ている場合にも、この制限はあてはまらない(B<MADV_DONTFORK> はそのメモリ\n"
7071 "バッファが B<fork>(2) 後に子プロセスからは利用できないことを保証するも\n"
7072 "のである)。"
7073
7074 #. type: Plain text
7075 #: build/C/man2/open.2:835
7076 msgid ""
7077 "The B<O_DIRECT> flag was introduced in SGI IRIX, where it has alignment "
7078 "restrictions similar to those of Linux 2.4.  IRIX has also a B<fcntl>(2)  "
7079 "call to query appropriate alignments, and sizes.  FreeBSD 4.x introduced a "
7080 "flag of the same name, but without alignment restrictions."
7081 msgstr ""
7082 "B<O_DIRECT> フラグは SGI IRIX で導入された。SGI IRIX にも Linux 2.4 と同様の "
7083 "(ユーザーバッファの) アラインメントの制限がある。 また、IRIX には適切な配置と"
7084 "サイズを取得するための B<fcntl>(2)  コールがある。 FreeBSD 4.x も同じ名前のフ"
7085 "ラグを導入したが、アラインメントの制限はない。"
7086
7087 #. type: Plain text
7088 #: build/C/man2/open.2:844
7089 msgid ""
7090 "B<O_DIRECT> support was added under Linux in kernel version 2.4.10.  Older "
7091 "Linux kernels simply ignore this flag.  Some file systems may not implement "
7092 "the flag and B<open>()  will fail with B<EINVAL> if it is used."
7093 msgstr ""
7094 "B<O_DIRECT> が Linux でサポートされたのは、カーネルバージョン 2.4.10 であ"
7095 "る。 古い Linux カーネルは、このフラグを単に無視する。 B<O_DIRECT> フラグをサ"
7096 "ポートしていないファイルシステムもあり、その場合は、 B<O_DIRECT> を使用する"
7097 "と B<open>()  は B<EINVAL> で失敗する。"
7098
7099 #. type: Plain text
7100 #: build/C/man2/open.2:855
7101 msgid ""
7102 "Applications should avoid mixing B<O_DIRECT> and normal I/O to the same "
7103 "file, and especially to overlapping byte regions in the same file.  Even "
7104 "when the file system correctly handles the coherency issues in this "
7105 "situation, overall I/O throughput is likely to be slower than using either "
7106 "mode alone.  Likewise, applications should avoid mixing B<mmap>(2)  of files "
7107 "with direct I/O to the same files."
7108 msgstr ""
7109 "アプリケーションは、同じファイル、 特に同じファイルの重複するバイト領域に対し"
7110 "て、 B<O_DIRECT> と通常の I/O を混ぜて使うのは避けるべきである。 ファイルシス"
7111 "テムがこのような状況において一貫性の問題を正しく 扱うことができる場合であって"
7112 "も、全体の I/O スループットは どちらか一方を使用するときと比べて低速になるで"
7113 "あろう。 同様に、アプリケーションは、同じファイルに対して B<mmap>(2)  と直接 "
7114 "I/O (B<O_DIRECT>)  を混ぜて使うのも避けるべきである。"
7115
7116 #. type: Plain text
7117 #: build/C/man2/open.2:877
7118 msgid ""
7119 "The behaviour of B<O_DIRECT> with NFS will differ from local file systems.  "
7120 "Older kernels, or kernels configured in certain ways, may not support this "
7121 "combination.  The NFS protocol does not support passing the flag to the "
7122 "server, so B<O_DIRECT> I/O will bypass the page cache only on the client; "
7123 "the server may still cache the I/O.  The client asks the server to make the "
7124 "I/O synchronous to preserve the synchronous semantics of B<O_DIRECT>.  Some "
7125 "servers will perform poorly under these circumstances, especially if the I/O "
7126 "size is small.  Some servers may also be configured to lie to clients about "
7127 "the I/O having reached stable storage; this will avoid the performance "
7128 "penalty at some risk to data integrity in the event of server power "
7129 "failure.  The Linux NFS client places no alignment restrictions on "
7130 "B<O_DIRECT> I/O."
7131 msgstr ""
7132 "NFS で B<O_DIRECT> を使った場合の動作はローカルのファイルシステムの場合と違"
7133 "う。 古いカーネルや、ある種の設定でコンパイルされたカーネルは、 B<O_DIRECT> "
7134 "と NFS の組み合わせをサポートしていないかもしれない。 NFS プロトコル自体は"
7135 "サーバにフラグを渡す機能は持っていないので、 B<O_DIRECT> I/O はクライアント上"
7136 "のページキャッシュをバイパスするだけになり、 サーバは I/O をキャッシュしてい"
7137 "るかもしれない。 クライアントは、 B<O_DIRECT> の同期機構を保持するため、サー"
7138 "バに対して I/O を同期して行うように依頼する。 サーバによっては、こうした状況"
7139 "下、特に I/O サイズが小さい場合に 性能が大きく劣化する。 また、サーバによって"
7140 "は、I/O が安定したストレージにまで行われたと、 クライアントに対して嘘をつくも"
7141 "のもある。 これは、サーバの電源故障が起こった際にデータの完全性が保たれない "
7142 "危険は少しあるが、性能面での不利な条件を回避するために行われている。 Linux "
7143 "の NFS クライアントでは B<O_DIRECT> I/O でのアラインメントの制限はない。"
7144
7145 #. type: Plain text
7146 #: build/C/man2/open.2:884
7147 msgid ""
7148 "In summary, B<O_DIRECT> is a potentially powerful tool that should be used "
7149 "with caution.  It is recommended that applications treat use of B<O_DIRECT> "
7150 "as a performance option which is disabled by default."
7151 msgstr ""
7152 "まとめると、 B<O_DIRECT> は、注意して使うべきであるが、強力なツールとなる可能"
7153 "性を持っている。 アプリケーションは B<O_DIRECT> をデフォルトでは無効になって"
7154 "いる性能向上のためのオプションと 考えておくのがよいであろう。"
7155
7156 #. type: Plain text
7157 #: build/C/man2/open.2:889
7158 msgid ""
7159 "\"The thing that has always disturbed me about O_DIRECT is that the whole "
7160 "interface is just stupid, and was probably designed by a deranged monkey on "
7161 "some serious mind-controlling substances.\"\\(emLinus"
7162 msgstr ""
7163 "「O_DIRECT でいつも困るのは、インタフェース全部が本当にお馬鹿な点だ。 たぶん"
7164 "危ないマインドコントロール剤で 頭がおかしくなったサルが設計したんじゃないか"
7165 "な」 \\(em Linus"
7166
7167 #.  FIXME . Check bugzilla report on open(O_ASYNC)
7168 #.  See http://bugzilla.kernel.org/show_bug.cgi?id=5993
7169 #. type: Plain text
7170 #: build/C/man2/open.2:901
7171 msgid ""
7172 "Currently, it is not possible to enable signal-driven I/O by specifying "
7173 "B<O_ASYNC> when calling B<open>(); use B<fcntl>(2)  to enable this flag."
7174 msgstr ""
7175 "現在のところ、 B<open>()  の呼び出し時に B<O_ASYNC> を指定してシグナル駆動 I/"
7176 "O を有効にすることはできない。 このフラグを有効にするには B<fcntl>(2)  を使用"
7177 "すること。"
7178
7179 #. type: Plain text
7180 #: build/C/man2/open.2:923
7181 msgid ""
7182 "B<chmod>(2), B<chown>(2), B<close>(2), B<dup>(2), B<fcntl>(2), B<link>(2), "
7183 "B<lseek>(2), B<mknod>(2), B<mmap>(2), B<mount>(2), B<openat>(2), B<read>(2), "
7184 "B<socket>(2), B<stat>(2), B<umask>(2), B<unlink>(2), B<write>(2), B<fopen>"
7185 "(3), B<fifo>(7), B<path_resolution>(7), B<symlink>(7)"
7186 msgstr ""
7187 "B<chmod>(2), B<chown>(2), B<close>(2), B<dup>(2), B<fcntl>(2), B<link>(2), "
7188 "B<lseek>(2), B<mknod>(2), B<mmap>(2), B<mount>(2), B<openat>(2), B<read>(2), "
7189 "B<socket>(2), B<stat>(2), B<umask>(2), B<unlink>(2), B<write>(2), B<fopen>"
7190 "(3), B<fifo>(7), B<path_resolution>(7), B<symlink>(7)"
7191
7192 #. type: TH
7193 #: build/C/man3/perror.3:31
7194 #, no-wrap
7195 msgid "PERROR"
7196 msgstr "PERROR"
7197
7198 #. type: TH
7199 #: build/C/man3/perror.3:31
7200 #, no-wrap
7201 msgid "2012-04-17"
7202 msgstr "2012-04-17"
7203
7204 #. type: Plain text
7205 #: build/C/man3/perror.3:34
7206 msgid "perror - print a system error message"
7207 msgstr "perror - システムエラーメッセージを出力する"
7208
7209 #. type: Plain text
7210 #: build/C/man3/perror.3:38
7211 msgid "B<void perror(const char *>I<s>B<);>"
7212 msgstr "B<void perror(const char *>I<s>B<);>"
7213
7214 #. type: Plain text
7215 #: build/C/man3/perror.3:40
7216 msgid "B<#include E<lt>errno.hE<gt>>"
7217 msgstr "B<#include E<lt>errno.hE<gt>>"
7218
7219 #. type: Plain text
7220 #: build/C/man3/perror.3:42
7221 msgid "B<const char *>I<sys_errlist>B<[];>"
7222 msgstr "B<const char *>I<sys_errlist>B<[];>"
7223
7224 #. type: Plain text
7225 #: build/C/man3/perror.3:44
7226 msgid "B<int >I<sys_nerr>B<;>"
7227 msgstr "B<int >I<sys_nerr>B<;>"
7228
7229 #. type: Plain text
7230 #: build/C/man3/perror.3:46
7231 msgid "B<int >I<errno>B<;>"
7232 msgstr "B<int >I<errno>B<;>"
7233
7234 #. type: Plain text
7235 #: build/C/man3/perror.3:55
7236 msgid "I<sys_errlist>, I<sys_nerr>: _BSD_SOURCE"
7237 msgstr "I<sys_errlist>, I<sys_nerr>: _BSD_SOURCE"
7238
7239 #. type: Plain text
7240 #: build/C/man3/perror.3:68
7241 msgid ""
7242 "The routine B<perror>()  produces a message on the standard error output, "
7243 "describing the last error encountered during a call to a system or library "
7244 "function.  First (if I<s> is not NULL and I<*s> is not a null byte (\\(aq"
7245 "\\e0\\(aq)) the argument string I<s> is printed, followed by a colon and a "
7246 "blank.  Then the message and a new-line."
7247 msgstr ""
7248 "関数 B<perror>()  は、システムコールやライブラリ関数の呼び出しにおいて、最後"
7249 "に発生した エラーに関する説明メッセージを生成し、標準エラー出力に出力する。 "
7250 "(I<s> が NULL でなく、 I<*s> が NULL バイト (\\(aq\\e0\\(aq) でない場合には) "
7251 "引き数の文字列 I<s> がまず出力され、続いてコロン、空白が出力され、 それから"
7252 "メッセージと改行が出力される。"
7253
7254 #. type: Plain text
7255 #: build/C/man3/perror.3:76
7256 msgid ""
7257 "To be of most use, the argument string should include the name of the "
7258 "function that incurred the error.  The error number is taken from the "
7259 "external variable I<errno>, which is set when errors occur but not cleared "
7260 "when successful calls are made."
7261 msgstr ""
7262 "このメッセージを最大限活用するためには、引き数文字列にエラーが発生した 関数名"
7263 "を入れておくとよい。 エラー番号は外部変数 I<errno> から取得される。 I<errno> "
7264 "はエラーが発生した時に設定され、 成功した呼び出しではクリアされない。"
7265
7266 #. type: Plain text
7267 #: build/C/man3/perror.3:90
7268 msgid ""
7269 "The global error list I<sys_errlist>[] indexed by I<errno> can be used to "
7270 "obtain the error message without the newline.  The largest message number "
7271 "provided in the table is I<sys_nerr>-1.  Be careful when directly accessing "
7272 "this list because new error values may not have been added to I<sys_errlist>"
7273 "[].  The use of I<sys_errlist>[] is nowadays deprecated."
7274 msgstr ""
7275 "大域変数のエラーリスト I<sys_errlist>[] は I<errno> を添字とする配列で、こ"
7276 "の\n"
7277 "配列から改行無しのエラーメッセージが取得される。 テーブルでの最大のメッセー"
7278 "ジ\n"
7279 "番号は I<sys_nerr> -1 となる。 このテーブルを直接参照する際には注意するこ"
7280 "と。\n"
7281 "なぜなら、新しいエラー番号が I<sys_errlist>[] に追加済とは限らないからであ"
7282 "る。\n"
7283 "現在では、I<sys_errlist>[] の使用は非推奨となっている。"
7284
7285 #. type: Plain text
7286 #: build/C/man3/perror.3:111
7287 msgid ""
7288 "When a system call fails, it usually returns -1 and sets the variable "
7289 "I<errno> to a value describing what went wrong.  (These values can be found "
7290 "in I<E<lt>errno.hE<gt>>.)  Many library functions do likewise.  The function "
7291 "B<perror>()  serves to translate this error code into human-readable form.  "
7292 "Note that I<errno> is undefined after a successful library call: this call "
7293 "may well change this variable, even though it succeeds, for example because "
7294 "it internally used some other library function that failed.  Thus, if a "
7295 "failing call is not immediately followed by a call to B<perror>(), the value "
7296 "of I<errno> should be saved."
7297 msgstr ""
7298 "システムコールが失敗した場合、通常、返り値として -1 が返り、 I<errno> にエ"
7299 "ラーを識別する値が設定される (設定されるエラー番号は I<E<lt>errno.hE<gt>> に"
7300 "記載されている)。 多くのライブラリ関数も同様の動作となる。 関数 B<perror>()  "
7301 "は、このエラーコードの可読なメッセージへの変換を行う。 I<errno> は、ライブラ"
7302 "リ呼び出しが成功した後には未定義であることに注意が必要である: その呼び出し自"
7303 "身は成功したとしても、内部で呼び出した他のライブラリ関数が 失敗して、その結果"
7304 "をこの変数に設定することがあるからだ。 よって、失敗した呼び出しの直後に "
7305 "B<perror>()  を呼ばない場合には I<errno> の値を 保存しておかなければならな"
7306 "い。"
7307
7308 #. type: Plain text
7309 #: build/C/man3/perror.3:124
7310 msgid ""
7311 "The function B<perror>()  and the external I<errno> (see B<errno>(3))  "
7312 "conform to C89, C99, 4.3BSD, POSIX.1-2001.  The externals I<sys_nerr> and "
7313 "I<sys_errlist> conform to BSD."
7314 msgstr ""
7315 "関数 B<perror>()  と外部変数 I<errno> (B<errno>(3)  参照) は C89, 4.3BSD, "
7316 "POSIX.1-2001 に準拠している。 外部変数 I<sys_nerr> と I<sys_errlist> は BSD "
7317 "に準拠している。"
7318
7319 #.  and only when _BSD_SOURCE is defined.
7320 #.  When
7321 #.  .B _GNU_SOURCE
7322 #.  is defined, the symbols
7323 #.  .I _sys_nerr
7324 #.  and
7325 #.  .I _sys_errlist
7326 #.  are provided.
7327 #. type: Plain text
7328 #: build/C/man3/perror.3:139
7329 msgid ""
7330 "The externals I<sys_nerr> and I<sys_errlist> are defined by glibc, but in "
7331 "I<E<lt>stdio.hE<gt>>."
7332 msgstr ""
7333 "外部変数 I<sys_nerr> と I<sys_errlist> は glibc で定義されているが、 "
7334 "I<E<lt>stdio.hE<gt>> に含まれている。"
7335
7336 #. type: Plain text
7337 #: build/C/man3/perror.3:144
7338 msgid "B<err>(3), B<errno>(3), B<error>(3), B<strerror>(3)"
7339 msgstr "B<err>(3), B<errno>(3), B<error>(3), B<strerror>(3)"
7340
7341 #. type: TH
7342 #: build/C/man2/pipe.2:36
7343 #, no-wrap
7344 msgid "PIPE"
7345 msgstr "PIPE"
7346
7347 #. type: TH
7348 #: build/C/man2/pipe.2:36
7349 #, no-wrap
7350 msgid "2012-02-14"
7351 msgstr "2012-02-14"
7352
7353 #. type: Plain text
7354 #: build/C/man2/pipe.2:39
7355 msgid "pipe, pipe2 - create pipe"
7356 msgstr "pipe, pipe2 - パイプを生成する"
7357
7358 #. type: Plain text
7359 #: build/C/man2/pipe.2:42 build/C/man2/read.2:41
7360 #, no-wrap
7361 msgid "B<#include E<lt>unistd.hE<gt>>\n"
7362 msgstr "B<#include E<lt>unistd.hE<gt>>\n"
7363
7364 #. type: Plain text
7365 #: build/C/man2/pipe.2:44
7366 #, no-wrap
7367 msgid "B<int pipe(int >I<pipefd>B<[2]);>\n"
7368 msgstr "B<int pipe(int >I<pipefd>B<[2]);>\n"
7369
7370 #. type: Plain text
7371 #: build/C/man2/pipe.2:48
7372 #, no-wrap
7373 msgid ""
7374 "B<#define _GNU_SOURCE>             /* See feature_test_macros(7) */\n"
7375 "B<#include E<lt>fcntl.hE<gt>>              /* Obtain O_* constant definitions */\n"
7376 "B<#include E<lt>unistd.hE<gt>>\n"
7377 msgstr ""
7378 "B<#define _GNU_SOURCE>             /* feature_test_macros(7) 参照 */\n"
7379 "B<#include E<lt>fcntl.hE<gt>>              /* O_* 定数の定義の取得 */\n"
7380 "B<#include E<lt>unistd.hE<gt>>\n"
7381
7382 #. type: Plain text
7383 #: build/C/man2/pipe.2:50
7384 #, no-wrap
7385 msgid "B<int pipe2(int >I<pipefd>B<[2], int >I<flags>B<);>\n"
7386 msgstr "B<int pipe2(int >I<pipefd>B<[2], int >I<flags>B<);>\n"
7387
7388 #. type: Plain text
7389 #: build/C/man2/pipe.2:66
7390 msgid ""
7391 "B<pipe>()  creates a pipe, a unidirectional data channel that can be used "
7392 "for interprocess communication.  The array I<pipefd> is used to return two "
7393 "file descriptors referring to the ends of the pipe.  I<pipefd[0]> refers to "
7394 "the read end of the pipe.  I<pipefd[1]> refers to the write end of the "
7395 "pipe.  Data written to the write end of the pipe is buffered by the kernel "
7396 "until it is read from the read end of the pipe.  For further details, see "
7397 "B<pipe>(7)."
7398 msgstr ""
7399 "B<pipe>(2)  はパイプを生成する。 パイプは、プロセス間通信に使用できる単方向の"
7400 "データチャネルである。 配列 I<pipefd> は、パイプの両端を参照する二つのファイ"
7401 "ルディスクリプタを 返すのに使用される。 I<pipefd[0]> がパイプの読み出し側、 "
7402 "I<pipefd[1]> がパイプの書き込み側である。 パイプの書き込み側に書き込まれた"
7403 "データは、 パイプの読み出し側から読み出されるまでカーネルでバッファリングされ"
7404 "る。 さらなる詳細は B<pipe>(7)  を参照のこと。"
7405
7406 #. type: Plain text
7407 #: build/C/man2/pipe.2:76
7408 msgid ""
7409 "If I<flags> is 0, then B<pipe2>()  is the same as B<pipe>().  The following "
7410 "values can be bitwise ORed in I<flags> to obtain different behavior:"
7411 msgstr ""
7412 "B<pipe2>()  は I<flags> が 0 の場合には B<pipe>()  と同じである。 I<flags> に"
7413 "以下の値をビット毎の論理和 (OR) で指定することで、 異なる動作をさせることがで"
7414 "きる。"
7415
7416 #. type: TP
7417 #: build/C/man2/pipe.2:76
7418 #, no-wrap
7419 msgid "B<O_NONBLOCK>"
7420 msgstr "B<O_NONBLOCK>"
7421
7422 #. type: Plain text
7423 #: build/C/man2/pipe.2:84
7424 msgid ""
7425 "Set the B<O_NONBLOCK> file status flag on the two new open file "
7426 "descriptions.  Using this flag saves extra calls to B<fcntl>(2)  to achieve "
7427 "the same result."
7428 msgstr ""
7429 "新しく生成される二つのオープンファイル記述 (open file description) の "
7430 "B<O_NONBLOCK> ファイルステータスフラグをセットする。 このフラグを使うこと"
7431 "で、 B<O_NONBLOCK> をセットするために B<fcntl>(2)  を追加で呼び出す必要がなく"
7432 "なる。"
7433
7434 #. type: TP
7435 #: build/C/man2/pipe.2:84
7436 #, no-wrap
7437 msgid "B<O_CLOEXEC>"
7438 msgstr "B<O_CLOEXEC>"
7439
7440 #. type: Plain text
7441 #: build/C/man2/pipe.2:92
7442 msgid ""
7443 "Set the close-on-exec (B<FD_CLOEXEC>)  flag on the two new file "
7444 "descriptors.  See the description of the same flag in B<open>(2)  for "
7445 "reasons why this may be useful."
7446 msgstr ""
7447 "新しく生成される二つのファイルディスクリプタの close-on-exec "
7448 "(B<FD_CLOEXEC>)  フラグをセットする。 このフラグが役に立つ理由については、 "
7449 "B<open>(2)  の B<O_CLOEXEC> フラグの説明を参照のこと。"
7450
7451 #. type: Plain text
7452 #: build/C/man2/pipe.2:102
7453 msgid "I<pipefd> is not valid."
7454 msgstr "I<pipefd> が無効な値である。"
7455
7456 #. type: Plain text
7457 #: build/C/man2/pipe.2:107
7458 msgid "(B<pipe2>())  Invalid value in I<flags>."
7459 msgstr "(B<pipe2>())  I<flags> に無効な値が入っている。"
7460
7461 #. type: Plain text
7462 #: build/C/man2/pipe.2:110
7463 msgid "Too many file descriptors are in use by the process."
7464 msgstr "このプロセスで使われているファイルディスクリプタが多すぎる。"
7465
7466 #. type: Plain text
7467 #: build/C/man2/pipe.2:118
7468 msgid ""
7469 "B<pipe2>()  was added to Linux in version 2.6.27; glibc support is available "
7470 "starting with version 2.9."
7471 msgstr ""
7472 "B<pipe2>()  はバージョン 2.6.27 で Linux に追加された。 glibc によるサポート"
7473 "はバージョン 2.9 以降で利用できる。"
7474
7475 #. type: Plain text
7476 #: build/C/man2/pipe.2:121
7477 msgid "B<pipe>(): POSIX.1-2001."
7478 msgstr "B<pipe>(): POSIX.1-2001."
7479
7480 #. type: Plain text
7481 #: build/C/man2/pipe.2:124
7482 msgid "B<pipe2>()  is Linux-specific."
7483 msgstr "B<pipe2>()  は Linux 固有である。"
7484
7485 #.  fork.2 refers to this example program.
7486 #. type: Plain text
7487 #: build/C/man2/pipe.2:140
7488 msgid ""
7489 "The following program creates a pipe, and then B<fork>(2)s to create a child "
7490 "process; the child inherits a duplicate set of file descriptors that refer "
7491 "to the same pipe.  After the B<fork>(2), each process closes the descriptors "
7492 "that it doesn't need for the pipe (see B<pipe>(7)).  The parent then writes "
7493 "the string contained in the program's command-line argument to the pipe, and "
7494 "the child reads this string a byte at a time from the pipe and echoes it on "
7495 "standard output."
7496 msgstr ""
7497 "以下のプログラムではパイプを生成し、その後 B<fork>(2)  で子プロセスを生成す"
7498 "る。 子プロセスは同じパイプを参照するファイルディスクリプタ集合のコピーを 継"
7499 "承する。 B<fork>(2)  の後、各プロセスはパイプ (B<pipe>(7)  を参照) に必要がな"
7500 "くなったディスクリプタをクローズする。 親プロセスはプログラムのコマンドライン"
7501 "引き数に含まれる 文字列をパイプへ書き込み、 子プロセスはこの文字列をパイプか"
7502 "ら 1 バイトずつ読み込んで標準出力にエコーする。"
7503
7504 #. type: Plain text
7505 #: build/C/man2/pipe.2:147
7506 #, no-wrap
7507 msgid ""
7508 "#include E<lt>sys/wait.hE<gt>\n"
7509 "#include E<lt>stdio.hE<gt>\n"
7510 "#include E<lt>stdlib.hE<gt>\n"
7511 "#include E<lt>unistd.hE<gt>\n"
7512 "#include E<lt>string.hE<gt>\n"
7513 msgstr ""
7514 "#include E<lt>sys/wait.hE<gt>\n"
7515 "#include E<lt>stdio.hE<gt>\n"
7516 "#include E<lt>stdlib.hE<gt>\n"
7517 "#include E<lt>unistd.hE<gt>\n"
7518 "#include E<lt>string.hE<gt>\n"
7519
7520 #. type: Plain text
7521 #: build/C/man2/pipe.2:154
7522 #, no-wrap
7523 msgid ""
7524 "int\n"
7525 "main(int argc, char *argv[])\n"
7526 "{\n"
7527 "    int pipefd[2];\n"
7528 "    pid_t cpid;\n"
7529 "    char buf;\n"
7530 msgstr ""
7531 "int\n"
7532 "main(int argc, char *argv[])\n"
7533 "{\n"
7534 "    int pipefd[2];\n"
7535 "    pid_t cpid;\n"
7536 "    char buf;\n"
7537
7538 #. type: Plain text
7539 #: build/C/man2/pipe.2:159
7540 #, no-wrap
7541 msgid ""
7542 "    if (argc != 2) {\n"
7543 "\tfprintf(stderr, \"Usage: %s E<lt>stringE<gt>\\en\", argv[0]);\n"
7544 "\texit(EXIT_FAILURE);\n"
7545 "    }\n"
7546 msgstr ""
7547 "    if (argc != 2) {\n"
7548 "\tfprintf(stderr, \"Usage: %s E<lt>stringE<gt>\\en\", argv[0]);\n"
7549 "\texit(EXIT_FAILURE);\n"
7550 "    }\n"
7551
7552 #. type: Plain text
7553 #: build/C/man2/pipe.2:164
7554 #, no-wrap
7555 msgid ""
7556 "    if (pipe(pipefd) == -1) {\n"
7557 "        perror(\"pipe\");\n"
7558 "        exit(EXIT_FAILURE);\n"
7559 "    }\n"
7560 msgstr ""
7561 "    if (pipe(pipefd) == -1) {\n"
7562 "        perror(\"pipe\");\n"
7563 "        exit(EXIT_FAILURE);\n"
7564 "    }\n"
7565
7566 #. type: Plain text
7567 #: build/C/man2/pipe.2:170
7568 #, no-wrap
7569 msgid ""
7570 "    cpid = fork();\n"
7571 "    if (cpid == -1) {\n"
7572 "        perror(\"fork\");\n"
7573 "        exit(EXIT_FAILURE);\n"
7574 "    }\n"
7575 msgstr ""
7576 "    cpid = fork();\n"
7577 "    if (cpid == -1) {\n"
7578 "        perror(\"fork\");\n"
7579 "        exit(EXIT_FAILURE);\n"
7580 "    }\n"
7581
7582 #. type: Plain text
7583 #: build/C/man2/pipe.2:173
7584 #, no-wrap
7585 msgid ""
7586 "    if (cpid == 0) {    /* Child reads from pipe */\n"
7587 "        close(pipefd[1]);          /* Close unused write end */\n"
7588 msgstr ""
7589 "    if (cpid == 0) {    /* 子プロセスがパイプから読み込む */\n"
7590 "        close(pipefd[1]);  /* 使用しない write 側はクローズする */\n"
7591
7592 #. type: Plain text
7593 #: build/C/man2/pipe.2:176
7594 #, no-wrap
7595 msgid ""
7596 "        while (read(pipefd[0], &buf, 1) E<gt> 0)\n"
7597 "            write(STDOUT_FILENO, &buf, 1);\n"
7598 msgstr ""
7599 "        while (read(pipefd[0], &buf, 1) E<gt> 0)\n"
7600 "            write(STDOUT_FILENO, &buf, 1);\n"
7601
7602 #. type: Plain text
7603 #: build/C/man2/pipe.2:180
7604 #, no-wrap
7605 msgid ""
7606 "        write(STDOUT_FILENO, \"\\en\", 1);\n"
7607 "        close(pipefd[0]);\n"
7608 "        _exit(EXIT_SUCCESS);\n"
7609 msgstr ""
7610 "        write(STDOUT_FILENO, \"\\en\", 1);\n"
7611 "        close(pipefd[0]);\n"
7612 "        _exit(EXIT_SUCCESS);\n"
7613
7614 #. type: Plain text
7615 #: build/C/man2/pipe.2:189
7616 #, no-wrap
7617 msgid ""
7618 "    } else {            /* Parent writes argv[1] to pipe */\n"
7619 "        close(pipefd[0]);          /* Close unused read end */\n"
7620 "        write(pipefd[1], argv[1], strlen(argv[1]));\n"
7621 "        close(pipefd[1]);          /* Reader will see EOF */\n"
7622 "        wait(NULL);                /* Wait for child */\n"
7623 "        exit(EXIT_SUCCESS);\n"
7624 "    }\n"
7625 "}\n"
7626 msgstr ""
7627 "    } else {            /* 親プロセスは argv[1] をパイプへ書き込む */\n"
7628 "        close(pipefd[0]);          /* 使用しない read 側はクローズする */\n"
7629 "        write(pipefd[1], argv[1], strlen(argv[1]));\n"
7630 "        close(pipefd[1]);          /* 読み込み側が EOF に出会う */\n"
7631 "        wait(NULL);                /* 子プロセスを待つ */\n"
7632 "        exit(EXIT_SUCCESS);\n"
7633 "    }\n"
7634 "}\n"
7635
7636 #. type: Plain text
7637 #: build/C/man2/pipe.2:197
7638 msgid ""
7639 "B<fork>(2), B<read>(2), B<socketpair>(2), B<write>(2), B<popen>(3), B<pipe>"
7640 "(7)"
7641 msgstr ""
7642 "B<fork>(2), B<read>(2), B<socketpair>(2), B<write>(2), B<popen>(3), B<pipe>"
7643 "(7)"
7644
7645 #. type: TH
7646 #: build/C/man3/popen.3:40
7647 #, no-wrap
7648 msgid "POPEN"
7649 msgstr "POPEN"
7650
7651 #. type: Plain text
7652 #: build/C/man3/popen.3:43
7653 msgid "popen, pclose - pipe stream to or from a process"
7654 msgstr "popen, pclose - プロセスとの入力/出力用のパイプストリーム"
7655
7656 #. type: Plain text
7657 #: build/C/man3/popen.3:48
7658 #, no-wrap
7659 msgid "B<FILE *popen(const char *>I<command>B<, const char *>I<type>B<);>\n"
7660 msgstr "B<FILE *popen(const char *>I<command>B<, const char *>I<type>B<);>\n"
7661
7662 #. type: Plain text
7663 #: build/C/man3/popen.3:50
7664 #, no-wrap
7665 msgid "B<int pclose(FILE *>I<stream>B<);>\n"
7666 msgstr "B<int pclose(FILE *>I<stream>B<);>\n"
7667
7668 #. type: Plain text
7669 #: build/C/man3/popen.3:60
7670 msgid "B<popen>(), B<pclose>():"
7671 msgstr "B<popen>(), B<pclose>():"
7672
7673 #. type: Plain text
7674 #: build/C/man3/popen.3:62
7675 msgid ""
7676 "_POSIX_C_SOURCE\\ E<gt>=\\ 2 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE"
7677 msgstr ""
7678 "_POSIX_C_SOURCE\\ E<gt>=\\ 2 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE"
7679
7680 #. type: Plain text
7681 #: build/C/man3/popen.3:73
7682 msgid ""
7683 "The B<popen>()  function opens a process by creating a pipe, forking, and "
7684 "invoking the shell.  Since a pipe is by definition unidirectional, the "
7685 "I<type> argument may specify only reading or writing, not both; the "
7686 "resulting stream is correspondingly read-only or write-only."
7687 msgstr ""
7688 "B<popen>()  関数は、プロセスをオープンする。具体的には、 パイプを生成し、"
7689 "フォークを行い、シェルを起動する。 定義から分かるように、パイプは一方向なの"
7690 "で、 I<type> 引き数には読み込みか書き込みのどちらか一方だけを指定できる (両方"
7691 "は指定できない)。 生成されるストリームは、この指定に対応して、読み取り専用ま"
7692 "たは 書き込み専用のいずれかとなる。"
7693
7694 #. type: Plain text
7695 #: build/C/man3/popen.3:97
7696 msgid ""
7697 "The I<command> argument is a pointer to a null-terminated string containing "
7698 "a shell command line.  This command is passed to I</bin/sh> using the B<-c> "
7699 "flag; interpretation, if any, is performed by the shell.  The I<type> "
7700 "argument is a pointer to a null-terminated string which must contain either "
7701 "the letter \\(aqr\\(aq for reading or the letter \\(aqw\\(aq for writing.  "
7702 "Since glibc 2.9, this argument can additionally include the letter \\(aqe"
7703 "\\(aq, which causes the close-on-exec flag (B<FD_CLOEXEC>)  to be set on the "
7704 "underlying file descriptor; see the description of the B<O_CLOEXEC> flag in "
7705 "B<open>(2)  for reasons why this may be useful."
7706 msgstr ""
7707 "I<command> 引き数は、シェルのコマンドラインを含む NULL 終端された文字列へのポ"
7708 "インタである。 このコマンドは B<-c> フラグを用いて I</bin/sh> に渡される。 コ"
7709 "マンドの解釈は (もし必要ならば) シェルによって行われる。 I<type> 引き数は、"
7710 "NULL 終端された文字列へのポインタで、 読み込みを示す文字 \\(aqr\\(aq か、書き"
7711 "込みを示す文字 \\(aqw\\(aq の どちらか一方を指定しなければならない。 glibc "
7712 "2.9 以降では、この引き数に文字 \\(aqe\\(aq を追加で指定できる。 文字 \\(aqe"
7713 "\\(aq を指定すると、 対応するファイルディスクリプタにおいて、 close-on-exec "
7714 "フラグ (B<FD_CLOEXEC>)  がセットされる。 これが役に立つ理由については、 "
7715 "B<open>(2)  の B<O_CLOEXEC> フラグの説明を参照のこと。"
7716
7717 #. type: Plain text
7718 #: build/C/man3/popen.3:113
7719 msgid ""
7720 "The return value from B<popen>()  is a normal standard I/O stream in all "
7721 "respects save that it must be closed with B<pclose>()  rather than B<fclose>"
7722 "(3).  Writing to such a stream writes to the standard input of the command; "
7723 "the command's standard output is the same as that of the process that called "
7724 "B<popen>(), unless this is altered by the command itself.  Conversely, "
7725 "reading from a \"popened\" stream reads the command's standard output, and "
7726 "the command's standard input is the same as that of the process that called "
7727 "B<popen>()."
7728 msgstr ""
7729 "B<popen>()  からの返り値は、通常の標準 I/O ストリームと同じであるが、 "
7730 "B<fclose>(3)  ではなく B<pclose>()  で閉じなくてはならないことだけが異なる。 "
7731 "このストリームへ書き込んだ結果はコマンドの標準入力に書き込まれる。 そして、コ"
7732 "マンドの標準出力は、 コマンドそのものが置き換わってしまわない限り、 B<popen>"
7733 "()  を呼んだプロセスの標準出力と同じことになる。 逆に、\"popened\" (B<popen>"
7734 "()  によって開かれた) ストリームからの読み込みは、 そのコマンドの標準出力を読"
7735 "み込むことになる。 そして、そのコマンドの標準入力は B<popen>()  を呼んだプロ"
7736 "セスの標準入力と同一である。"
7737
7738 #. type: Plain text
7739 #: build/C/man3/popen.3:117
7740 msgid "Note that output B<popen>()  streams are fully buffered by default."
7741 msgstr ""
7742 "デフォルトでは、 B<popen>()  の出力ストリームは完全にバッファリングされること"
7743 "に注意しよう。"
7744
7745 #. type: Plain text
7746 #: build/C/man3/popen.3:123
7747 msgid ""
7748 "The B<pclose>()  function waits for the associated process to terminate and "
7749 "returns the exit status of the command as returned by B<wait4>(2)."
7750 msgstr ""
7751 "B<pclose>()  関数は、(パイプに) 関連づけられたプロセスが終了するのを待ち、 "
7752 "B<wait4>(2)  によって返されたコマンドの終了状態を返す。"
7753
7754 #. type: Plain text
7755 #: build/C/man3/popen.3:131
7756 msgid ""
7757 "The B<popen>()  function returns NULL if the B<fork>(2)  or B<pipe>(2)  "
7758 "calls fail, or if it cannot allocate memory."
7759 msgstr ""
7760 "B<popen>()  関数は、 B<fork>(2)  または B<pipe>(2)  呼び出しが失敗した場合"
7761 "や、 メモリ割り当てができなかった場合、 NULL を返す。"
7762
7763 #.  These conditions actually give undefined results, so I commented
7764 #.  them out.
7765 #.  .I stream
7766 #.  is not associated with a "popen()ed" command, if
7767 #. .I stream
7768 #.  already "pclose()d", or if
7769 #. type: Plain text
7770 #: build/C/man3/popen.3:146
7771 msgid ""
7772 "The B<pclose>()  function returns -1 if B<wait4>(2)  returns an error, or "
7773 "some other error is detected.  In the event of an error, these functions set "
7774 "I<errnro> to indicate the cause of the error."
7775 msgstr "B<pclose>()  関数は、 B<wait4>(2)  がエラーを返したり、何か他のエラーが見つかった場合、 -1 を返す。 その場合、 I<errno> にエラーの原因を示す値が設定される。"
7776
7777 #. type: Plain text
7778 #: build/C/man3/popen.3:165
7779 msgid ""
7780 "The B<popen>()  function does not set I<errno> if memory allocation fails.  "
7781 "If the underlying B<fork>(2)  or B<pipe>(2)  fails, I<errno> is set "
7782 "appropriately.  If the I<type> argument is invalid, and this condition is "
7783 "detected, I<errno> is set to B<EINVAL>."
7784 msgstr ""
7785 "B<popen>()  関数は、メモリアロケーションに失敗しても I<errno> をセットしな"
7786 "い。 B<popen>()  が中で呼び出す B<fork>(2)  や B<pipe>(2)  が失敗した場合に"
7787 "は、 I<errno> が適切にセットされる。 引き数 I<type> が無効であり、この状態が"
7788 "検知された場合には、 I<errno> が B<EINVAL> にセットされる。"
7789
7790 #. type: Plain text
7791 #: build/C/man3/popen.3:172
7792 msgid ""
7793 "If B<pclose>()  cannot obtain the child status, I<errno> is set to B<ECHILD>."
7794 msgstr ""
7795 "B<pclose>()  が、子プロセスの状態を取得できなかった場合、 I<errno> が "
7796 "B<ECHILD> にセットされる。"
7797
7798 #. type: Plain text
7799 #: build/C/man3/popen.3:178
7800 msgid "The \\(aqe\\(aq value for I<type> is a Linux extension."
7801 msgstr "I<type> に指定できる \\(aqe\\(aq は Linux での拡張である。"
7802
7803 #. type: Plain text
7804 #: build/C/man3/popen.3:191
7805 msgid ""
7806 "Since the standard input of a command opened for reading shares its seek "
7807 "offset with the process that called B<popen>(), if the original process has "
7808 "done a buffered read, the command's input position may not be as expected.  "
7809 "Similarly, the output from a command opened for writing may become "
7810 "intermingled with that of the original process.  The latter can be avoided "
7811 "by calling B<fflush>(3)  before B<popen>()."
7812 msgstr ""
7813 "読み込みのために開かれたコマンドの標準入力は B<popen>(), を呼んだプロセスと一"
7814 "緒に、その読み取り位置を共有する。 そのため、もとのプロセスがバッファリングさ"
7815 "れた読み取りを終了したら、 そのコマンドの入力位置は予想されたものには なって"
7816 "いないかもしれない。 同様に、書き込みのために開かれたコマンドからの出力は、 "
7817 "もとのプロセスの出力と混ざり合うことになるかもしれない。 後者は B<popen>()  "
7818 "の前に B<fflush>(3)  を呼び出すことによって回避可能である。"
7819
7820 #.  .SH HISTORY
7821 #.  A
7822 #.  .BR popen ()
7823 #.  and a
7824 #.  .BR pclose ()
7825 #.  function appeared in Version 7 AT&T UNIX.
7826 #. type: Plain text
7827 #: build/C/man3/popen.3:201
7828 msgid ""
7829 "Failure to execute the shell is indistinguishable from the shell's failure "
7830 "to execute command, or an immediate exit of the command.  The only hint is "
7831 "an exit status of 127."
7832 msgstr ""
7833 "シェルの実行の失敗は、 シェルがコマンドの実行に失敗したことや、 コマンドがす"
7834 "ぐに終了してしまったことと、区別がつかない。 唯一のヒントは終了状態が 127 に"
7835 "なることである。"
7836
7837 #. type: Plain text
7838 #: build/C/man3/popen.3:211
7839 msgid ""
7840 "B<sh>(1), B<fork>(2), B<pipe>(2), B<wait4>(2), B<fclose>(3), B<fflush>(3), "
7841 "B<fopen>(3), B<stdio>(3), B<system>(3)"
7842 msgstr ""
7843 "B<sh>(1), B<fork>(2), B<pipe>(2), B<wait4>(2), B<fclose>(3), B<fflush>(3), "
7844 "B<fopen>(3), B<stdio>(3), B<system>(3)"
7845
7846 #. type: TH
7847 #: build/C/man3/printf.3:34
7848 #, no-wrap
7849 msgid "PRINTF"
7850 msgstr "PRINTF"
7851
7852 #. type: TH
7853 #: build/C/man3/printf.3:34
7854 #, no-wrap
7855 msgid "2013-03-05"
7856 msgstr "2013-03-05"
7857
7858 #. type: Plain text
7859 #: build/C/man3/printf.3:38
7860 msgid ""
7861 "printf, fprintf, sprintf, snprintf, vprintf, vfprintf, vsprintf, vsnprintf - "
7862 "formatted output conversion"
7863 msgstr ""
7864 "printf, fprintf, sprintf, snprintf, vprintf, vfprintf, vsprintf, vsnprintf - "
7865 "指定された書式に変換して出力を行う"
7866
7867 #. type: Plain text
7868 #: build/C/man3/printf.3:42
7869 msgid "B<int printf(const char *>I<format>B<, ...);>"
7870 msgstr "B<int printf(const char *>I<format>B<, ...);>"
7871
7872 #. type: Plain text
7873 #: build/C/man3/printf.3:44
7874 msgid "B<int fprintf(FILE *>I<stream>B<, const char *>I<format>B<, ...);>"
7875 msgstr "B<int fprintf(FILE *>I<stream>B<, const char *>I<format>B<, ...);>"
7876
7877 #. type: Plain text
7878 #: build/C/man3/printf.3:46
7879 msgid "B<int sprintf(char *>I<str>B<, const char *>I<format>B<, ...);>"
7880 msgstr "B<int sprintf(char *>I<str>B<, const char *>I<format>B<, ...);>"
7881
7882 #. type: Plain text
7883 #: build/C/man3/printf.3:48
7884 msgid ""
7885 "B<int snprintf(char *>I<str>B<, size_t >I<size>B<, const char "
7886 "*>I<format>B<, ...);>"
7887 msgstr ""
7888 "B<int snprintf(char *>I<str>B<, size_t >I<size>B<, const char "
7889 "*>I<format>B<, ...);>"
7890
7891 #. type: Plain text
7892 #: build/C/man3/printf.3:50
7893 msgid "B<#include E<lt>stdarg.hE<gt>>"
7894 msgstr "B<#include E<lt>stdarg.hE<gt>>"
7895
7896 #. type: Plain text
7897 #: build/C/man3/printf.3:52
7898 msgid "B<int vprintf(const char *>I<format>B<, va_list >I<ap>B<);>"
7899 msgstr "B<int vprintf(const char *>I<format>B<, va_list >I<ap>B<);>"
7900
7901 #. type: Plain text
7902 #: build/C/man3/printf.3:54
7903 msgid ""
7904 "B<int vfprintf(FILE *>I<stream>B<, const char *>I<format>B<, va_list "
7905 ">I<ap>B<);>"
7906 msgstr ""
7907 "B<int vfprintf(FILE *>I<stream>B<, const char *>I<format>B<, va_list "
7908 ">I<ap>B<);>"
7909
7910 #. type: Plain text
7911 #: build/C/man3/printf.3:56
7912 msgid ""
7913 "B<int vsprintf(char *>I<str>B<, const char *>I<format>B<, va_list >I<ap>B<);>"
7914 msgstr ""
7915 "B<int vsprintf(char *>I<str>B<, const char *>I<format>B<, va_list >I<ap>B<);>"
7916
7917 #. type: Plain text
7918 #: build/C/man3/printf.3:59
7919 msgid ""
7920 "B<int vsnprintf(char *>I<str>B<, size_t >I<size>B<, const char "
7921 "*>I<format>B<, va_list >I<ap>B<);>"
7922 msgstr ""
7923 "B<int vsnprintf(char *>I<str>B<, size_t >I<size>B<, const char "
7924 "*>I<format>B<, va_list >I<ap>B<);>"
7925
7926 #. type: Plain text
7927 #: build/C/man3/printf.3:68
7928 msgid "B<snprintf>(), B<vsnprintf>():"
7929 msgstr "B<snprintf>(), B<vsnprintf>():"
7930
7931 #. type: Plain text
7932 #: build/C/man3/printf.3:71
7933 msgid ""
7934 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _ISOC99_SOURCE || "
7935 "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L;"
7936 msgstr ""
7937 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _ISOC99_SOURCE || "
7938 "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L;"
7939
7940 #. type: Plain text
7941 #: build/C/man3/printf.3:74 build/C/man3/scanf.3:85
7942 msgid "or I<cc -std=c99>"
7943 msgstr "or I<cc -std=c99>"
7944
7945 #. type: Plain text
7946 #: build/C/man3/printf.3:101
7947 msgid ""
7948 "The functions in the B<printf>()  family produce output according to a "
7949 "I<format> as described below.  The functions B<printf>()  and B<vprintf>()  "
7950 "write output to I<stdout>, the standard output stream; B<fprintf>()  and "
7951 "B<vfprintf>()  write output to the given output I<stream>; B<sprintf>(), "
7952 "B<snprintf>(), B<vsprintf>()  and B<vsnprintf>()  write to the character "
7953 "string I<str>."
7954 msgstr ""
7955 "B<printf>()  関数グループは、以下で述べるように、 I<format> に従って出力を生"
7956 "成するものである。 B<printf>()  と B<vprintf>()  は出力を I<stdout> (標準出力"
7957 "ストリーム) に書き出す。 B<fprintf>()  と B<vfprintf>()  は出力を指定された出"
7958 "力 I<stream> に書き出す。 B<sprintf>(), B<snprintf>(), B<vsprintf>(), "
7959 "B<vsnprintf>()  は出力を文字列 I<str> に書き込む。"
7960
7961 #. type: Plain text
7962 #: build/C/man3/printf.3:110
7963 msgid ""
7964 "The functions B<snprintf>()  and B<vsnprintf>()  write at most I<size> bytes "
7965 "(including the terminating null byte (\\(aq\\e0\\(aq)) to I<str>."
7966 msgstr ""
7967 "B<snprintf>()  と B<vsnprintf>()  は最大で I<size> バイトを I<str> に書き込"
7968 "む (I<size> には文字列を終端する NULL バイト (\\(aq\\e0\\(aq) もを含まれる)。"
7969
7970 #. type: Plain text
7971 #: build/C/man3/printf.3:134
7972 msgid ""
7973 "The functions B<vprintf>(), B<vfprintf>(), B<vsprintf>(), B<vsnprintf>()  "
7974 "are equivalent to the functions B<printf>(), B<fprintf>(), B<sprintf>(), "
7975 "B<snprintf>(), respectively, except that they are called with a I<va_list> "
7976 "instead of a variable number of arguments.  These functions do not call the "
7977 "I<va_end> macro.  Because they invoke the I<va_arg> macro, the value of "
7978 "I<ap> is undefined after the call.  See B<stdarg>(3)."
7979 msgstr ""
7980 "B<vprintf>(), B<vfprintf>(), B<vsprintf>(), B<vsnprintf>()  の各関数はそれぞ"
7981 "れ B<printf>(), B<fprintf>(), B<sprintf>(), B<snprintf>(), の各関数と等価であ"
7982 "り、可変数引き数の代わりに I<va_list> を引き数として呼び出される点だけが異な"
7983 "る。 これらの関数では I<va_end> マクロは呼び出されない。 これらの関数は "
7984 "I<va_arg> を呼び出すので、呼び出し後の I<ap> の値は未定義である。 B<stdarg>"
7985 "(3)  を参照のこと。"
7986
7987 #. type: Plain text
7988 #: build/C/man3/printf.3:141
7989 msgid ""
7990 "These eight functions write the output under the control of a I<format> "
7991 "string that specifies how subsequent arguments (or arguments accessed via "
7992 "the variable-length argument facilities of B<stdarg>(3))  are converted for "
7993 "output."
7994 msgstr ""
7995 "これらの 8 つの関数は I<format> 文字列の制御に従って出力を書き出す。 "
7996 "I<format> 文字列は、これに続く引き数 (または B<stdarg>(3)  の可変長引き数機構"
7997 "を使ってアクセスできる引き数)  をどのように変換して出力するかを指定する。"
7998
7999 #. type: Plain text
8000 #: build/C/man3/printf.3:152
8001 msgid ""
8002 "C99 and POSIX.1-2001 specify that the results are undefined if a call to "
8003 "B<sprintf>(), B<snprintf>(), B<vsprintf>(), or B<vsnprintf>()  would cause "
8004 "copying to take place between objects that overlap (e.g., if the target "
8005 "string array and one of the supplied input arguments refer to the same "
8006 "buffer).  See NOTES."
8007 msgstr ""
8008 "C99 と POSIX.1-2001 では、 B<sprintf>(), B<snprintf>(), B<vsprintf>(), "
8009 "B<vsnprintf>()  の呼び出しで、範囲が重複するオブジェクト間でコピーが発生する"
8010 "場合の 結果は不定であると規定されている (例えば、出力先の文字列と入力された "
8011 "引き数の一つが同じバッファを参照している場合などである)。 「注意」の節を参"
8012 "照。"
8013
8014 #. type: SS
8015 #: build/C/man3/printf.3:152
8016 #, no-wrap
8017 msgid "Return value"
8018 msgstr "Return Values"
8019
8020 #. type: Plain text
8021 #: build/C/man3/printf.3:155
8022 msgid ""
8023 "Upon successful return, these functions return the number of characters "
8024 "printed (excluding the null byte used to end output to strings)."
8025 msgstr ""
8026 "成功時には、上記の関数は書き込まれた文字数を返す (文字列の最後を示すために使"
8027 "用する NULL バイトは数に含まれない)。"
8028
8029 #. type: Plain text
8030 #: build/C/man3/printf.3:171
8031 msgid ""
8032 "The functions B<snprintf>()  and B<vsnprintf>()  do not write more than "
8033 "I<size> bytes (including the terminating null byte (\\(aq\\e0\\(aq)).  If "
8034 "the output was truncated due to this limit then the return value is the "
8035 "number of characters (excluding the terminating null byte)  which would have "
8036 "been written to the final string if enough space had been available.  Thus, "
8037 "a return value of I<size> or more means that the output was truncated.  (See "
8038 "also below under NOTES.)"
8039 msgstr ""
8040 "B<snprintf>()  と B<vsnprintf>()  は、 I<size> バイトを越える文字数を書き込ま"
8041 "ない (I<size> には文字列を終端する NULL バイト (\\(aq\\e0\\(aq) も含まれ"
8042 "る)。 この制限によって出力が切り詰められた場合には、 もし十分なスペースがあれ"
8043 "ば書き込まれたであろう文字の個数 (文字列を終端する NULL バイトを除く) を返"
8044 "す。 従って、返り値が I<size> 以上だった場合、出力が切り詰められたことを意味"
8045 "する (後述の注意も参照のこと)。"
8046
8047 #. type: Plain text
8048 #: build/C/man3/printf.3:173
8049 msgid "If an output error is encountered, a negative value is returned."
8050 msgstr "エラーが発生した場合は、負の数を返す。"
8051
8052 #. type: SS
8053 #: build/C/man3/printf.3:173
8054 #, no-wrap
8055 msgid "Format of the format string"
8056 msgstr "フォーマット文字列のフォーマット"
8057
8058 #. type: Plain text
8059 #: build/C/man3/printf.3:195
8060 msgid ""
8061 "The format string is a character string, beginning and ending in its initial "
8062 "shift state, if any.  The format string is composed of zero or more "
8063 "directives: ordinary characters (not B<%>), which are copied unchanged to "
8064 "the output stream; and conversion specifications, each of which results in "
8065 "fetching zero or more subsequent arguments.  Each conversion specification "
8066 "is introduced by the character B<%>, and ends with a I<conversion "
8067 "specifier>.  In between there may be (in this order) zero or more I<flags>, "
8068 "an optional minimum I<field width>, an optional I<precision> and an optional "
8069 "I<length modifier>."
8070 msgstr ""
8071 "フォーマット文字列は文字の列で、 (もしあるなら) 初期シフト状態で始まり、初期"
8072 "シフト状態で終わる。 フォーマット用の文字列は 0 個以上の命令 (directives) に"
8073 "よって構成される。 命令には、通常文字と変換指定 (conversion specifications) "
8074 "がある。 通常文字は B<%> 以外の文字で、出力ストリームにそのままコピーされ"
8075 "る。 変換指定は、それぞれが 0 個以上の引き数を取る。 各変換指定は文字 B<%> で"
8076 "始まり、 I<変換指定子 (conversion specifier)> で終わる。 B<%> と変換指定子の"
8077 "間には、0 個以上の I<フラグ 、> 最小 I<フィールド幅 、> I<精度 、> I<長さ修飾"
8078 "子> を (この順序で) 置くことができる。"
8079
8080 #. type: Plain text
8081 #: build/C/man3/printf.3:208
8082 msgid ""
8083 "The arguments must correspond properly (after type promotion) with the "
8084 "conversion specifier.  By default, the arguments are used in the order "
8085 "given, where each \\(aq*\\(aq and each conversion specifier asks for the "
8086 "next argument (and it is an error if insufficiently many arguments are "
8087 "given).  One can also specify explicitly which argument is taken, at each "
8088 "place where an argument is required, by writing \"%m$\" instead of \\(aq%"
8089 "\\(aq and \"*m$\" instead of \\(aq*\\(aq, where the decimal integer m "
8090 "denotes the position in the argument list of the desired argument, indexed "
8091 "starting from 1.  Thus,"
8092 msgstr ""
8093 "引き数は (型の格上げの後は) 変換指定子が表す型と正確に対応しなければならな"
8094 "い。 デフォルトでは、\\(aq*\\(aq や変換指定子が出てくる毎に次の引き数を要求さ"
8095 "れ、 引き数は指定された順序で使用されていく (指定された引き数の個数が不十分な"
8096 "らエラーとなる)。 また、引き数が必要な箇所で \\(aq%\\(aq の代わりに \"%m$"
8097 "\"、 \\(aq*\\(aqの代わりに \"*m$\" と書くことで、 明示的にどの引き数を使用す"
8098 "るかを指定することもできる。 ここで 10進の整数 m は希望の引き数の引き数リスト"
8099 "での位置を示す (最初の引き数の番号が 1 である)。 従って、"
8100
8101 #. type: Plain text
8102 #: build/C/man3/printf.3:212
8103 #, no-wrap
8104 msgid "printf(\"%*d\", width, num);\n"
8105 msgstr "printf(\"%*d\", width, num);\n"
8106
8107 #. type: Plain text
8108 #: build/C/man3/printf.3:216
8109 msgid "and"
8110 msgstr "と"
8111
8112 #. type: Plain text
8113 #: build/C/man3/printf.3:220
8114 #, no-wrap
8115 msgid "printf(\"%2$*1$d\", width, num);\n"
8116 msgstr "printf(\"%2$*1$d\", width, num);\n"
8117
8118 #. type: Plain text
8119 #: build/C/man3/printf.3:236
8120 msgid ""
8121 "are equivalent.  The second style allows repeated references to the same "
8122 "argument.  The C99 standard does not include the style using \\(aq$\\(aq, "
8123 "which comes from the Single UNIX Specification.  If the style using \\(aq$"
8124 "\\(aq is used, it must be used throughout for all conversions taking an "
8125 "argument and all width and precision arguments, but it may be mixed with \"%%"
8126 "\" formats which do not consume an argument.  There may be no gaps in the "
8127 "numbers of arguments specified using \\(aq$\\(aq; for example, if arguments "
8128 "1 and 3 are specified, argument 2 must also be specified somewhere in the "
8129 "format string."
8130 msgstr ""
8131 "は等価である。 二番目の書き方では同じ引き数を繰り返し参照することができる。 "
8132 "C99 標準には、 Single UNIX Specification 由来の \\(aq$\\(aq を使った書き方は"
8133 "含まれていない。 \\(aq$\\(aq を使ったスタイルを使うと、引き数を取る変換及び幅"
8134 "と精度の引き数を 全てこのスタイルで指定しなければならないが、 引き数を消費し"
8135 "ない \"%%\" フォーマットと混ざっているかもしれない。 \\(aq$\\(aq で指定される"
8136 "引き数の番号に空きがあってはならない。 例えば、もし引き数 1 と 3 が指定される"
8137 "と、引き数 2 もフォーマット文字列のどこかで 指定されなければならない。"
8138
8139 #. type: Plain text
8140 #: build/C/man3/printf.3:246
8141 msgid ""
8142 "For some numeric conversions a radix character (\"decimal point\") or "
8143 "thousands' grouping character is used.  The actual character used depends on "
8144 "the B<LC_NUMERIC> part of the locale.  The POSIX locale uses \\(aq.\\(aq as "
8145 "radix character, and does not have a grouping character.  Thus,"
8146 msgstr ""
8147 "数値変換には小数点や 1000 単位の区切り文字を使うものもある。 実際にどの文字を"
8148 "使うかはロケールの B<LC_NUMERIC> による。 POSIX ロケールでは小数点に \\(aq."
8149 "\\(aq を用い、 区切り文字は使わない。 従って、"
8150
8151 #. type: Plain text
8152 #: build/C/man3/printf.3:250
8153 #, no-wrap
8154 msgid "    printf(\"%\\(aq.2f\", 1234567.89);\n"
8155 msgstr "printf(\"%\\(aq.2f\", 1234567.89);\n"
8156
8157 #. type: Plain text
8158 #: build/C/man3/printf.3:255
8159 msgid ""
8160 "results in \"1234567.89\" in the POSIX locale, in \"1234567,89\" in the "
8161 "nl_NL locale, and in \"1.234.567,89\" in the da_DK locale."
8162 msgstr ""
8163 "は、 POSIX ロケールでは \"1234567.89\" 、 nl_NL ロケールでは "
8164 "\"1234567,89\"、 da_DK ロケールでは \"1.234.567,89\" となる。"
8165
8166 #. type: SS
8167 #: build/C/man3/printf.3:255
8168 #, no-wrap
8169 msgid "The flag characters"
8170 msgstr "フラグ文字"
8171
8172 #. type: Plain text
8173 #: build/C/man3/printf.3:257
8174 msgid "The character % is followed by zero or more of the following flags:"
8175 msgstr "% 文字の後ろには 0 個以上のフラグ文字が続く。"
8176
8177 #. type: TP
8178 #: build/C/man3/printf.3:257
8179 #, no-wrap
8180 msgid "B<#>"
8181 msgstr "B<#>"
8182
8183 #. type: Plain text
8184 #: build/C/man3/printf.3:291
8185 msgid ""
8186 "The value should be converted to an \"alternate form\".  For B<o> "
8187 "conversions, the first character of the output string is made zero (by "
8188 "prefixing a 0 if it was not zero already).  For B<x> and B<X> conversions, a "
8189 "nonzero result has the string \"0x\" (or \"0X\" for B<X> conversions) "
8190 "prepended to it.  For B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, and B<G> "
8191 "conversions, the result will always contain a decimal point, even if no "
8192 "digits follow it (normally, a decimal point appears in the results of those "
8193 "conversions only if a digit follows).  For B<g> and B<G> conversions, "
8194 "trailing zeros are not removed from the result as they would otherwise be.  "
8195 "For other conversions, the result is undefined."
8196 msgstr ""
8197 "値は「別の形式」に変換される。 B<o> 変換の場合、(先頭文字が 0 になっていない"
8198 "場合に先頭に 0 を追加することで)  出力文字列の最初の文字を 0 にする。 B<x> "
8199 "と B<X> 変換の場合、数値が 0 でないときには文字列 \"0x\" (B<X> 変換の場合に"
8200 "は \"0X\") が前に付与される。 B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, B<G> "
8201 "変換では、 小数点に続く数字がなくても、 出力には常に小数点が含まれる (通常"
8202 "は、小数点の後に数字が続く場合にのみ、 小数点が表示される)。 B<g> と B<G> 変"
8203 "換の場合、他の変換とは異なり、末尾のゼロが変換結果から削除されない。 その他の"
8204 "変換では、結果は未定義である。"
8205
8206 #. type: TP
8207 #: build/C/man3/printf.3:291
8208 #, no-wrap
8209 msgid "B<\\&0>"
8210 msgstr "B<\\&0>"
8211
8212 #. type: Plain text
8213 #: build/C/man3/printf.3:331
8214 msgid ""
8215 "The value should be zero padded.  For B<d>, B<i>, B<o>, B<u>, B<x>, B<X>, "
8216 "B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, and B<G> conversions, the "
8217 "converted value is padded on the left with zeros rather than blanks.  If the "
8218 "B<\\&0> and B<-> flags both appear, the B<\\&0> flag is ignored.  If a "
8219 "precision is given with a numeric conversion (B<d>, B<i>, B<o>, B<u>, B<x>, "
8220 "and B<X>), the B<\\&0> flag is ignored.  For other conversions, the behavior "
8221 "is undefined."
8222 msgstr ""
8223 "値をゼロで埋める。 B<d>, B<i>, B<o>, B<u>, B<x>, B<X>, B<a>, B<A>, B<e>, "
8224 "B<E>, B<f>, B<F>, B<g>, B<G> 変換では、変換した値の左側を空白文字の代わりにゼ"
8225 "ロで埋める。 B<\\&0> と B<-> が両方とも指定された場合は、 B<\\&0> フラグは無"
8226 "視される。 精度が数値変換 (B<d>, B<i>, B<o>, B<u>, B<x>, B<X>)  と同時に指定"
8227 "された場合には、 B<\\&0> フラグは無視される。 その他の変換では、動作は未定義"
8228 "である。"
8229
8230 #. type: TP
8231 #: build/C/man3/printf.3:331
8232 #, no-wrap
8233 msgid "B<->"
8234 msgstr "B<->"
8235
8236 #. type: Plain text
8237 #: build/C/man3/printf.3:344
8238 msgid ""
8239 "The converted value is to be left adjusted on the field boundary.  (The "
8240 "default is right justification.)  Except for B<n> conversions, the converted "
8241 "value is padded on the right with blanks, rather than on the left with "
8242 "blanks or zeros.  A B<-> overrides a B<\\&0> if both are given."
8243 msgstr ""
8244 "変換値をフィールド境界で左揃えにする (デフォルトは右揃えである)。 B<n> 変換以"
8245 "外では、変換された値は 左側ではなく右側を空白文字やゼロで埋められる。 B<-> "
8246 "と B<\\&0> の両方が指定された場合には、 B<-> が優先される。"
8247
8248 #. type: TP
8249 #: build/C/man3/printf.3:344
8250 #, no-wrap
8251 msgid "B<\\(aq \\(aq>"
8252 msgstr "B<' '>"
8253
8254 #. type: Plain text
8255 #: build/C/man3/printf.3:348
8256 msgid ""
8257 "(a space) A blank should be left before a positive number (or empty string) "
8258 "produced by a signed conversion."
8259 msgstr ""
8260 "(1個の半角スペース)  符号付き変換で生成された正の数字の前に空白 (または空文字"
8261 "列) が置かれる。"
8262
8263 #. type: TP
8264 #: build/C/man3/printf.3:348
8265 #, no-wrap
8266 msgid "B<+>"
8267 msgstr "B<+>"
8268
8269 #. type: Plain text
8270 #: build/C/man3/printf.3:356
8271 msgid ""
8272 "A sign (+ or -) should always be placed before a number produced by a signed "
8273 "conversion.  By default a sign is used only for negative numbers.  A B<+> "
8274 "overrides a space if both are used."
8275 msgstr ""
8276 "符号付き変換によって出力される数字の前に、常に符号 (+ か -) が置かれる。 デ"
8277 "フォルトでは、符号は負の数字の場合のみ付与される。 B<+> と半角スペースの 両方"
8278 "が使われている場合には、 B<+> が優先される。"
8279
8280 #. type: Plain text
8281 #: build/C/man3/printf.3:359
8282 msgid ""
8283 "The five flag characters above are defined in the C standard.  The SUSv2 "
8284 "specifies one further flag character."
8285 msgstr ""
8286 "上記の 5 つのフラグは C 標準で定義されている。 SUSv2 では、さらにもう一つフラ"
8287 "グ文字が規定されている。"
8288
8289 #. type: TP
8290 #: build/C/man3/printf.3:359
8291 #, no-wrap
8292 msgid "B<\\(aq>"
8293 msgstr "B<\\(aq>"
8294
8295 #. type: Plain text
8296 #: build/C/man3/printf.3:376
8297 msgid ""
8298 "For decimal conversion (B<i>, B<d>, B<u>, B<f>, B<F>, B<g>, B<G>)  the "
8299 "output is to be grouped with thousands' grouping characters if the locale "
8300 "information indicates any.  Note that many versions of B<gcc>(1)  cannot "
8301 "parse this option and will issue a warning.  SUSv2 does not include I<%"
8302 "\\(aqF>."
8303 msgstr ""
8304 "10進数変換 (B<i>, B<d>, B<u>, B<f>, B<F>, B<g>, B<G>)  において、ロケール情報"
8305 "に指定があれば 1000 単位の区切り文字を出力する。 B<gcc>(1)  の多くのバージョ"
8306 "ンは、このオプションを解釈することができず、 警告を出力することに注意せよ。 %"
8307 "\\(aqF は SUSv2 には含まれていない。"
8308
8309 #. type: Plain text
8310 #: build/C/man3/printf.3:378
8311 msgid "glibc 2.2 adds one further flag character."
8312 msgstr "glibc 2.2 では、さらに一つフラグ文字が追加されている。"
8313
8314 #. type: TP
8315 #: build/C/man3/printf.3:378
8316 #, no-wrap
8317 msgid "B<I>"
8318 msgstr "B<I>"
8319
8320 #.  outdigits keyword in locale file
8321 #. type: Plain text
8322 #: build/C/man3/printf.3:388
8323 msgid ""
8324 "For decimal integer conversion (B<i>, B<d>, B<u>)  the output uses the "
8325 "locale's alternative output digits, if any.  For example, since glibc 2.2.3 "
8326 "this will give Arabic-Indic digits in the Persian (\"fa_IR\") locale."
8327 msgstr ""
8328 "10進整数変換 (B<i>, B<d>, B<u>)  において、ロケールの代替出力数字があれば、そ"
8329 "れを用いて出力する。 例えば、 glibc 2.2.3 以降では、ペルシア (\"fa_IR\") ロ"
8330 "ケールで アラビア数字 (Arabic-Indic digits) を出力できる。"
8331
8332 #. type: SS
8333 #: build/C/man3/printf.3:388
8334 #, no-wrap
8335 msgid "The field width"
8336 msgstr "フィールド幅"
8337
8338 #. type: Plain text
8339 #: build/C/man3/printf.3:404
8340 msgid ""
8341 "An optional decimal digit string (with nonzero first digit) specifying a "
8342 "minimum field width.  If the converted value has fewer characters than the "
8343 "field width, it will be padded with spaces on the left (or right, if the "
8344 "left-adjustment flag has been given).  Instead of a decimal digit string one "
8345 "may write \"*\" or \"*m$\" (for some decimal integer I<m>) to specify that "
8346 "the field width is given in the next argument, or in the I<m>-th argument, "
8347 "respectively, which must be of type I<int>.  A negative field width is taken "
8348 "as a \\(aq-\\(aq flag followed by a positive field width.  In no case does a "
8349 "nonexistent or small field width cause truncation of a field; if the result "
8350 "of a conversion is wider than the field width, the field is expanded to "
8351 "contain the conversion result."
8352 msgstr ""
8353 "最小のフィールド幅を指定する 10進数の数値文字列 (文字列の最初の文字は ゼロ以"
8354 "外)。本項目はオプションである。 変換された値の文字数がフィールド長よりも少な"
8355 "い場合、 フィールドの左側をスペースで埋める (左揃えのフラグがある場合は右側を"
8356 "埋める)。 10進数の文字列の代わりに \"*\" や \"*m$\" (I<m> は 10進整数) を書く"
8357 "こともできる。 \"*\" と \"*m$\" はそれぞれ、次の引き数と I<m> 番目の引き数を"
8358 "フィールド幅として 使うことを指定する (これらの引き数は I<int> 型でなければな"
8359 "らない)。 フィールド幅に負の数が指定された場合は、 \\(aq-\\(aq フラグと正の数"
8360 "のフィールド幅として扱われる。 フィールド幅が小さかったり指定がなかったりして"
8361 "も、フィールドが切り詰められる ことはない。もし変換結果がフィールド幅よりも広"
8362 "かった場合、 フィールドは変換結果が入る幅に広げられる。"
8363
8364 #. type: SS
8365 #: build/C/man3/printf.3:404
8366 #, no-wrap
8367 msgid "The precision"
8368 msgstr "精度"
8369
8370 #. type: Plain text
8371 #: build/C/man3/printf.3:440
8372 msgid ""
8373 "An optional precision, in the form of a period (\\(aq.\\(aq)  followed by an "
8374 "optional decimal digit string.  Instead of a decimal digit string one may "
8375 "write \"*\" or \"*m$\" (for some decimal integer m) to specify that the "
8376 "precision is given in the next argument, or in the m-th argument, "
8377 "respectively, which must be of type I<int>.  If the precision is given as "
8378 "just \\(aq.\\(aq, or the precision is negative, the precision is taken to be "
8379 "zero.  This gives the minimum number of digits to appear for B<d>, B<i>, "
8380 "B<o>, B<u>, B<x>, and B<X> conversions, the number of digits to appear after "
8381 "the radix character for B<a>, B<A>, B<e>, B<E>, B<f>, and B<F> conversions, "
8382 "the maximum number of significant digits for B<g> and B<G> conversions, or "
8383 "the maximum number of characters to be printed from a string for B<s> and "
8384 "B<S> conversions."
8385 msgstr ""
8386 "オプションである精度は、ピリオド (\\(aq.\\(aq) とそれに続く10進数という 形式"
8387 "で指定する (10進数はオプション) 。 10進数の文字列の代わりに \"*\" や \"*m$"
8388 "\" (m は 10 進整数)を書くこともできる。 \"*\" と \"*m$\" はそれぞれ、次の引き"
8389 "数と m 番目の引き数を精度として 使うことを指定する (これらの引き数は I<int> "
8390 "型でなければならない)。 精度として \\(aq.\\(aq だけが指定されたり、精度が負の"
8391 "数だった場合、 精度はゼロとみなされる。 B<d>, B<i>, B<o>, B<u>, B<x>, B<X> 変"
8392 "換では、表示される最小の桁数を指定する。 B<a>, B<A>, B<e>, B<E>, B<f>, B<F> "
8393 "変換では、小数点以下に表示される数字の桁数を指定する。 B<g> と B<G> 変換で"
8394 "は、有効数字の最大桁数を指定する。 B<s> と B<S> 変換では、文字列から出力され"
8395 "る最大文字数を指定する。"
8396
8397 #. type: SS
8398 #: build/C/man3/printf.3:440
8399 #, no-wrap
8400 msgid "The length modifier"
8401 msgstr "長さ修飾子"
8402
8403 #. type: Plain text
8404 #: build/C/man3/printf.3:450
8405 msgid ""
8406 "Here, \"integer conversion\" stands for B<d>, B<i>, B<o>, B<u>, B<x>, or "
8407 "B<X> conversion."
8408 msgstr ""
8409 "「整数変換」とは、 B<d>, B<i>, B<o>, B<u>, B<x>, B<X> 変換のことである。"
8410
8411 #. type: TP
8412 #: build/C/man3/printf.3:450 build/C/man3/scanf.3:294
8413 #, no-wrap
8414 msgid "B<hh>"
8415 msgstr "B<hh>"
8416
8417 #. type: Plain text
8418 #: build/C/man3/printf.3:461
8419 msgid ""
8420 "A following integer conversion corresponds to a I<signed char> or I<unsigned "
8421 "char> argument, or a following B<n> conversion corresponds to a pointer to a "
8422 "I<signed char> argument."
8423 msgstr ""
8424 "整数変換に対応する引き数が I<signed char> か I<unsigned char> で、 B<n> 変換"
8425 "に対応する引き数が I<signed char> へのポインタであることを示す。"
8426
8427 #. type: TP
8428 #: build/C/man3/printf.3:461 build/C/man3/scanf.3:284
8429 #, no-wrap
8430 msgid "B<h>"
8431 msgstr "B<h>"
8432
8433 #. type: Plain text
8434 #: build/C/man3/printf.3:472
8435 msgid ""
8436 "A following integer conversion corresponds to a I<short int> or I<unsigned "
8437 "short int> argument, or a following B<n> conversion corresponds to a pointer "
8438 "to a I<short int> argument."
8439 msgstr ""
8440 "整数変換に対応する引き数が I<short int> か I<unsigned short int> で、 B<n> 変"
8441 "換に対応する引き数が I<short int> へのポインタであることを示す。"
8442
8443 #. type: TP
8444 #: build/C/man3/printf.3:472 build/C/man3/scanf.3:311
8445 #, no-wrap
8446 msgid "B<l>"
8447 msgstr "B<l>"
8448
8449 #. type: Plain text
8450 #: build/C/man3/printf.3:491
8451 msgid ""
8452 "(ell) A following integer conversion corresponds to a I<long int> or "
8453 "I<unsigned long int> argument, or a following B<n> conversion corresponds to "
8454 "a pointer to a I<long int> argument, or a following B<c> conversion "
8455 "corresponds to a I<wint_t> argument, or a following B<s> conversion "
8456 "corresponds to a pointer to I<wchar_t> argument."
8457 msgstr ""
8458 "各変換に対応する引き数が、 整数変換では I<long int>か I<unsigned long int>、 "
8459 "B<n> 変換では I<long long int> へのポインタ、 B<c> 変換では I<wint_t>、 B<s> "
8460 "変換では I<wchar_t> へのポインタであることを示す。"
8461
8462 #. type: TP
8463 #: build/C/man3/printf.3:491
8464 #, no-wrap
8465 msgid "B<ll>"
8466 msgstr "B<ll> (エルエル)"
8467
8468 #. type: Plain text
8469 #: build/C/man3/printf.3:503
8470 msgid ""
8471 "(ell-ell).  A following integer conversion corresponds to a I<long long int> "
8472 "or I<unsigned long long int> argument, or a following B<n> conversion "
8473 "corresponds to a pointer to a I<long long int> argument."
8474 msgstr ""
8475 "整数変換に対応する引き数が I<long long int> か I<unsigned long long int> "
8476 "で、 B<n> 変換に対応する引き数が I<long int> へのポインタであることを示す。"
8477
8478 #. type: TP
8479 #: build/C/man3/printf.3:503 build/C/man3/scanf.3:338
8480 #, no-wrap
8481 msgid "B<L>"
8482 msgstr "B<L>"
8483
8484 #. type: Plain text
8485 #: build/C/man3/printf.3:519
8486 msgid ""
8487 "A following B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, or B<G> conversion "
8488 "corresponds to a I<long double> argument.  (C99 allows %LF, but SUSv2 does "
8489 "not.)"
8490 msgstr ""
8491 "B<a>, B<A>, B<e>, B<E>, B<f>, B<F>, B<g>, B<G> 変換に対応する引き数が I<long "
8492 "double> であることを示す。 (C99 では %LF を使うことを認めているが、SUSv2 では"
8493 "認められていない。)"
8494
8495 #. type: TP
8496 #: build/C/man3/printf.3:519 build/C/man3/scanf.3:354
8497 #, no-wrap
8498 msgid "B<q>"
8499 msgstr "B<q>"
8500
8501 #. type: Plain text
8502 #: build/C/man3/printf.3:525
8503 msgid ""
8504 "(\"quad\". 4.4BSD and Linux libc5 only.  Don't use.)  This is a synonym for "
8505 "B<ll>."
8506 msgstr ""
8507 "(\"quad\"。 4.4BSD と Linux libc5 のみ有効。使ってはならない。)  B<ll> と同じ"
8508 "意味である。"
8509
8510 #. type: TP
8511 #: build/C/man3/printf.3:525 build/C/man3/scanf.3:302
8512 #, no-wrap
8513 msgid "B<j>"
8514 msgstr "B<j>"
8515
8516 #. type: Plain text
8517 #: build/C/man3/printf.3:532
8518 msgid ""
8519 "A following integer conversion corresponds to an I<intmax_t> or I<uintmax_t> "
8520 "argument."
8521 msgstr ""
8522 "整数変換に対応する引き数が I<intmax_t> か I<uintmax_t> であることを示す。"
8523
8524 #. type: TP
8525 #: build/C/man3/printf.3:532 build/C/man3/scanf.3:366
8526 #, no-wrap
8527 msgid "B<z>"
8528 msgstr "B<z>"
8529
8530 #. type: Plain text
8531 #: build/C/man3/printf.3:543
8532 msgid ""
8533 "A following integer conversion corresponds to a I<size_t> or I<ssize_t> "
8534 "argument.  (Linux libc5 has B<Z> with this meaning.  Don't use it.)"
8535 msgstr ""
8536 "整数変換に対応する引き数が I<size_t> か I<ssize_t> であることを示す。 (Linux "
8537 "libc5 では、これを指定するのに B<Z> を用いる。使ってはならない。)"
8538
8539 #. type: TP
8540 #: build/C/man3/printf.3:543 build/C/man3/scanf.3:359
8541 #, no-wrap
8542 msgid "B<t>"
8543 msgstr "B<t>"
8544
8545 #. type: Plain text
8546 #: build/C/man3/printf.3:548
8547 msgid "A following integer conversion corresponds to a I<ptrdiff_t> argument."
8548 msgstr "整数変換に対応する引き数が I<ptrdiff_t> であることを示す。"
8549
8550 #. type: Plain text
8551 #: build/C/man3/printf.3:577
8552 msgid ""
8553 "The SUSv2 knows about only the length modifiers B<h> (in B<hd>, B<hi>, "
8554 "B<ho>, B<hx>, B<hX>, B<hn>)  and B<l> (in B<ld>, B<li>, B<lo>, B<lx>, B<lX>, "
8555 "B<ln>, B<lc>, B<ls>)  and B<L> (in B<Le>, B<LE>, B<Lf>, B<Lg>, B<LG>)."
8556 msgstr ""
8557 "SUSv2 で長さ修飾子として使用できるのは、 B<h> (B<hd>, B<hi>, B<ho>, B<hx>, "
8558 "B<hX>, B<hn>), B<l> (B<ld>, B<li>, B<lo>, B<lx>, B<lX>, B<ln>, B<lc>, "
8559 "B<ls>), B<L> (B<Le>, B<LE>, B<Lf>, B<Lg>, B<LG>)  だけである。"
8560
8561 #. type: SS
8562 #: build/C/man3/printf.3:577
8563 #, no-wrap
8564 msgid "The conversion specifier"
8565 msgstr "変換指定子"
8566
8567 #. type: Plain text
8568 #: build/C/man3/printf.3:580
8569 msgid ""
8570 "A character that specifies the type of conversion to be applied.  The "
8571 "conversion specifiers and their meanings are:"
8572 msgstr ""
8573 "適用される変換の型を指定する文字。 変換指定子とその意味は以下の通りである。"
8574
8575 #. type: TP
8576 #: build/C/man3/printf.3:580
8577 #, no-wrap
8578 msgid "B<d>, B<i>"
8579 msgstr "B<d>, B<i>"
8580
8581 #. type: Plain text
8582 #: build/C/man3/printf.3:590
8583 msgid ""
8584 "The I<int> argument is converted to signed decimal notation.  The precision, "
8585 "if any, gives the minimum number of digits that must appear; if the "
8586 "converted value requires fewer digits, it is padded on the left with zeros.  "
8587 "The default precision is 1.  When 0 is printed with an explicit precision 0, "
8588 "the output is empty."
8589 msgstr ""
8590 "I<int> 引き数を符号付き 10 進表記に変換する。 精度指定があれば、精度で指定し"
8591 "た桁数は必ず出力される。変換後の値が 指定された桁数に足りない場合は、左側が "
8592 "0 で埋められる。 デフォルトの精度は 1 である。 0 を表示しようとした時に、明示"
8593 "的に精度として 0 が指定されていると、 出力は空文字列となる。"
8594
8595 #. type: TP
8596 #: build/C/man3/printf.3:590
8597 #, no-wrap
8598 msgid "B<o>, B<u>, B<x>, B<X>"
8599 msgstr "B<o>, B<u>, B<x>, B<X>"
8600
8601 #. type: Plain text
8602 #: build/C/man3/printf.3:617
8603 msgid ""
8604 "The I<unsigned int> argument is converted to unsigned octal (B<o>), unsigned "
8605 "decimal (B<u>), or unsigned hexadecimal (B<x> and B<X>)  notation.  The "
8606 "letters B<abcdef> are used for B<x> conversions; the letters B<ABCDEF> are "
8607 "used for B<X> conversions.  The precision, if any, gives the minimum number "
8608 "of digits that must appear; if the converted value requires fewer digits, it "
8609 "is padded on the left with zeros.  The default precision is 1.  When 0 is "
8610 "printed with an explicit precision 0, the output is empty."
8611 msgstr ""
8612 "I<unsigned int> 引き数を、 符号なし8進数 (B<o>), 符号なし10進数 (B<u>), 符号"
8613 "なし16進数 (B<x> と B<X>)  に変換する。 B<x> 変換では B<abcdef> が使用され、 "
8614 "B<X> 変換では B<ABCDEF> が使用される。 精度指定があれば、精度で指定した桁数は"
8615 "必ず出力される。変換後の値が 指定された桁数に足りない場合は、左側が 0 で埋め"
8616 "られる。"
8617
8618 #. type: TP
8619 #: build/C/man3/printf.3:617
8620 #, no-wrap
8621 msgid "B<e>, B<E>"
8622 msgstr "B<e>, B<E>"
8623
8624 #. type: Plain text
8625 #: build/C/man3/printf.3:636
8626 msgid ""
8627 "The I<double> argument is rounded and converted in the style [-]dB<\\&."
8628 ">dddB<e>\\(+-dd where there is one digit before the decimal-point character "
8629 "and the number of digits after it is equal to the precision; if the "
8630 "precision is missing, it is taken as 6; if the precision is zero, no decimal-"
8631 "point character appears.  An B<E> conversion uses the letter B<E> (rather "
8632 "than B<e>)  to introduce the exponent.  The exponent always contains at "
8633 "least two digits; if the value is zero, the exponent is 00."
8634 msgstr ""
8635 "I<double> 引き数を丸めて [-]dB<\\&.>dddB<e>\\(+-dd の形に変換する。\n"
8636 "小数点の前には一桁の数字があり、小数点以下の桁数は精度で指定された桁数\n"
8637 "になる。精度は指定されなかった場合 6 とみなされる。 精度が 0 の場合には、\n"
8638 "小数点以下は表示されない。B<E> 変換では、指数を表現するときに (B<e> で\n"
8639 "はなく) B<E> が使われる。指数部分は少なくとも 2桁表示される。つまり、\n"
8640 "指数の値が 0 の場合には、00 と表示される。"
8641
8642 #. type: TP
8643 #: build/C/man3/printf.3:636
8644 #, no-wrap
8645 msgid "B<f>, B<F>"
8646 msgstr "B<f>, B<F>"
8647
8648 #. type: Plain text
8649 #: build/C/man3/printf.3:647
8650 msgid ""
8651 "The I<double> argument is rounded and converted to decimal notation in the "
8652 "style [-]dddB<\\&.>ddd, where the number of digits after the decimal-point "
8653 "character is equal to the precision specification.  If the precision is "
8654 "missing, it is taken as 6; if the precision is explicitly zero, no decimal-"
8655 "point character appears.  If a decimal point appears, at least one digit "
8656 "appears before it."
8657 msgstr ""
8658 "I<double> 引き数を丸めて [-]dddB<\\&.>ddd の形の10進表現に変換する。 小数点の"
8659 "後の桁数は、精度で指定された値となる。 精度が指定されていない場合には 6 とし"
8660 "て扱われる。 精度として明示的に 0 が指定されたときには、小数点以下は表示され"
8661 "ない。 小数点を表示する際には、小数点の前に少なくとも一桁は数字が表示される。"
8662
8663 #. type: Plain text
8664 #: build/C/man3/printf.3:658
8665 msgid ""
8666 "(The SUSv2 does not know about B<F> and says that character string "
8667 "representations for infinity and NaN may be made available.  The C99 "
8668 "standard specifies \"[-]inf\" or \"[-]infinity\" for infinity, and a string "
8669 "starting with \"nan\" for NaN, in the case of B<f> conversion, and \"[-]INF"
8670 "\" or \"[-]INFINITY\" or \"NAN*\" in the case of B<F> conversion.)"
8671 msgstr ""
8672 "(SUSv2 では、B<F> は規定されておらず、無限や NaN に関する文字列表現を\n"
8673 "行ってもよいことになっている。\n"
8674 " C99 標準では、B<f> 変換では、無限は \"[-]inf\" か \"[-]infinity\" と表示"
8675 "し、\n"
8676 "NaN は文字列の先頭に `nan' をつけて表示するように規定されている。\n"
8677 "B<F> 変換の場合は \"[-]INF\", \"[-]INFINITY\", \"NAN*\" と表示される。)"
8678
8679 #. type: TP
8680 #: build/C/man3/printf.3:658
8681 #, no-wrap
8682 msgid "B<g>, B<G>"
8683 msgstr "B<g>, B<G>"
8684
8685 #. type: Plain text
8686 #: build/C/man3/printf.3:683
8687 msgid ""
8688 "The I<double> argument is converted in style B<f> or B<e> (or B<F> or B<E> "
8689 "for B<G> conversions).  The precision specifies the number of significant "
8690 "digits.  If the precision is missing, 6 digits are given; if the precision "
8691 "is zero, it is treated as 1.  Style B<e> is used if the exponent from its "
8692 "conversion is less than -4 or greater than or equal to the precision.  "
8693 "Trailing zeros are removed from the fractional part of the result; a decimal "
8694 "point appears only if it is followed by at least one digit."
8695 msgstr ""
8696 "I<double> 引き数を B<f> か B<e> (B<G> 変換の場合は B<F> か B<E>)  の形式に変"
8697 "換する。 精度は表示する桁数を指定する。 精度が指定されない場合は、6桁とみなさ"
8698 "れる。 精度が 0 の場合は、1桁とみなされる。 変換される値の指数が、 -4 より小"
8699 "さいか、精度以上の場合に、 B<e> 形式が使用される。 変換された結果の小数部分の"
8700 "末尾の 0 は削除される。小数点が表示されるのは、 小数点以下に数字が少なくとも"
8701 "一つある場合にだけである。"
8702
8703 #. type: TP
8704 #: build/C/man3/printf.3:683
8705 #, no-wrap
8706 msgid "B<a>, B<A>"
8707 msgstr "B<a>, B<A>"
8708
8709 #. type: Plain text
8710 #: build/C/man3/printf.3:707
8711 msgid ""
8712 "(C99; not in SUSv2) For B<a> conversion, the I<double> argument is converted "
8713 "to hexadecimal notation (using the letters abcdef)  in the style [-]B<0x>hB<"
8714 "\\&.>hhhhB<p>\\(+-; for B<A> conversion the prefix B<0X>, the letters "
8715 "ABCDEF, and the exponent separator B<P> is used.  There is one hexadecimal "
8716 "digit before the decimal point, and the number of digits after it is equal "
8717 "to the precision.  The default precision suffices for an exact "
8718 "representation of the value if an exact representation in base 2 exists and "
8719 "otherwise is sufficiently large to distinguish values of type I<double>.  "
8720 "The digit before the decimal point is unspecified for nonnormalized numbers, "
8721 "and nonzero but otherwise unspecified for normalized numbers."
8722 msgstr ""
8723 "(C99 にはあるが SUSv2 にはない) B<a> 変換では、 I<double> 引き数を\n"
8724 "(abcdef の文字を使って) [-]B<0x>hB<\\&.>hhhhB<p>\\(+- 形式の\n"
8725 "16 進表記に変換する。\n"
8726 "B<A> 変換では、前置文字列 B<0X>, 文字 ABCDEF, 指数文字 B<P> を用いる。\n"
8727 "小数点の前には 1 桁の 16 進数が置かれ、小数点の後ろの桁数は 精度で指定\n"
8728 "された値となる。デフォルトの精度は、その値が 2 進数で正確に表現できる\n"
8729 "場合には、その値を正確に表現できる桁数となる。それ以外の場合は、\n"
8730 "I<double> 型の値を区別するのに十分な大きさとなる。 小数点の前の数字は、\n"
8731 "正規化されていない数の場合はいくつになるか分からない。 正規化された数の\n"
8732 "場合は、 0 以外の値になるが、いくつになるかは分からない。"
8733
8734 #. type: TP
8735 #: build/C/man3/printf.3:707 build/C/man3/scanf.3:459
8736 #: build/C/man3/wprintf.3:151
8737 #, no-wrap
8738 msgid "B<c>"
8739 msgstr "B<c>"
8740
8741 #. type: Plain text
8742 #: build/C/man3/printf.3:725
8743 msgid ""
8744 "If no B<l> modifier is present, the I<int> argument is converted to an "
8745 "I<unsigned char>, and the resulting character is written.  If an B<l> "
8746 "modifier is present, the I<wint_t> (wide character) argument is converted to "
8747 "a multibyte sequence by a call to the B<wcrtomb>(3)  function, with a "
8748 "conversion state starting in the initial state, and the resulting multibyte "
8749 "string is written."
8750 msgstr ""
8751 "B<l> 修飾子がなければ、 I<int> 引き数を I<unsigned char> に変換して、その結果"
8752 "に対応する文字を出力する。 B<l> 修飾子があれば、 I<wint_t> (ワイド文字) 引き"
8753 "数を、 B<wcrtomb>(3)  関数を初期シフト状態で呼び出してマルチバイト文字列に変"
8754 "換し、 変換されたマルチバイト文字列を出力する。"
8755
8756 #. type: TP
8757 #: build/C/man3/printf.3:725 build/C/man3/scanf.3:451
8758 #: build/C/man3/wprintf.3:165
8759 #, no-wrap
8760 msgid "B<s>"
8761 msgstr "B<s>"
8762
8763 #. type: Plain text
8764 #: build/C/man3/printf.3:740
8765 msgid ""
8766 "If no B<l> modifier is present: The I<const char\\ *> argument is expected "
8767 "to be a pointer to an array of character type (pointer to a string).  "
8768 "Characters from the array are written up to (but not including) a "
8769 "terminating null byte (\\(aq\\e0\\(aq); if a precision is specified, no more "
8770 "than the number specified are written.  If a precision is given, no null "
8771 "byte need be present; if the precision is not specified, or is greater than "
8772 "the size of the array, the array must contain a terminating null byte."
8773 msgstr "B<l> 修飾子がない場合、 引き数は I<const char\\ *> 型で文字型の配列へのポインタ (文字列へのポインタ) であることが 期待されている。配列中の文字は、終端の NULL バイト (\\(aq\\e0\\(aq)  が出てくるまで出力される (終端文字は出力されない)。 精度が指定されていると、指定された字数以上は出力されない。 精度が指定された場合には、終端バイトが存在する必要はない。 精度が指定されていなかったり、精度の値が配列の大きさより大きい場合には、 配列は終端の NULL バイトを含んでいなければならない。"
8774
8775 #. type: Plain text
8776 #: build/C/man3/printf.3:767
8777 msgid ""
8778 "If an B<l> modifier is present: The I<const wchar_t\\ *> argument is "
8779 "expected to be a pointer to an array of wide characters.  Wide characters "
8780 "from the array are converted to multibyte characters (each by a call to the "
8781 "B<wcrtomb>(3)  function, with a conversion state starting in the initial "
8782 "state before the first wide character), up to and including a terminating "
8783 "null wide character.  The resulting multibyte characters are written up to "
8784 "(but not including) the terminating null byte.  If a precision is specified, "
8785 "no more bytes than the number specified are written, but no partial "
8786 "multibyte characters are written.  Note that the precision determines the "
8787 "number of I<bytes> written, not the number of I<wide characters> or I<screen "
8788 "positions>.  The array must contain a terminating null wide character, "
8789 "unless a precision is given and it is so small that the number of bytes "
8790 "written exceeds it before the end of the array is reached."
8791 msgstr "B<l> 修飾子が指定されている場合、 引き数は I<const wchar_t\\ *> 型でワイド文字の配列へのポインタであることが期待されている。 配列中のワイド文字は (1文字毎に B<wcrtomb>(3)  を呼び出して) マルチバイト文字に変換される (最初のワイド文字の変換の前に B<wcrtomb>()  のシフト状態を初期状態に戻してから変換は行われる)。 マルチバイト文字への変換は、文字列を終端する NULL ワイド文字が 出てくるまで行われ、終端 NULL ワイド文字も含めて変換される。 結果のマルチバイト文字列は、終端の NULL バイトが出てくるまで 出力される (終端の NULL バイトは出力されない)。 精度が指定された場合、指定されたバイト数以上には出力されない。 但し、マルチバイト文字の一部分だけが出力されることはない。 精度は「バイト」数を指定するものであり、「ワイド文字」数や 「画面での位置」を指定するものではないことに注意。 精度が指定されていて、さらに出力が配列の末尾に達する前に出力バイト数が 精度の値を超える場合だけは、配列は NULL ワイド文字で終端されていなくてもよい。 それ以外の場合は、必ず配列は NULL ワイド文字で終端されていなければならない。"
8792
8793 #. type: TP
8794 #: build/C/man3/printf.3:767
8795 #, no-wrap
8796 msgid "B<C>"
8797 msgstr "B<C>"
8798
8799 #. type: Plain text
8800 #: build/C/man3/printf.3:773
8801 msgid "(Not in C99, but in SUSv2.)  Synonym for B<lc>.  Don't use."
8802 msgstr "(C99 にはないが SUSv2 にはある)  B<lc> と同じ。使ってはならない。"
8803
8804 #. type: TP
8805 #: build/C/man3/printf.3:773
8806 #, no-wrap
8807 msgid "B<S>"
8808 msgstr "B<S>"
8809
8810 #. type: Plain text
8811 #: build/C/man3/printf.3:779
8812 msgid "(Not in C99, but in SUSv2.)  Synonym for B<ls>.  Don't use."
8813 msgstr "(C99 にはないが SUSv2 にはある)  B<ls> と同じ。使ってはならない。"
8814
8815 #. type: TP
8816 #: build/C/man3/printf.3:779 build/C/man3/scanf.3:502
8817 #, no-wrap
8818 msgid "B<p>"
8819 msgstr "B<p>"
8820
8821 #. type: Plain text
8822 #: build/C/man3/printf.3:787
8823 msgid ""
8824 "The I<void\\ *> pointer argument is printed in hexadecimal (as if by B<%#x> "
8825 "or B<%#lx>)."
8826 msgstr "I<void\\ *> ポインタ引き数を (B<%#x> や B<%#lx> のような) 16 進数で出力する。"
8827
8828 #. type: TP
8829 #: build/C/man3/printf.3:787 build/C/man3/scanf.3:510
8830 #, no-wrap
8831 msgid "B<n>"
8832 msgstr "B<n>"
8833
8834 #. type: Plain text
8835 #: build/C/man3/printf.3:794
8836 msgid ""
8837 "The number of characters written so far is stored into the integer indicated "
8838 "by the I<int\\ *> (or variant) pointer argument.  No argument is converted."
8839 msgstr "これまでに出力された文字数を I<int\\ *> (または類似の型) のポインタ引き数が指す整数に保存する。 引き数の変換は行われない。"
8840
8841 #. type: TP
8842 #: build/C/man3/printf.3:794
8843 #, no-wrap
8844 msgid "B<m>"
8845 msgstr "B<m>"
8846
8847 #. type: Plain text
8848 #: build/C/man3/printf.3:800
8849 msgid ""
8850 "(Glibc extension.)  Print output of I<strerror(errno)>.  No argument is "
8851 "required."
8852 msgstr ""
8853 "(glibc での拡張)  I<strerror(errno)> の出力を表示する。引き数は必要ない。"
8854
8855 #. type: TP
8856 #: build/C/man3/printf.3:800 build/C/man3/scanf.3:377
8857 #, no-wrap
8858 msgid "B<%>"
8859 msgstr "B<%>"
8860
8861 #. type: Plain text
8862 #: build/C/man3/printf.3:806
8863 msgid ""
8864 "A \\(aq%\\(aq is written.  No argument is converted.  The complete "
8865 "conversion specification is \\(aq%%\\(aq."
8866 msgstr ""
8867 "\\(aq%\\(aq 文字を出力する。変換される引き数は無い。 変換指定全体を書くと \"%"
8868 "%\" となる。"
8869
8870 #. type: Plain text
8871 #: build/C/man3/printf.3:821
8872 msgid ""
8873 "The B<fprintf>(), B<printf>(), B<sprintf>(), B<vprintf>(), B<vfprintf>(), "
8874 "and B<vsprintf>()  functions conform to C89 and C99.  The B<snprintf>()  and "
8875 "B<vsnprintf>()  functions conform to C99."
8876 msgstr ""
8877 "B<fprintf>(), B<printf>(), B<sprintf>(), B<vprintf>(), B<vfprintf>(), "
8878 "B<vsprintf>()  関数は、C89 と C99 に準拠している。 B<snprintf>()  と "
8879 "B<vsnprintf>()  は C99 に準拠している。"
8880
8881 #. type: Plain text
8882 #: build/C/man3/printf.3:834
8883 msgid ""
8884 "Concerning the return value of B<snprintf>(), SUSv2 and C99 contradict each "
8885 "other: when B<snprintf>()  is called with I<size>=0 then SUSv2 stipulates an "
8886 "unspecified return value less than 1, while C99 allows I<str> to be NULL in "
8887 "this case, and gives the return value (as always)  as the number of "
8888 "characters that would have been written in case the output string has been "
8889 "large enough."
8890 msgstr ""
8891 "B<snprintf>()  の返り値を見ると、 SUSv2 と C99 標準は互いに矛盾している。 "
8892 "SUSv2 では、 B<snprintf>()  が I<size>=0 で呼び出された場合、 1 未満の値を何"
8893 "か返り値とするように規定している。 一方 C99 では、このような場合 I<str> を "
8894 "NULL とし、返り値として (通常通り) 出力バッファが十分な大きさが あった場合に"
8895 "出力されるであろう文字数を返す。"
8896
8897 #. type: Plain text
8898 #: build/C/man3/printf.3:848
8899 msgid ""
8900 "Linux libc4 knows about the five C standard flags.  It knows about the "
8901 "length modifiers B<h>, B<l>, B<L>, and the conversions B<c>, B<d>, B<e>, "
8902 "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 "
8903 "B<X>, where B<F> is a synonym for B<f>.  Additionally, it accepts B<D>, "
8904 "B<O>, and B<U> as synonyms for B<ld>, B<lo>, and B<lu>.  (This is bad, and "
8905 "caused serious bugs later, when support for B<%D> disappeared.)  No locale-"
8906 "dependent radix character, no thousands' separator, no NaN or infinity, no "
8907 "\"%m$\" and \"*m$\"."
8908 msgstr ""
8909 "Linux libc4 では、 5 つの C 標準のフラグ、 長さ修飾子 B<h>, B<l>, B<L>、変換 "
8910 "B<c>, B<d>, B<e>, B<E>, B<f>, B<F>, B<g>, B<G>, B<i>, B<n>, B<o>, B<p>, "
8911 "B<s>, B<u>, B<x>, B<X> が使える。 但し B<F> は B<f> と同義である。 また、 "
8912 "B<D>, B<O>, and B<U> を B<ld>, B<lo>, and B<lu> と同じものとして使える (これ"
8913 "はまずい仕様で、 後に B<%D> の対応が打ち切られた時に深刻なバグを 引き起こし"
8914 "た)。ロケール依存の小数点、1000 区切り、 NaN と無限、 \"%m$\" と \"*m$\" は使"
8915 "えない。"
8916
8917 #. type: Plain text
8918 #: build/C/man3/printf.3:859
8919 msgid ""
8920 "Linux libc5 knows about the five C standard flags and the \\(aq flag, "
8921 "locale, \"%m$\" and \"*m$\".  It knows about the length modifiers B<h>, "
8922 "B<l>, B<L>, B<Z>, and B<q>, but accepts B<L> and B<q> both for I<long "
8923 "double> and for I<long long int> (this is a bug).  It no longer recognizes "
8924 "B<F>, B<D>, B<O>, and B<U>, but adds the conversion character B<m>, which "
8925 "outputs I<strerror(errno)>."
8926 msgstr ""
8927 "Linux libc5 では、 5 つの C 標準のフラグと \\(aq フラグ、ロケール、 \"%m$\" "
8928 "と \"*m$\" が使える。 また、長さ修飾子 B<h>, B<l>, B<L>, B<Z>, iand B<q> が使"
8929 "えるが、 B<L> と B<q> は両方とも I<long double> と I<long long int> に対応し"
8930 "ている (これはバグである)。 現在では変換 B<F>, B<D>, B<O>, B<U> は認識されな"
8931 "いが、変換文字 B<m> が追加された。これは I<strerror(errno)> を出力するもので"
8932 "ある。"
8933
8934 #. type: Plain text
8935 #: build/C/man3/printf.3:861
8936 msgid "glibc 2.0 adds conversion characters B<C> and B<S>."
8937 msgstr "glibc 2.0 では、変換文字 B<C> と B<S> が追加された。"
8938
8939 #. type: Plain text
8940 #: build/C/man3/printf.3:864
8941 msgid ""
8942 "glibc 2.1 adds length modifiers B<hh>, B<j>, B<t>, and B<z> and conversion "
8943 "characters B<a> and B<A>."
8944 msgstr ""
8945 "glibc 2.1 では、長さ修飾子 B<hh>, B<j>, B<t>, B<z> と変換文字 B<a>, B<A> が追"
8946 "加された。"
8947
8948 #. type: Plain text
8949 #: build/C/man3/printf.3:867
8950 msgid ""
8951 "glibc 2.2 adds the conversion character B<F> with C99 semantics, and the "
8952 "flag character B<I>."
8953 msgstr ""
8954 "glibc 2.2 では、 C99 で規定された意味での変換文字 B<F> と フラグ文字 B<I> が"
8955 "追加された。"
8956
8957 #. type: Plain text
8958 #: build/C/man3/printf.3:869
8959 msgid "Some programs imprudently rely on code such as the following"
8960 msgstr ""
8961 "テキストを I<buf> に追加するのに、軽率にも次のようなコードを使っているプログ"
8962 "ラムがある。"
8963
8964 #. type: Plain text
8965 #: build/C/man3/printf.3:871
8966 #, no-wrap
8967 msgid "    sprintf(buf, \"%s some further text\", buf);\n"
8968 msgstr "    sprintf(buf, \"%s some further text\", buf);\n"
8969
8970 #.  http://sourceware.org/bugzilla/show_bug.cgi?id=7075
8971 #. type: Plain text
8972 #: build/C/man3/printf.3:887
8973 msgid ""
8974 "to append text to I<buf>.  However, the standards explicitly note that the "
8975 "results are undefined if source and destination buffers overlap when calling "
8976 "B<sprintf>(), B<snprintf>(), B<vsprintf>(), and B<vsnprintf>().  Depending "
8977 "on the version of B<gcc>(1)  used, and the compiler options employed, calls "
8978 "such as the above will B<not> produce the expected results."
8979 msgstr ""
8980 "しかしながら、標準規格では、 B<sprintf>(), B<snprintf>(), B<vsprintf>(), "
8981 "B<vsnprintf>()  の呼び出しにおいて、コピー元とコピー先のバッファが重なってい"
8982 "た場合の 結果は不定である、と明記されている。 使用する B<gcc>(1)  のバージョ"
8983 "ンや指定したコンパイラのオプション次第では、 上記のような呼び出しで、期待した"
8984 "結果が得られ「ない」ことがある。"
8985
8986 #.  .SH HISTORY
8987 #.  UNIX V7 defines the three routines
8988 #.  .BR printf (),
8989 #.  .BR fprintf (),
8990 #.  .BR sprintf (),
8991 #.  and has the flag \-, the width or precision *, the length modifier l,
8992 #.  and the conversions doxfegcsu, and also D,O,U,X as synonyms for ld,lo,lu,lx.
8993 #.  This is still true for 2.9.1BSD, but 2.10BSD has the flags
8994 #.  #, + and <space> and no longer mentions D,O,U,X.
8995 #.  2.11BSD has
8996 #.  .BR vprintf (),
8997 #.  .BR vfprintf (),
8998 #.  .BR vsprintf (),
8999 #.  and warns not to use D,O,U,X.
9000 #.  4.3BSD Reno has the flag 0, the length modifiers h and L,
9001 #.  and the conversions n, p, E, G, X (with current meaning)
9002 #.  and deprecates D,O,U.
9003 #.  4.4BSD introduces the functions
9004 #.  .BR snprintf ()
9005 #.  and
9006 #.  .BR vsnprintf (),
9007 #.  and the length modifier q.
9008 #.  FreeBSD also has functions
9009 #.  .BR asprintf ()
9010 #.  and
9011 #.  .BR vasprintf (),
9012 #.  that allocate a buffer large enough for
9013 #.  .BR sprintf ().
9014 #.  In glibc there are functions
9015 #.  .BR dprintf ()
9016 #.  and
9017 #.  .BR vdprintf ()
9018 #.  that print to a file descriptor instead of a stream.
9019 #. type: Plain text
9020 #: build/C/man3/printf.3:929
9021 msgid ""
9022 "The glibc implementation of the functions B<snprintf>()  and B<vsnprintf>()  "
9023 "conforms to the C99 standard, that is, behaves as described above, since "
9024 "glibc version 2.1.  Until glibc 2.0.6 they would return -1 when the output "
9025 "was truncated."
9026 msgstr ""
9027 "glibc の B<snprintf>()  と B<vsnprintf>()  の実装は、バージョン 2.1 以降は "
9028 "C99 標準に準拠しており、 上記の通りの動作をする。 glibc 2.0.6 までは、出力が"
9029 "切り詰められた場合は -1 を返す。"
9030
9031 #. type: Plain text
9032 #: build/C/man3/printf.3:946
9033 msgid ""
9034 "Because B<sprintf>()  and B<vsprintf>()  assume an arbitrarily long string, "
9035 "callers must be careful not to overflow the actual space; this is often "
9036 "impossible to assure.  Note that the length of the strings produced is "
9037 "locale-dependent and difficult to predict.  Use B<snprintf>()  and "
9038 "B<vsnprintf>()  instead (or B<asprintf>(3)  and B<vasprintf>(3))."
9039 msgstr ""
9040 "B<sprintf>()  と B<vsprintf>()  は勝手に十分に長い文字列領域があると仮定する"
9041 "ので、呼び出し側は 実際の領域からあふれないように注意しなければならない。 し"
9042 "かし、これを保証することが不可能な場合が多い。 生成される文字列の長さはロケー"
9043 "ル依存であり、予測が難しいことに注意。 代わりに B<snprintf>()  と "
9044 "B<vsnprintf>()  (または B<asprintf>(3)  と B<vasprintf>(3))  を使うこと。"
9045
9046 #. type: Plain text
9047 #: build/C/man3/printf.3:959
9048 msgid ""
9049 "Linux libc4.[45] does not have a B<snprintf>(), but provides a libbsd that "
9050 "contains an B<snprintf>()  equivalent to B<sprintf>(), that is, one that "
9051 "ignores the I<size> argument.  Thus, the use of B<snprintf>()  with early "
9052 "libc4 leads to serious security problems."
9053 msgstr ""
9054 "Linux libc4.[45] には B<snprintf>()  はないが、 libbsd が提供されており、 そ"
9055 "の中には B<sprintf>()  と等価な (つまり I<size> 引き数を無視する)  "
9056 "B<snprintf>()  がある。 したがって、初期の libc4 で B<snprintf>()  を使うと、"
9057 "深刻なセキュリティ問題を引き起こすことがある。"
9058
9059 #.  .PP
9060 #.  Some floating-point conversions under early libc4
9061 #.  caused memory leaks.
9062 #. type: Plain text
9063 #: build/C/man3/printf.3:973
9064 msgid ""
9065 "Code such as B<printf(>I<foo>B<);> often indicates a bug, since I<foo> may "
9066 "contain a % character.  If I<foo> comes from untrusted user input, it may "
9067 "contain B<%n>, causing the B<printf>()  call to write to memory and creating "
9068 "a security hole."
9069 msgstr ""
9070 "B<printf(>I<foo>B<);> のようなコードはしばしばバグを引き起こす。 なぜなら "
9071 "I<foo> に % 文字が含まれてるかもしれないからである。 I<foo> が信頼できない"
9072 "ユーザー入力から作られている場合には、 その中に B<%n> が含まれていることがあ"
9073 "り、 B<printf>()  呼び出し時にメモリへの書き込みが起こり、 セキュリティーホー"
9074 "ルを作ることになるかもしれない。"
9075
9076 #. type: Plain text
9077 #: build/C/man3/printf.3:977
9078 msgid "To print I<Pi> to five decimal places:"
9079 msgstr "I<Pi> を 5 桁で出力する。"
9080
9081 #. type: Plain text
9082 #: build/C/man3/printf.3:983
9083 #, no-wrap
9084 msgid ""
9085 "#include E<lt>math.hE<gt>\n"
9086 "#include E<lt>stdio.hE<gt>\n"
9087 "fprintf(stdout, \"pi = %.5f\\en\", 4 * atan(1.0));\n"
9088 msgstr ""
9089 "#include E<lt>math.hE<gt>\n"
9090 "#include E<lt>stdio.hE<gt>\n"
9091 "fprintf(stdout, \"pi = %.5f\\en\", 4 * atan(1.0));\n"
9092
9093 #. type: Plain text
9094 #: build/C/man3/printf.3:992
9095 msgid ""
9096 "To print a date and time in the form \"Sunday, July 3, 10:02\", where "
9097 "I<weekday> and I<month> are pointers to strings:"
9098 msgstr ""
9099 "日付と時間を \"Sunday, July 3, 10:02\" の形式で出力する。 (I<weekday> と "
9100 "I<month> は文字列へのポインタである)"
9101
9102 #. type: Plain text
9103 #: build/C/man3/printf.3:998
9104 #, no-wrap
9105 msgid ""
9106 "#include E<lt>stdio.hE<gt>\n"
9107 "fprintf(stdout, \"%s, %s %d, %.2d:%.2d\\en\",\n"
9108 "        weekday, month, day, hour, min);\n"
9109 msgstr ""
9110 "#include E<lt>stdio.hE<gt>\n"
9111 "fprintf(stdout, \"%s, %s %d, %.2d:%.2d\\en\",\n"
9112 "\tweekday, month, day, hour, min);\n"
9113
9114 #. type: Plain text
9115 #: build/C/man3/printf.3:1004
9116 msgid ""
9117 "Many countries use the day-month-year order.  Hence, an internationalized "
9118 "version must be able to print the arguments in an order specified by the "
9119 "format:"
9120 msgstr ""
9121 "日 - 月 - 年 の順序で表示を行う国も多い。 従って、国際版では書式で指定された"
9122 "順番で 引き数を表示できなければならない。"
9123
9124 #. type: Plain text
9125 #: build/C/man3/printf.3:1010
9126 #, no-wrap
9127 msgid ""
9128 "#include E<lt>stdio.hE<gt>\n"
9129 "fprintf(stdout, format,\n"
9130 "        weekday, month, day, hour, min);\n"
9131 msgstr ""
9132 "#include E<lt>stdio.hE<gt>\n"
9133 "fprintf(stdout, format,\n"
9134 "\tweekday, month, day, hour, min);\n"
9135
9136 #. type: Plain text
9137 #: build/C/man3/printf.3:1017
9138 msgid ""
9139 "where I<format> depends on locale, and may permute the arguments.  With the "
9140 "value:"
9141 msgstr ""
9142 "I<format> はロケールに依存しており、引き数の順番を変えることもできる。 "
9143 "I<format> が"
9144
9145 #. type: Plain text
9146 #: build/C/man3/printf.3:1021
9147 #, no-wrap
9148 msgid "\"%1$s, %3$d. %2$s, %4$d:%5$.2d\\en\"\n"
9149 msgstr "\"%1$s, %3$d. %2$s, %4$d:%5$.2d\\en\"\n"
9150
9151 #. type: Plain text
9152 #: build/C/man3/printf.3:1025
9153 msgid "one might obtain \"Sonntag, 3. Juli, 10:02\"."
9154 msgstr "であれば、 \"Sonntag, 3. Juli, 10:02\" という結果になる。"
9155
9156 #. type: Plain text
9157 #: build/C/man3/printf.3:1028
9158 msgid ""
9159 "To allocate a sufficiently large string and print into it (code correct for "
9160 "both glibc 2.0 and glibc 2.1):"
9161 msgstr ""
9162 "十分に大きな文字列領域を確保して、そこにメッセージを格納するには (glibc 2.0 "
9163 "と glibc 2.1 の両方で正しく動作するコード):"
9164
9165 #. type: Plain text
9166 #: build/C/man3/printf.3:1031
9167 msgid ""
9168 "If truncation occurs in glibc versions prior to 2.0.6, this is treated as an "
9169 "error instead of being handled gracefully."
9170 msgstr ""
9171 "バージョン 2.0.6 より前の glibc で切り詰めが起こった場合、切り詰めは適切に処"
9172 "理されず、エラーとして扱われる。"
9173
9174 #. type: Plain text
9175 #: build/C/man3/printf.3:1036
9176 #, no-wrap
9177 msgid ""
9178 "#include E<lt>stdio.hE<gt>\n"
9179 "#include E<lt>stdlib.hE<gt>\n"
9180 "#include E<lt>stdarg.hE<gt>\n"
9181 msgstr ""
9182 "#include E<lt>stdio.hE<gt>\n"
9183 "#include E<lt>stdlib.hE<gt>\n"
9184 "#include E<lt>stdarg.hE<gt>\n"
9185
9186 #. type: Plain text
9187 #: build/C/man3/printf.3:1044
9188 #, no-wrap
9189 msgid ""
9190 "char *\n"
9191 "make_message(const char *fmt, ...)\n"
9192 "{\n"
9193 "    int n;\n"
9194 "    int size = 100;     /* Guess we need no more than 100 bytes */\n"
9195 "    char *p, *np;\n"
9196 "    va_list ap;\n"
9197 msgstr ""
9198 "char *\n"
9199 "make_message(const char *fmt, ...)\n"
9200 "{\n"
9201 "    int n;\n"
9202 "    int size = 100;     /* Guess we need no more than 100 bytes */\n"
9203 "    char *p, *np;\n"
9204 "    va_list ap;\n"
9205
9206 #. type: Plain text
9207 #: build/C/man3/printf.3:1047
9208 #, no-wrap
9209 msgid ""
9210 "    if ((p = malloc(size)) == NULL)\n"
9211 "        return NULL;\n"
9212 msgstr ""
9213 "    if ((p = malloc(size)) == NULL)\n"
9214 "        return NULL;\n"
9215
9216 #. type: Plain text
9217 #: build/C/man3/printf.3:1049
9218 #, no-wrap
9219 msgid "    while (1) {\n"
9220 msgstr "    while (1) {\n"
9221
9222 #. type: Plain text
9223 #: build/C/man3/printf.3:1051
9224 #, no-wrap
9225 msgid "        /* Try to print in the allocated space */\n"
9226 msgstr "        /* Try to print in the allocated space */\n"
9227
9228 #. type: Plain text
9229 #: build/C/man3/printf.3:1055
9230 #, no-wrap
9231 msgid ""
9232 "        va_start(ap, fmt);\n"
9233 "        n = vsnprintf(p, size, fmt, ap);\n"
9234 "        va_end(ap);\n"
9235 msgstr ""
9236 "        va_start(ap, fmt);\n"
9237 "        n = vsnprintf(p, size, fmt, ap);\n"
9238 "        va_end(ap);\n"
9239
9240 #. type: Plain text
9241 #: build/C/man3/printf.3:1057
9242 #, no-wrap
9243 msgid "        /* Check error code */\n"
9244 msgstr "        /* Check error code */\n"
9245
9246 #. type: Plain text
9247 #: build/C/man3/printf.3:1060
9248 #, no-wrap
9249 msgid ""
9250 "        if (n E<lt> 0)\n"
9251 "            return NULL;\n"
9252 msgstr ""
9253 "        if (n E<lt> 0)\n"
9254 "            return NULL;\n"
9255
9256 #. type: Plain text
9257 #: build/C/man3/printf.3:1062
9258 #, no-wrap
9259 msgid "        /* If that worked, return the string */\n"
9260 msgstr "        /* If that worked, return the string */\n"
9261
9262 #. type: Plain text
9263 #: build/C/man3/printf.3:1065
9264 #, no-wrap
9265 msgid ""
9266 "        if (n E<lt> size)\n"
9267 "            return p;\n"
9268 msgstr ""
9269 "        if (n E<lt> size)\n"
9270 "            return p;\n"
9271
9272 #. type: Plain text
9273 #: build/C/man3/printf.3:1067
9274 #, no-wrap
9275 msgid "        /* Else try again with more space */\n"
9276 msgstr "        /* Else try again with more space */\n"
9277
9278 #. type: Plain text
9279 #: build/C/man3/printf.3:1069
9280 #, no-wrap
9281 msgid "        size = n + 1;       /* Precisely what is needed */\n"
9282 msgstr "        size = n + 1;       /* Precisely what is needed */\n"
9283
9284 #. type: Plain text
9285 #: build/C/man3/printf.3:1079
9286 #, no-wrap
9287 msgid ""
9288 "        if ((np = realloc (p, size)) == NULL) {\n"
9289 "            free(p);\n"
9290 "            return NULL;\n"
9291 "        } else {\n"
9292 "            p = np;\n"
9293 "        }\n"
9294 "    }\n"
9295 "}\n"
9296 msgstr ""
9297 "        if ((np = realloc (p, size)) == NULL) {\n"
9298 "            free(p);\n"
9299 "            return NULL;\n"
9300 "        } else {\n"
9301 "            p = np;\n"
9302 "        }\n"
9303 "    }\n"
9304 "}\n"
9305
9306 #. type: Plain text
9307 #: build/C/man3/printf.3:1089
9308 msgid ""
9309 "B<printf>(1), B<asprintf>(3), B<dprintf>(3), B<scanf>(3), B<setlocale>(3), "
9310 "B<wcrtomb>(3), B<wprintf>(3), B<locale>(5)"
9311 msgstr ""
9312 "B<printf>(1), B<asprintf>(3), B<dprintf>(3), B<scanf>(3), B<setlocale>(3), "
9313 "B<wcrtomb>(3), B<wprintf>(3), B<locale>(5)"
9314
9315 #. type: TH
9316 #: build/C/man3/puts.3:26
9317 #, no-wrap
9318 msgid "PUTS"
9319 msgstr "PUTS"
9320
9321 #. type: TH
9322 #: build/C/man3/puts.3:26
9323 #, no-wrap
9324 msgid "2011-09-28"
9325 msgstr "2011-09-28"
9326
9327 #. type: Plain text
9328 #: build/C/man3/puts.3:29
9329 msgid "fputc, fputs, putc, putchar, puts - output of characters and strings"
9330 msgstr "fputc, fputs, putc, putchar, puts - 文字と文字列の出力"
9331
9332 #. type: Plain text
9333 #: build/C/man3/puts.3:34
9334 #, no-wrap
9335 msgid "B<int fputc(int >I<c>B<, FILE *>I<stream>B<);>\n"
9336 msgstr "B<int fputc(int >I<c>B<, FILE *>I<stream>B<);>\n"
9337
9338 #. type: Plain text
9339 #: build/C/man3/puts.3:36
9340 #, no-wrap
9341 msgid "B<int fputs(const char *>I<s>B<, FILE *>I<stream>B<);>\n"
9342 msgstr "B<int fputs(const char *>I<s>B<, FILE *>I<stream>B<);>\n"
9343
9344 #. type: Plain text
9345 #: build/C/man3/puts.3:38
9346 #, no-wrap
9347 msgid "B<int putc(int >I<c>B<, FILE *>I<stream>B<);>\n"
9348 msgstr "B<int putc(int >I<c>B<, FILE *>I<stream>B<);>\n"
9349
9350 #. type: Plain text
9351 #: build/C/man3/puts.3:40
9352 #, no-wrap
9353 msgid "B<int putchar(int >I<c>B<);>\n"
9354 msgstr "B<int putchar(int >I<c>B<);>\n"
9355
9356 #. type: Plain text
9357 #: build/C/man3/puts.3:42
9358 #, no-wrap
9359 msgid "B<int puts(const char *>I<s>B<);>\n"
9360 msgstr "B<int puts(const char *>I<s>B<);>\n"
9361
9362 #. type: Plain text
9363 #: build/C/man3/puts.3:51
9364 msgid ""
9365 "B<fputc>()  writes the character I<c>, cast to an I<unsigned char>, to "
9366 "I<stream>."
9367 msgstr ""
9368 "B<fputc>()  は、キャラクタ I<c> を I<unsigned char> にキャストし、 I<stream> "
9369 "に書き込む。"
9370
9371 #. type: Plain text
9372 #: build/C/man3/puts.3:58
9373 msgid ""
9374 "B<fputs>()  writes the string I<s> to I<stream>, without its terminating "
9375 "null byte (\\(aq\\e0\\(aq)."
9376 msgstr ""
9377 "B<fputs>()  は、文字列 I<s> を I<stream> に書き込む。 文字列終端の NULL バイ"
9378 "ト (\\(aq\\e0\\(aq) は出力しない。"
9379
9380 #. type: Plain text
9381 #: build/C/man3/puts.3:65
9382 msgid ""
9383 "B<putc>()  is equivalent to B<fputc>()  except that it may be implemented as "
9384 "a macro which evaluates I<stream> more than once."
9385 msgstr ""
9386 "B<putc>()  は、 I<stream> を一度以上評価するマクロとして実装されているかも知"
9387 "れないという点を除き、 B<fputc>()  と同じである。"
9388
9389 #. type: Plain text
9390 #: build/C/man3/puts.3:69
9391 msgid "B<putchar(>I<c>B<);> is equivalent to B<putc(>I<c>B<,>I<stdout>B<).>"
9392 msgstr "B<putchar(>I<c>B<);> は、 B<putc(>I<c>B<,>I<stdout>B<)> と同じである。"
9393
9394 #. type: Plain text
9395 #: build/C/man3/puts.3:76
9396 msgid "B<puts>()  writes the string I<s> and a trailing newline to I<stdout>."
9397 msgstr "B<puts>()  は、文字列 I<s> と改行を I<stdout> に書き込む。"
9398
9399 #. type: Plain text
9400 #: build/C/man3/puts.3:81
9401 msgid ""
9402 "Calls to the functions described here can be mixed with each other and with "
9403 "calls to other output functions from the I<stdio> library for the same "
9404 "output stream."
9405 msgstr ""
9406 "ここで説明された関数はお互いに混在して使用することができ、また、 I<stdio> ラ"
9407 "イブラリに含まれる他の出力関数を同じ出力ストリームに対して 呼び出す事が出来"
9408 "る。"
9409
9410 #. type: Plain text
9411 #: build/C/man3/puts.3:96
9412 msgid ""
9413 "B<fputc>(), B<putc>()  and B<putchar>()  return the character written as an "
9414 "I<unsigned char> cast to an I<int> or B<EOF> on error."
9415 msgstr ""
9416 "B<fputc>(), B<putc>(), B<putchar>()  は I<unsigned char> として書き込まれた文"
9417 "字を I<int> にキャストして返す。 エラーが発生した場合は B<EOF> を返す。"
9418
9419 #. type: Plain text
9420 #: build/C/man3/puts.3:103
9421 msgid ""
9422 "B<puts>()  and B<fputs>()  return a nonnegative number on success, or B<EOF> "
9423 "on error."
9424 msgstr ""
9425 "B<puts>()  と B<fputs>()  は、成功すると負ではない数を、エラーが発生した場合"
9426 "は B<EOF> を返す。"
9427
9428 #. type: Plain text
9429 #: build/C/man3/puts.3:112
9430 msgid ""
9431 "It is not advisable to mix calls to output functions from the I<stdio> "
9432 "library with low-level calls to B<write>(2)  for the file descriptor "
9433 "associated with the same output stream; the results will be undefined and "
9434 "very probably not what you want."
9435 msgstr ""
9436 "I<stdio> ライブラリに含まれる出力関数と、同じ出力ストリームに結びつけられた "
9437 "ファイルディスクリプタに対する B<write>(2)  の低レベル呼び出しを混在して 使用"
9438 "することは賢明ではない。 その結果は定義されておらず、望む結果が得られない可能"
9439 "性が高い。"
9440
9441 #. type: Plain text
9442 #: build/C/man3/puts.3:124
9443 msgid ""
9444 "B<write>(2), B<ferror>(3), B<fopen>(3), B<fputwc>(3), B<fputws>(3), B<fseek>"
9445 "(3), B<fwrite>(3), B<gets>(3), B<putwchar>(3), B<scanf>(3), B<unlocked_stdio>"
9446 "(3)"
9447 msgstr ""
9448 "B<write>(2), B<ferror>(3), B<fopen>(3), B<fputwc>(3), B<fputws>(3), B<fseek>"
9449 "(3), B<fwrite>(3), B<gets>(3), B<putwchar>(3), B<scanf>(3), B<unlocked_stdio>"
9450 "(3)"
9451
9452 #. type: TH
9453 #: build/C/man2/read.2:35
9454 #, no-wrap
9455 msgid "READ"
9456 msgstr "READ"
9457
9458 #. type: TH
9459 #: build/C/man2/read.2:35
9460 #, no-wrap
9461 msgid "2013-02-12"
9462 msgstr "2013-02-12"
9463
9464 #. type: Plain text
9465 #: build/C/man2/read.2:38
9466 msgid "read - read from a file descriptor"
9467 msgstr "read - ファイルディスクリプタから読み込む"
9468
9469 #. type: Plain text
9470 #: build/C/man2/read.2:43
9471 #, no-wrap
9472 msgid "B<ssize_t read(int >I<fd>B<, void *>I<buf>B<, size_t >I<count>B<);>\n"
9473 msgstr "B<ssize_t read(int >I<fd>B<, void *>I<buf>B<, size_t >I<count>B<);>\n"
9474
9475 #. type: Plain text
9476 #: build/C/man2/read.2:52
9477 msgid ""
9478 "B<read>()  attempts to read up to I<count> bytes from file descriptor I<fd> "
9479 "into the buffer starting at I<buf>."
9480 msgstr ""
9481 "B<read>()  はファイルディスクリプタ (file descriptor)  I<fd> から最大 "
9482 "I<count> バイトを I<buf> で始まるバッファーへ読み込もうとする。"
9483
9484 #. type: Plain text
9485 #: build/C/man2/read.2:60
9486 msgid ""
9487 "On files that support seeking, the read operation commences at the current "
9488 "file offset, and the file offset is incremented by the number of bytes "
9489 "read.  If the current file offset is at or past the end of file, no bytes "
9490 "are read, and B<read>()  returns zero."
9491 msgstr ""
9492 "seek に対応しているファイルでは、read は現在のファイルオフセットから行われ、"
9493 "ファイルオフセットは読み込んだバイト数分だけ進められる。現在のファイルオフ"
9494 "セットがファイル末尾かそれより先の場合は、読み出しは行われず、 B<read>() は "
9495 "0 を返す。"
9496
9497 #. type: Plain text
9498 #: build/C/man2/read.2:75
9499 msgid ""
9500 "If I<count> is zero, B<read>()  I<may> detect the errors described below.  "
9501 "In the absence of any errors, or if B<read>()  does not check for errors, a "
9502 "B<read>()  with a I<count> of 0 returns zero and has no other effects."
9503 msgstr ""
9504 "I<count> が 0 の場合、 B<read>() は以下で説明するエラーを検出するI<場合がある"
9505 ">。 どのエラーもなかった場合、もしくは B<read>() がエラーのチェックを行わない"
9506 "場合、 I<count> が 0 で呼び出された B<read>() は 0 を返し、何も行わない。"
9507
9508 #. type: Plain text
9509 #: build/C/man2/read.2:81
9510 msgid "If I<count> is greater than B<SSIZE_MAX>, the result is unspecified."
9511 msgstr "I<count> が B<SSIZE_MAX> より大きければ、結果は規定できない。"
9512
9513 #. type: Plain text
9514 #: build/C/man2/read.2:95
9515 msgid ""
9516 "On success, the number of bytes read is returned (zero indicates end of "
9517 "file), and the file position is advanced by this number.  It is not an error "
9518 "if this number is smaller than the number of bytes requested; this may "
9519 "happen for example because fewer bytes are actually available right now "
9520 "(maybe because we were close to end-of-file, or because we are reading from "
9521 "a pipe, or from a terminal), or because B<read>()  was interrupted by a "
9522 "signal.  On error, -1 is returned, and I<errno> is set appropriately.  In "
9523 "this case it is left unspecified whether the file position (if any) changes."
9524 msgstr ""
9525 "成功した場合、読み込んだバイト数を返す (0 はファイルの終りを意味する)。 ファ"
9526 "イル位置はこの数だけ進められる。 この数が要求した数より小さかったとしてもエ"
9527 "ラーではない; 例えば今すぐには実際にそれだけの数しかない場合 (ファイルの最後"
9528 "に近いのかも しれないし、パイプ (pipe) や端末 (terminal) から読み込んでいるか"
9529 "もしれない) や B<read>()  がシグナル (signal) によって割り込まれた場合にこれ"
9530 "は起こりえる。 エラーの場合は、-1 が返され、 I<errno> が適切に設定される。こ"
9531 "の場合はファイル位置が変更されるかどうかは 不定である。"
9532
9533 #. type: TP
9534 #: build/C/man2/read.2:96 build/C/man3/scanf.3:548 build/C/man2/write.2:108
9535 #, no-wrap
9536 msgid "B<EAGAIN>"
9537 msgstr "B<EAGAIN>"
9538
9539 #. type: Plain text
9540 #: build/C/man2/read.2:103
9541 msgid ""
9542 "The file descriptor I<fd> refers to a file other than a socket and has been "
9543 "marked nonblocking (B<O_NONBLOCK>), and the read would block."
9544 msgstr ""
9545 "ファイルディスクリプタ I<fd> がソケット以外のファイルを参照していて、 非停止 "
9546 "(nonblocking) モード (B<O_NONBLOCK>)  に設定されており、読み込みを行うと停止"
9547 "する状況にある。"
9548
9549 #. type: TP
9550 #: build/C/man2/read.2:103 build/C/man2/write.2:115
9551 #, no-wrap
9552 msgid "B<EAGAIN> or B<EWOULDBLOCK>"
9553 msgstr "B<EAGAIN> または B<EWOULDBLOCK>"
9554
9555 #.  Actually EAGAIN on Linux
9556 #. type: Plain text
9557 #: build/C/man2/read.2:114
9558 msgid ""
9559 "The file descriptor I<fd> refers to a socket and has been marked nonblocking "
9560 "(B<O_NONBLOCK>), and the read would block.  POSIX.1-2001 allows either error "
9561 "to be returned for this case, and does not require these constants to have "
9562 "the same value, so a portable application should check for both "
9563 "possibilities."
9564 msgstr ""
9565 "ファイルディスクリプタ I<fd> がソケットを参照していて、非停止 (nonblocking) "
9566 "モード (B<O_NONBLOCK>)  に設定されており、読み込みを行うと停止する状況にあ"
9567 "る。 POSIX.1-2001 は、この場合にどちらのエラーを返すことも認めており、 これ"
9568 "ら 2 つの定数が同じ値を持つことも求めていない。 したがって、移植性が必要なア"
9569 "プリケーションでは、両方の可能性を 確認すべきである。"
9570
9571 #. type: Plain text
9572 #: build/C/man2/read.2:118
9573 msgid "I<fd> is not a valid file descriptor or is not open for reading."
9574 msgstr ""
9575 "I<fd> が有効なファイルディスクリプタでないか、読み込みのために オープン "
9576 "(open) されていない。"
9577
9578 #. type: Plain text
9579 #: build/C/man2/read.2:122 build/C/man2/write.2:145
9580 msgid "I<buf> is outside your accessible address space."
9581 msgstr "I<buf> がアクセス可能なアドレス空間の外にある。"
9582
9583 #. type: Plain text
9584 #: build/C/man2/read.2:126
9585 msgid ""
9586 "The call was interrupted by a signal before any data was read; see B<signal>"
9587 "(7)."
9588 msgstr ""
9589 "何のデータも読み込まないうちにシグナルに割り込まれた。 B<signal>(7)  参照。"
9590
9591 #. type: Plain text
9592 #: build/C/man2/read.2:137
9593 msgid ""
9594 "I<fd> is attached to an object which is unsuitable for reading; or the file "
9595 "was opened with the B<O_DIRECT> flag, and either the address specified in "
9596 "I<buf>, the value specified in I<count>, or the current file offset is not "
9597 "suitably aligned."
9598 msgstr ""
9599 "I<fd> は読み込みに適していないオブジェクトを参照している。 もしくは、ファイル"
9600 "が B<O_DIRECT> フラグを指定してオープンされているが、 I<buf> に指定されたアド"
9601 "レス、 I<count> に指定された値、 現在のファイルオフセットのいずれかの アライ"
9602 "ンメントが不適切である。"
9603
9604 #. type: Plain text
9605 #: build/C/man2/read.2:147
9606 msgid ""
9607 "I<fd> was created via a call to B<timerfd_create>(2)  and the wrong size "
9608 "buffer was given to B<read>(); see B<timerfd_create>(2)  for further "
9609 "information."
9610 msgstr ""
9611 "I<fd> が B<timerfd_create>(2)  の呼び出しで作成されたが、 B<read>()  に間違っ"
9612 "たサイズのバッファが渡された。 さらなる情報は B<timerfd_create>(2)  を参照の"
9613 "こと。"
9614
9615 #. type: Plain text
9616 #: build/C/man2/read.2:158
9617 msgid ""
9618 "I/O error.  This will happen for example when the process is in a background "
9619 "process group, tries to read from its controlling terminal, and either it is "
9620 "ignoring or blocking B<SIGTTIN> or its process group is orphaned.  It may "
9621 "also occur when there is a low-level I/O error while reading from a disk or "
9622 "tape."
9623 msgstr ""
9624 "I/O エラー。これは例えばプロセスがバックグランド・プロセスグループで、それを"
9625 "制御している端末から読み込もうとし、 B<SIGTTIN> が無視 (ignore) または禁止 "
9626 "(blocking) されている場合や、 そのプロセスグループが孤立 (orphan) している場"
9627 "合に起こる。 またディスクやテープを読んでいる時に低レベル I/O エラー が発生し"
9628 "た場合にも起こる。"
9629
9630 #. type: Plain text
9631 #: build/C/man2/read.2:162
9632 msgid "I<fd> refers to a directory."
9633 msgstr "I<fd> がディレクトリを参照している。"
9634
9635 #. type: Plain text
9636 #: build/C/man2/read.2:173
9637 msgid ""
9638 "Other errors may occur, depending on the object connected to I<fd>.  POSIX "
9639 "allows a B<read>()  that is interrupted after reading some data to return -1 "
9640 "(with I<errno> set to B<EINTR>)  or to return the number of bytes already "
9641 "read."
9642 msgstr ""
9643 "I<fd> が接続しているオブジェクトによっては他のエラーも起こりえる。 POSIX で"
9644 "は、 いくらかのデータを読んだ後に割り込みが起こった場合、 B<read>()  は "
9645 "(I<errno> に B<EINTR> を設定して) -1 を返してもよいし、 既に読み込んだバイト"
9646 "数を返してもよい。"
9647
9648 #. type: Plain text
9649 #: build/C/man2/read.2:187
9650 msgid ""
9651 "On NFS file systems, reading small amounts of data will update the timestamp "
9652 "only the first time, subsequent calls may not do so.  This is caused by "
9653 "client side attribute caching, because most if not all NFS clients leave "
9654 "st_atime (last file access time)  updates to the server and client side "
9655 "reads satisfied from the client's cache will not cause st_atime updates on "
9656 "the server as there are no server side reads.  UNIX semantics can be "
9657 "obtained by disabling client side attribute caching, but in most situations "
9658 "this will substantially increase server load and decrease performance."
9659 msgstr ""
9660 "NFS において。少量のデータを読み込む場合、最初の時のみにタイム スタンプが更新"
9661 "され、続くコールでは更新されないだろう。 これはクライアント側で属性のキャッシ"
9662 "ングを行なうためである。 なぜならば、もし全ての NFS クライアントが st_atime "
9663 "(最終ファイルアクセス時刻)  の更新をサーバーに送らず、クライアント側でキャッ"
9664 "シュを読むことに満足して いれば、サーバー側での read は発生しないので "
9665 "st_atime の更新は行なわれからだ。 UNIX の方式では、クライアント側の属性の"
9666 "キャッシングを無効にすることで、 これを得ることができる。しかしほとんどの状況"
9667 "ではこれは続くサーバーの 負荷を増加させ、パフォーマンスの低下をもたらす。"
9668
9669 #. type: Plain text
9670 #: build/C/man2/read.2:200
9671 msgid ""
9672 "B<close>(2), B<fcntl>(2), B<ioctl>(2), B<lseek>(2), B<open>(2), B<pread>(2), "
9673 "B<readdir>(2), B<readlink>(2), B<readv>(2), B<select>(2), B<write>(2), "
9674 "B<fread>(3)"
9675 msgstr ""
9676 "B<close>(2), B<fcntl>(2), B<ioctl>(2), B<lseek>(2), B<open>(2), B<pread>(2), "
9677 "B<readdir>(2), B<readlink>(2), B<readv>(2), B<select>(2), B<write>(2), "
9678 "B<fread>(3)"
9679
9680 #. type: TH
9681 #: build/C/man2/readlink.2:43
9682 #, no-wrap
9683 msgid "READLINK"
9684 msgstr "READLINK"
9685
9686 #. type: TH
9687 #: build/C/man2/readlink.2:43
9688 #, no-wrap
9689 msgid "2011-09-20"
9690 msgstr "2011-09-20"
9691
9692 #. type: Plain text
9693 #: build/C/man2/readlink.2:46
9694 msgid "readlink - read value of a symbolic link"
9695 msgstr "readlink - シンボリックリンクの値を読む"
9696
9697 #. type: Plain text
9698 #: build/C/man2/readlink.2:50
9699 msgid ""
9700 "B<ssize_t readlink(const char *>I<path>B<, char *>I<buf>B<, size_t "
9701 ">I<bufsiz>B<);>"
9702 msgstr ""
9703 "B<ssize_t readlink(const char *>I<path>B<, char *>I<buf>B<, size_t "
9704 ">I<bufsiz>B<);>"
9705
9706 #. type: Plain text
9707 #: build/C/man2/readlink.2:58
9708 msgid "B<readlink>():"
9709 msgstr "B<readlink>():"
9710
9711 #. type: Plain text
9712 #: build/C/man2/readlink.2:61 build/C/man2/symlink.2:50
9713 msgid ""
9714 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
9715 "_XOPEN_SOURCE_EXTENDED || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
9716 msgstr ""
9717 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
9718 "_XOPEN_SOURCE_EXTENDED || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
9719
9720 #. type: Plain text
9721 #: build/C/man2/readlink.2:77
9722 msgid ""
9723 "B<readlink>()  places the contents of the symbolic link I<path> in the "
9724 "buffer I<buf>, which has size I<bufsiz>.  B<readlink>()  does not append a "
9725 "null byte to I<buf>.  It will truncate the contents (to a length of "
9726 "I<bufsiz> characters), in case the buffer is too small to hold all of the "
9727 "contents."
9728 msgstr ""
9729 "B<readlink>()  は I<path> で与えられたシンボリックリンクの内容を I<buf> バッ"
9730 "ファーへ格納する、 I<buf> のサイズは I<bufsiz> である。 B<readlink>()  は "
9731 "NULL バイトを I<buf> に追加しない。 その内容全てを格納するのにバッファーが小"
9732 "さ過ぎる場合は、 (I<bufsiz> バイトの長さに) 内容を切り詰める。"
9733
9734 #. type: Plain text
9735 #: build/C/man2/readlink.2:85
9736 msgid ""
9737 "On success, B<readlink>()  returns the number of bytes placed in I<buf>.  On "
9738 "error, -1 is returned and I<errno> is set to indicate the error."
9739 msgstr ""
9740 "成功すると、 B<readlink>()  は I<buf> に格納されたバイト数を返す。 エラーの場"
9741 "合、-1 を返し、 I<errno> にエラーを示す値を設定する。"
9742
9743 #. type: Plain text
9744 #: build/C/man2/readlink.2:91
9745 msgid ""
9746 "Search permission is denied for a component of the path prefix.  (See also "
9747 "B<path_resolution>(7).)"
9748 msgstr ""
9749 "パスのディレクトリ部分に検索許可が与えられていない (B<path_resolution>(7)  も"
9750 "参照すること)。"
9751
9752 #. type: Plain text
9753 #: build/C/man2/readlink.2:95
9754 msgid "I<buf> extends outside the process's allocated address space."
9755 msgstr "I<buf> がプロセスに割り当てられたアドレス空間の外を指している。"
9756
9757 #.  At the glibc level, bufsiz is unsigned, so this error can only occur
9758 #.  if bufsiz==0.  However, the in the kernel syscall, bufsiz is signed,
9759 #.  and this error can also occur if bufsiz < 0.
9760 #.  See: http://thread.gmane.org/gmane.linux.man/380
9761 #.  Subject: [patch 0/3] [RFC] kernel/glibc mismatch of "readlink" syscall?
9762 #. type: Plain text
9763 #: build/C/man2/readlink.2:104
9764 msgid "I<bufsiz> is not positive."
9765 msgstr "I<bufsiz> が正でない。"
9766
9767 #. type: Plain text
9768 #: build/C/man2/readlink.2:107
9769 msgid "The named file is not a symbolic link."
9770 msgstr "指定したファイルがシンボリックリンクでない。"
9771
9772 #. type: Plain text
9773 #: build/C/man2/readlink.2:110
9774 msgid "An I/O error occurred while reading from the file system."
9775 msgstr "ファイルシステムの読み込み中に I/O エラーが起こった。"
9776
9777 #. type: Plain text
9778 #: build/C/man2/readlink.2:113
9779 msgid "Too many symbolic links were encountered in translating the pathname."
9780 msgstr "パス名にシンボリックリンクが多すぎる。"
9781
9782 #. type: Plain text
9783 #: build/C/man2/readlink.2:116
9784 msgid "A pathname, or a component of a pathname, was too long."
9785 msgstr "パス名かパス名の一部分が長過ぎる。"
9786
9787 #. type: Plain text
9788 #: build/C/man2/readlink.2:119
9789 msgid "The named file does not exist."
9790 msgstr "その名前のファイルが存在しない。"
9791
9792 #. type: Plain text
9793 #: build/C/man2/readlink.2:125
9794 msgid "A component of the path prefix is not a directory."
9795 msgstr "パスのディレクトリ部分がディレクトリでない。"
9796
9797 #. type: Plain text
9798 #: build/C/man2/readlink.2:130
9799 msgid "4.4BSD (B<readlink>()  first appeared in 4.2BSD), POSIX.1-2001."
9800 msgstr "4.4BSD (B<readlink>()  は 4.2BSD で初めて登場した), POSIX.1-2001."
9801
9802 #. type: Plain text
9803 #: build/C/man2/readlink.2:138
9804 msgid ""
9805 "In versions of glibc up to and including glibc 2.4, the return type of "
9806 "B<readlink>()  was declared as I<int>.  Nowadays, the return type is "
9807 "declared as I<ssize_t>, as (newly) required in POSIX.1-2001."
9808 msgstr ""
9809 "バージョン 2.4 以前の glibc (バージョン 2.4 を含む) では、 B<readlink>()  の"
9810 "返り値の型は I<int> で宣言されていた。現在では、返り値の型は I<ssize_t> であ"
9811 "る (返り値 I<ssize_t> は POSIX.1-2001 で (新たに) 必須となった)。"
9812
9813 #. type: Plain text
9814 #: build/C/man2/readlink.2:157
9815 msgid ""
9816 "Using a statically sized buffer might not provide enough room for the "
9817 "symbolic link contents.  The required size for the buffer can be obtained "
9818 "from the I<stat.st_size> value returned by a call to B<lstat>(2)  on the "
9819 "link.  However, the number of bytes written by B<readlink>()  should be "
9820 "checked to make sure that the size of the symbolic link did not increase "
9821 "between the calls.  Dynamically allocating the buffer for B<readlink>()  "
9822 "also addresses a common portability problem when using I<PATH_MAX> for the "
9823 "buffer size, as this constant is not guaranteed to be defined per POSIX if "
9824 "the system does not have such limit."
9825 msgstr ""
9826 "静的な大きさのバッファを使うと、シンボリックリンクの内容を\n"
9827 "格納するのに十分な領域がない場合がある。\n"
9828 "バッファに必要なサイズは、そのシンボリックリンクに対して B<lstat>(2)\n"
9829 "の呼び出しで返される I<stat.st_size> の値から取得できる。\n"
9830 "ただし、 B<readlink>() が書き込んだバイト数をチェックして、\n"
9831 "シンボリックリンクのサイズが B<lstat>(2) と B<readlink>() の呼び出し\n"
9832 "の間で増えていないことを確認すべきである。\n"
9833 "B<readlink>() 用のバッファを動的に割り当てる方法でも、\n"
9834 "バッファサイズとして I<PATH_MAX> を使用する場合に共通する移植性の\n"
9835 "問題を解決することができる。なぜなら、POSIX では、\n"
9836 "システムがそのような上限値を定義していない場合には、\n"
9837 "I<PATH_MAX> が定義されることが保証されていないからである。"
9838
9839 #. type: Plain text
9840 #: build/C/man2/readlink.2:163
9841 msgid ""
9842 "The following program allocates the buffer needed by B<readlink>()  "
9843 "dynamically from the information provided by B<lstat>(), making sure there's "
9844 "no race condition between the calls."
9845 msgstr ""
9846 "以下のプログラムは、 B<readlink>() が必要とするバッファを、\n"
9847 "B<lstat>() が提供する情報に基づいて動的に割り当てる。\n"
9848 "また、両方の呼び出し間で競合条件がないことを保証している。"
9849
9850 #. type: Plain text
9851 #: build/C/man2/readlink.2:170
9852 #, no-wrap
9853 msgid ""
9854 "#include E<lt>sys/types.hE<gt>\n"
9855 "#include E<lt>sys/stat.hE<gt>\n"
9856 "#include E<lt>stdio.hE<gt>\n"
9857 "#include E<lt>stdlib.hE<gt>\n"
9858 "#include E<lt>unistd.hE<gt>\n"
9859 msgstr ""
9860 "#include E<lt>sys/types.hE<gt>\n"
9861 "#include E<lt>sys/stat.hE<gt>\n"
9862 "#include E<lt>stdio.hE<gt>\n"
9863 "#include E<lt>stdlib.hE<gt>\n"
9864 "#include E<lt>unistd.hE<gt>\n"
9865
9866 #. type: Plain text
9867 #: build/C/man2/readlink.2:177
9868 #, no-wrap
9869 msgid ""
9870 "int\n"
9871 "main(int argc, char *argv[])\n"
9872 "{\n"
9873 "    struct stat sb;\n"
9874 "    char *linkname;\n"
9875 "    ssize_t r;\n"
9876 msgstr ""
9877 "int\n"
9878 "main(int argc, char *argv[])\n"
9879 "{\n"
9880 "    struct stat sb;\n"
9881 "    char *linkname;\n"
9882 "    ssize_t r;\n"
9883
9884 #. type: Plain text
9885 #: build/C/man2/readlink.2:182
9886 #, no-wrap
9887 msgid ""
9888 "    if (argc != 2) {\n"
9889 "        fprintf(stderr, \"Usage: %s E<lt>pathnameE<gt>\\en\", argv[0]);\n"
9890 "        exit(EXIT_FAILURE);\n"
9891 "    }\n"
9892 msgstr ""
9893 "    if (argc != 2) {\n"
9894 "        fprintf(stderr, \"Usage: %s E<lt>pathnameE<gt>\\en\", argv[0]);\n"
9895 "        exit(EXIT_FAILURE);\n"
9896 "    }\n"
9897
9898 #. type: Plain text
9899 #: build/C/man2/readlink.2:187
9900 #, no-wrap
9901 msgid ""
9902 "    if (lstat(argv[1], &sb) == -1) {\n"
9903 "        perror(\"lstat\");\n"
9904 "        exit(EXIT_FAILURE);\n"
9905 "    }\n"
9906 msgstr ""
9907 "    if (lstat(argv[1], &sb) == -1) {\n"
9908 "        perror(\"lstat\");\n"
9909 "        exit(EXIT_FAILURE);\n"
9910 "    }\n"
9911
9912 #. type: Plain text
9913 #: build/C/man2/readlink.2:193
9914 #, no-wrap
9915 msgid ""
9916 "    linkname = malloc(sb.st_size + 1);\n"
9917 "    if (linkname == NULL) {\n"
9918 "        fprintf(stderr, \"insufficient memory\\en\");\n"
9919 "        exit(EXIT_FAILURE);\n"
9920 "    }\n"
9921 msgstr ""
9922 "    linkname = malloc(sb.st_size + 1);\n"
9923 "    if (linkname == NULL) {\n"
9924 "        fprintf(stderr, \"insufficient memory\\en\");\n"
9925 "        exit(EXIT_FAILURE);\n"
9926 "    }\n"
9927
9928 #. type: Plain text
9929 #: build/C/man2/readlink.2:195
9930 #, no-wrap
9931 msgid "    r = readlink(argv[1], linkname, sb.st_size + 1);\n"
9932 msgstr "    r = readlink(argv[1], linkname, sb.st_size + 1);\n"
9933
9934 #. type: Plain text
9935 #: build/C/man2/readlink.2:200
9936 #, no-wrap
9937 msgid ""
9938 "    if (r E<lt> 0) {\n"
9939 "        perror(\"lstat\");\n"
9940 "        exit(EXIT_FAILURE);\n"
9941 "    }\n"
9942 msgstr ""
9943 "    if (r E<lt> 0) {\n"
9944 "        perror(\"lstat\");\n"
9945 "        exit(EXIT_FAILURE);\n"
9946 "    }\n"
9947
9948 #. type: Plain text
9949 #: build/C/man2/readlink.2:206
9950 #, no-wrap
9951 msgid ""
9952 "    if (r E<gt> sb.st_size) {\n"
9953 "        fprintf(stderr, \"symlink increased in size \"\n"
9954 "                        \"between lstat() and readlink()\\en\");\n"
9955 "        exit(EXIT_FAILURE);\n"
9956 "    }\n"
9957 msgstr ""
9958 "    if (r E<gt> sb.st_size) {\n"
9959 "        fprintf(stderr, \"symlink increased in size \"\n"
9960 "                        \"between lstat() and readlink()\\en\");\n"
9961 "        exit(EXIT_FAILURE);\n"
9962 "    }\n"
9963
9964 #. type: Plain text
9965 #: build/C/man2/readlink.2:208
9966 #, no-wrap
9967 msgid "    linkname[sb.st_size] = \\(aq\\e0\\(aq;\n"
9968 msgstr "    linkname[sb.st_size] = \\(aq\\e0\\(aq;\n"
9969
9970 #. type: Plain text
9971 #: build/C/man2/readlink.2:210
9972 #, no-wrap
9973 msgid "    printf(\"\\(aq%s\\(aq points to \\(aq%s\\(aq\\en\", argv[1], linkname);\n"
9974 msgstr "    printf(\"\\(aq%s\\(aq points to \\(aq%s\\(aq\\en\", argv[1], linkname);\n"
9975
9976 #. type: Plain text
9977 #: build/C/man2/readlink.2:222
9978 msgid ""
9979 "B<readlink>(1), B<lstat>(2), B<readlinkat>(2), B<stat>(2), B<symlink>(2), "
9980 "B<path_resolution>(7), B<symlink>(7)"
9981 msgstr ""
9982 "B<readlink>(1), B<lstat>(2), B<readlinkat>(2), B<stat>(2), B<symlink>(2),\n"
9983 "B<path_resolution>(7), B<symlink>(7)"
9984
9985 #. type: TH
9986 #: build/C/man2/readv.2:32
9987 #, no-wrap
9988 msgid "READV"
9989 msgstr "READV"
9990
9991 #. type: TH
9992 #: build/C/man2/readv.2:32
9993 #, no-wrap
9994 msgid "2010-11-17"
9995 msgstr "2010-11-17"
9996
9997 #. type: Plain text
9998 #: build/C/man2/readv.2:35
9999 msgid ""
10000 "readv, writev, preadv, pwritev - read or write data into multiple buffers"
10001 msgstr "readv, writev, preadv, pwritev - 複数のバッファへの読み書きを行なう"
10002
10003 #. type: Plain text
10004 #: build/C/man2/readv.2:38
10005 #, no-wrap
10006 msgid "B<#include E<lt>sys/uio.hE<gt>>\n"
10007 msgstr "B<#include E<lt>sys/uio.hE<gt>>\n"
10008
10009 #. type: Plain text
10010 #: build/C/man2/readv.2:40
10011 #, no-wrap
10012 msgid "B<ssize_t readv(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<);>\n"
10013 msgstr "B<ssize_t readv(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<);>\n"
10014
10015 #. type: Plain text
10016 #: build/C/man2/readv.2:42
10017 #, no-wrap
10018 msgid "B<ssize_t writev(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<);>\n"
10019 msgstr "B<ssize_t writev(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<);>\n"
10020
10021 #. type: Plain text
10022 #: build/C/man2/readv.2:45
10023 #, no-wrap
10024 msgid ""
10025 "B<ssize_t preadv(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<,>\n"
10026 "B<               off_t >I<offset>B<);>\n"
10027 msgstr ""
10028 "B<ssize_t preadv(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<,>\n"
10029 "B<               off_t >I<offset>B<);>\n"
10030
10031 #. type: Plain text
10032 #: build/C/man2/readv.2:48
10033 #, no-wrap
10034 msgid ""
10035 "B<ssize_t pwritev(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<,>\n"
10036 "B<                off_t >I<offset>B<);>\n"
10037 msgstr ""
10038 "B<ssize_t pwritev(int >I<fd>B<, const struct iovec *>I<iov>B<, int >I<iovcnt>B<,>\n"
10039 "B<                off_t >I<offset>B<);>\n"
10040
10041 #. type: Plain text
10042 #: build/C/man2/readv.2:58
10043 msgid "B<preadv>(), B<pwritev>(): _BSD_SOURCE"
10044 msgstr "B<preadv>(), B<pwritev>(): _BSD_SOURCE"
10045
10046 #. type: Plain text
10047 #: build/C/man2/readv.2:68
10048 msgid ""
10049 "The B<readv>()  system call reads I<iovcnt> buffers from the file associated "
10050 "with the file descriptor I<fd> into the buffers described by I<iov> "
10051 "(\"scatter input\")."
10052 msgstr ""
10053 "B<readv>() システムコールは、ファイルディスクリプタ I<fd> に関連付けられた\n"
10054 "ファイルから、 I<iovcnt> 個のバッファ分のデータを読み込み、 I<iov> で指定\n"
10055 "されたバッファに格納する (\"scatter input\";「ばらまき入力」)。"
10056
10057 #. type: Plain text
10058 #: build/C/man2/readv.2:78
10059 msgid ""
10060 "The B<writev>()  system call writes I<iovcnt> buffers of data described by "
10061 "I<iov> to the file associated with the file descriptor I<fd> (\"gather output"
10062 "\")."
10063 msgstr ""
10064 "B<writev>() システムコールは、 I<iov> で指定されたバッファから最大 "
10065 "I<iovcnt>\n"
10066 "個のバッファ分のデータを取り出し、 ファイルディスクリプタ I<fd> に関連付け"
10067 "ら\n"
10068 "れたファイルに書き込む (\"gather output\";「かき集め出力」)。"
10069
10070 #. type: Plain text
10071 #: build/C/man2/readv.2:87
10072 msgid ""
10073 "The pointer I<iov> points to an array of I<iovec> structures, defined in "
10074 "I<E<lt>sys/uio.hE<gt>> as:"
10075 msgstr ""
10076 "ポインタ I<iov> は I<iovec> 構造体の配列へのポインタである。 I<iovec> 構造体"
10077 "は I<E<lt>sys/uio.hE<gt>> で以下のように定義されている:"
10078
10079 #. type: Plain text
10080 #: build/C/man2/readv.2:95
10081 #, no-wrap
10082 msgid ""
10083 "struct iovec {\n"
10084 "    void  *iov_base;    /* Starting address */\n"
10085 "    size_t iov_len;     /* Number of bytes to transfer */\n"
10086 "};\n"
10087 msgstr ""
10088 "struct iovec {\n"
10089 "    void  *iov_base;    /* Starting address */\n"
10090 "    size_t iov_len;     /* Number of bytes to transfer */\n"
10091 "};\n"
10092
10093 #. type: Plain text
10094 #: build/C/man2/readv.2:103
10095 msgid ""
10096 "The B<readv>()  system call works just like B<read>(2)  except that multiple "
10097 "buffers are filled."
10098 msgstr ""
10099 "B<readv>() システムコールは、複数のバッファにデータを読み込む点を除いて\n"
10100 "B<read>(2) と全く同様の動作を行う。"
10101
10102 #. type: Plain text
10103 #: build/C/man2/readv.2:109
10104 msgid ""
10105 "The B<writev>()  system call works just like B<write>(2)  except that "
10106 "multiple buffers are written out."
10107 msgstr ""
10108 "B<writev>() システムコールは、複数のバッファのデータを書き出す点以外は\n"
10109 "B<write>(2) と全く同様の動作を行う。"
10110
10111 #. type: Plain text
10112 #: build/C/man2/readv.2:128
10113 msgid ""
10114 "Buffers are processed in array order.  This means that B<readv>()  "
10115 "completely fills I<iov>[0] before proceeding to I<iov>[1], and so on.  (If "
10116 "there is insufficient data, then not all buffers pointed to by I<iov> may be "
10117 "filled.)  Similarly, B<writev>()  writes out the entire contents of I<iov>"
10118 "[0] before proceeding to I<iov>[1], and so on."
10119 msgstr ""
10120 "バッファは配列の順序で処理される。これは、 B<readv>()  が I<iov>[0] が完全に"
10121 "一杯になるまでデータを詰めてから、 I<iov>[1] などに進むことを意味する (データ"
10122 "が十分ない場合は、 I<iov> が指すバッファのいずれも一杯にならない)。 同様に、 "
10123 "B<writev>()  は I<iov>[0] の内容を全部書き出してから I<iov>[1] などに進む。"
10124
10125 #. type: Plain text
10126 #: build/C/man2/readv.2:146
10127 msgid ""
10128 "The data transfers performed by B<readv>()  and B<writev>()  are atomic: the "
10129 "data written by B<writev>()  is written as a single block that is not "
10130 "intermingled with output from writes in other processes (but see B<pipe>(7)  "
10131 "for an exception); analogously, B<readv>()  is guaranteed to read a "
10132 "contiguous block of data from the file, regardless of read operations "
10133 "performed in other threads or processes that have file descriptors referring "
10134 "to the same open file description (see B<open>(2))."
10135 msgstr ""
10136 "B<readv>()  と B<writev>()  によるデータ転送は atomic に行われる。つまり、 "
10137 "B<writev>()  によるデータ書き込みは一つのブロックとして行われ、他のプロセス"
10138 "の write による書き込みと混ざり合うことはない (例外に関しては B<pipe>(7)  を"
10139 "参照のこと)。同様に、 B<readv>()  はファイルから連続するデータブロックが読み"
10140 "出すことが保証され、 同じファイル記述 (file description; B<open>(2)  参照) を"
10141 "参照するファイルディスクリプタを持つ他のスレッドやプロセスが 実行した read 操"
10142 "作の影響を受けることはない。"
10143
10144 #. type: SS
10145 #: build/C/man2/readv.2:146
10146 #, no-wrap
10147 msgid "preadv() and pwritev()"
10148 msgstr "preadv() と pwritev()"
10149
10150 #. type: Plain text
10151 #: build/C/man2/readv.2:159
10152 msgid ""
10153 "The B<preadv>()  system call combines the functionality of B<readv>()  and "
10154 "B<pread>(2).  It performs the same task as B<readv>(), but adds a fourth "
10155 "argument, I<offset>, which specifies the file offset at which the input "
10156 "operation is to be performed."
10157 msgstr ""
10158 "B<preadv>() システムコールは B<readv>() と B<preadv>(2) の機能を\n"
10159 "組み合わせたものである。\n"
10160 "B<readv>() と同じ処理を実行するが、\n"
10161 "4 番目の引き数 I<offset> が追加されており、\n"
10162 "この引き数は入力操作を行うファイルオフセットを指定する。"
10163
10164 #. type: Plain text
10165 #: build/C/man2/readv.2:172
10166 msgid ""
10167 "The B<pwritev>()  system call combines the functionality of B<writev>()  and "
10168 "B<pwrite>(2).  It performs the same task as B<writev>(), but adds a fourth "
10169 "argument, I<offset>, which specifies the file offset at which the output "
10170 "operation is to be performed."
10171 msgstr ""
10172 "B<pwritev>() システムコールは B<writev>() と B<pwrite>(2) の機能を\n"
10173 "組み合わせたものである。\n"
10174 "B<writev>() と同じ処理を実行するが、\n"
10175 "4 番目の引き数 I<offset> が追加されており、\n"
10176 "この引き数は出力操作を行うファイルオフセットを指定する。"
10177
10178 #. type: Plain text
10179 #: build/C/man2/readv.2:177
10180 msgid ""
10181 "The file offset is not changed by these system calls.  The file referred to "
10182 "by I<fd> must be capable of seeking."
10183 msgstr ""
10184 "これらのシステムコールで、ファイルオフセットは変更されない。\n"
10185 "I<fd> が参照するファイルは seek 可能でなければならない。"
10186
10187 #. type: Plain text
10188 #: build/C/man2/readv.2:188
10189 msgid ""
10190 "On success, B<readv>()  and B<preadv>()  return the number of bytes read; "
10191 "B<writev>()  and B<pwritev>()  return the number of bytes written.  On "
10192 "error, -1 is returned, and I<errno> is set appropriately."
10193 msgstr ""
10194 "成功した場合、 B<readv>() と B<preadv> は読み込んだバイト数を返し、\n"
10195 "B<writev>() と B<pwritev>()は書き込んだバイト数を返す。\n"
10196 "エラーの場合 -1 を返し、I<errno> を適切に設定する。"
10197
10198 #. type: Plain text
10199 #: build/C/man2/readv.2:200
10200 msgid ""
10201 "The errors are as given for B<read>(2)  and B<write>(2).  Furthermore, "
10202 "B<preadv>()  and B<pwritev>()  can also fail for the same reasons as B<lseek>"
10203 "(2).  Additionally, the following error is defined:"
10204 msgstr ""
10205 "B<read>(2)  や B<write>(2)  と同じエラーが定義されている。\n"
10206 "さらに、 B<preadv>() と B<pwritev>() は B<lseek>(2) と同じ理由でも失敗す"
10207 "る。\n"
10208 "また、追加で以下のエラーが定義されている:"
10209
10210 #. type: Plain text
10211 #: build/C/man2/readv.2:209
10212 msgid ""
10213 "The sum of the I<iov_len> values overflows an I<ssize_t> value.  Or, the "
10214 "vector count I<iovcnt> is less than zero or greater than the permitted "
10215 "maximum."
10216 msgstr ""
10217 "I<iov_len> の合計が I<ssize_t> の範囲をオーバーフローした。もしくは、 ベクタ"
10218 "数 I<iovcnt> が 0 より小さいか許可された最大値よりも大きかった。"
10219
10220 #. type: Plain text
10221 #: build/C/man2/readv.2:214
10222 msgid ""
10223 "B<preadv>()  and B<pwritev>()  first appeared in Linux 2.6.30; library "
10224 "support was added in glibc 2.10."
10225 msgstr ""
10226 "B<preadv>() と B<pwritev>() は Linux 2.6.30 で初めて登場した。\n"
10227 "ライブラリによるサポートは glibc 2.10 で追加された。"
10228
10229 #.  The readv/writev system calls were buggy before Linux 1.3.40.
10230 #.  (Says release.libc.)
10231 #. type: Plain text
10232 #: build/C/man2/readv.2:222
10233 msgid ""
10234 "B<readv>(), B<writev>(): 4.4BSD (these system calls first appeared in "
10235 "4.2BSD), POSIX.1-2001.  Linux libc5 used I<size_t> as the type of the "
10236 "I<iovcnt> argument, and I<int> as the return type."
10237 msgstr ""
10238 "B<readv>(), B<writev>(): \n"
10239 "4.4BSD (これらのシステムコールは 4.2BSD で最初に現われた)、POSIX.1-2001。 \n"
10240 "Linux libc5 では、 I<iovcnt> 引き数の型として I<size_t> を、\n"
10241 "返り値の型として I<int> を使用していた。"
10242
10243 #. type: Plain text
10244 #: build/C/man2/readv.2:226
10245 msgid ""
10246 "B<preadv>(), B<pwritev>(): nonstandard, but present also on the modern BSDs."
10247 msgstr "B<preadv>(), B<pwritev>(): 非標準だが、最近の BSD にも存在する。"
10248
10249 #. type: SS
10250 #: build/C/man2/readv.2:227
10251 #, no-wrap
10252 msgid "Linux notes"
10253 msgstr "Linux での注意"
10254
10255 #. type: Plain text
10256 #: build/C/man2/readv.2:258
10257 msgid ""
10258 "POSIX.1-2001 allows an implementation to place a limit on the number of "
10259 "items that can be passed in I<iov>.  An implementation can advertise its "
10260 "limit by defining B<IOV_MAX> in I<E<lt>limits.hE<gt>> or at run time via the "
10261 "return value from I<sysconf(_SC_IOV_MAX)>.  On Linux, the limit advertised "
10262 "by these mechanisms is 1024, which is the true kernel limit.  However, the "
10263 "glibc wrapper functions do some extra work if they detect that the "
10264 "underlying kernel system call failed because this limit was exceeded.  In "
10265 "the case of B<readv>()  the wrapper function allocates a temporary buffer "
10266 "large enough for all of the items specified by I<iov>, passes that buffer in "
10267 "a call to B<read>(2), copies data from the buffer to the locations specified "
10268 "by the I<iov_base> fields of the elements of I<iov>, and then frees the "
10269 "buffer.  The wrapper function for B<writev>()  performs the analogous task "
10270 "using a temporary buffer and a call to B<write>(2)."
10271 msgstr ""
10272 "POSIX.1-2001 では、 I<iov> で渡すことができる要素数に上限を設ける実装が認めら"
10273 "れている。 実装は、 I<E<lt>limits.hE<gt>> の B<IOV_MAX> を定義することや、実"
10274 "行時に I<sysconf(_SC_IOV_MAX)> の返り値経由で、この上限を広告することができ"
10275 "る。 Linux では、この仕組みにより広告される上限は 1024 であり、 この値はカー"
10276 "ネルでの上限そのものである。 一方で、glibc のラッパー関数は、その関数の内部で"
10277 "呼ばれるカーネル システムコールがこの上限を超過して失敗したことを検出する"
10278 "と、 追加の動作をする。 B<readv>()  の場合、ラッパー関数は I<iov> で指定され"
10279 "た全ての要素を格納できる大きさの一時バッファを割り当て、 B<read>(2)  を呼び出"
10280 "す際にそのバッファを渡し、 そのバッファのデータを I<iov> の各要素の "
10281 "I<iov_base> フィールドが指定する場所にコピーしてから、 そのバッファを解放す"
10282 "る。 B<writev>()  のラッパー関数も、同じように一時バッファを使って B<write>"
10283 "(2)  を呼び出す。"
10284
10285 #. type: Plain text
10286 #: build/C/man2/readv.2:265
10287 msgid ""
10288 "It is not advisable to mix calls to B<readv>()  or B<writev>(), which "
10289 "operate on file descriptors, with the functions from the stdio library; the "
10290 "results will be undefined and probably not what you want."
10291 msgstr ""
10292 "ファイルディスクリプタに対する操作を行う B<readv>() や B<writev>() と、\n"
10293 "標準入出力ライブラリの関数をごちゃまぜにして呼ぶのはお薦めしない。\n"
10294 "どんな結果になるかは定義されておらず、おそらく期待する結果は\n"
10295 "得られないだろう。"
10296
10297 #. type: Plain text
10298 #: build/C/man2/readv.2:268
10299 msgid "The following code sample demonstrates the use of B<writev>():"
10300 msgstr "以下のサンプルコードは B<writev>()  の使用方法を示すものである。"
10301
10302 #. type: Plain text
10303 #: build/C/man2/readv.2:275
10304 #, no-wrap
10305 msgid ""
10306 "char *str0 = \"hello \";\n"
10307 "char *str1 = \"world\\en\";\n"
10308 "struct iovec iov[2];\n"
10309 "ssize_t nwritten;\n"
10310 msgstr ""
10311 "char *str0 = \"hello \";\n"
10312 "char *str1 = \"world\\en\";\n"
10313 "struct iovec iov[2];\n"
10314 "ssize_t nwritten;\n"
10315
10316 #. type: Plain text
10317 #: build/C/man2/readv.2:280
10318 #, no-wrap
10319 msgid ""
10320 "iov[0].iov_base = str0;\n"
10321 "iov[0].iov_len = strlen(str0);\n"
10322 "iov[1].iov_base = str1;\n"
10323 "iov[1].iov_len = strlen(str1);\n"
10324 msgstr ""
10325 "iov[0].iov_base = str0;\n"
10326 "iov[0].iov_len = strlen(str0);\n"
10327 "iov[1].iov_base = str1;\n"
10328 "iov[1].iov_len = strlen(str1);\n"
10329
10330 #. type: Plain text
10331 #: build/C/man2/readv.2:282
10332 #, no-wrap
10333 msgid "nwritten = writev(STDOUT_FILENO, iov, 2);\n"
10334 msgstr "nwritten = writev(STDOUT_FILENO, iov, 2);\n"
10335
10336 #. type: Plain text
10337 #: build/C/man2/readv.2:288
10338 msgid "B<pread>(2), B<read>(2), B<write>(2)"
10339 msgstr "B<pread>(2), B<read>(2), B<write>(2)"
10340
10341 #. type: TH
10342 #: build/C/man3/remove.3:31
10343 #, no-wrap
10344 msgid "REMOVE"
10345 msgstr "REMOVE"
10346
10347 #. type: TH
10348 #: build/C/man3/remove.3:31
10349 #, no-wrap
10350 msgid "2008-12-03"
10351 msgstr "2008-12-03"
10352
10353 #. type: Plain text
10354 #: build/C/man3/remove.3:34
10355 msgid "remove - remove a file or directory"
10356 msgstr "remove - ファイルやディレクトリを削除する"
10357
10358 #. type: Plain text
10359 #: build/C/man3/remove.3:38
10360 msgid "B<int remove(const char *>I<pathname>B<);>"
10361 msgstr "B<int remove(const char *>I<pathname>B<);>"
10362
10363 #. type: Plain text
10364 #: build/C/man3/remove.3:46
10365 msgid ""
10366 "B<remove>()  deletes a name from the file system.  It calls B<unlink>(2)  "
10367 "for files, and B<rmdir>(2)  for directories."
10368 msgstr ""
10369 "B<remove>()  はファイルシステムからファイル名を削除する。 ファイルに対しては "
10370 "B<unlink>(2)  を、ディレクトリに対しては B<rmdir>(2)  を呼び出す。"
10371
10372 #. type: Plain text
10373 #: build/C/man3/remove.3:50
10374 msgid ""
10375 "If the removed name was the last link to a file and no processes have the "
10376 "file open, the file is deleted and the space it was using is made available "
10377 "for reuse."
10378 msgstr ""
10379 "もしその名前が ファイルへの最後のリンクで、かつ、どのプロセスもそのファイル"
10380 "を 開いていないなら、ファイルも削除する。ファイルの占めていた 領域は他で使う"
10381 "ことができるようになる。"
10382
10383 #. type: Plain text
10384 #: build/C/man3/remove.3:55
10385 msgid ""
10386 "If the name was the last link to a file, but any processes still have the "
10387 "file open, the file will remain in existence until the last file descriptor "
10388 "referring to it is closed."
10389 msgstr ""
10390 "名前がファイルへの最後のリンクであっても、どこかのプロセスが そのファイルを開"
10391 "いているなら、ファイルの最後のファイル記述子 (file descriptor) が閉じられるま"
10392 "でファイルは存在し続ける。"
10393
10394 #. type: Plain text
10395 #: build/C/man3/remove.3:57
10396 msgid "If the name referred to a symbolic link, the link is removed."
10397 msgstr "名前が指しているのがシンボリックリンクなら、そのリンクを削除する。"
10398
10399 #. type: Plain text
10400 #: build/C/man3/remove.3:60
10401 msgid ""
10402 "If the name referred to a socket, FIFO, or device, the name is removed, but "
10403 "processes which have the object open may continue to use it."
10404 msgstr ""
10405 "名前が指しているのがソケット、FIFO、デバイスの場合、名前は削除されるが、 その"
10406 "ソケットなどを開いているプロセスはそのまま使い続けることができる。"
10407
10408 #. type: Plain text
10409 #: build/C/man3/remove.3:70
10410 msgid "The errors that occur are those for B<unlink>(2)  and B<rmdir>(2)."
10411 msgstr "発生するエラーは B<unlink>(2)  および B<rmdir>(2)  と同じものである。"
10412
10413 #. type: Plain text
10414 #: build/C/man3/remove.3:72
10415 msgid "C89, C99, 4.3BSD, POSIX.1-2001."
10416 msgstr "C89, C99, 4.3BSD, POSIX.1-2001."
10417
10418 #. type: Plain text
10419 #: build/C/man3/remove.3:78
10420 msgid ""
10421 "Under libc4 and libc5, B<remove>()  was an alias for B<unlink>(2)  (and "
10422 "hence would not remove directories)."
10423 msgstr ""
10424 "libc4 と libc5 においては、 B<remove>()  は B<unlink>(2)  の別名であった "
10425 "(従ってディレクトリを削除できなかった)。"
10426
10427 #. type: Plain text
10428 #: build/C/man3/remove.3:81 build/C/man2/unlink.2:148
10429 msgid ""
10430 "Infelicities in the protocol underlying NFS can cause the unexpected "
10431 "disappearance of files which are still being used."
10432 msgstr ""
10433 "NFS プロトコルに内在する問題により、まだ使用中のファイルが想定外に消えてしま"
10434 "うことがありえる。"
10435
10436 #. type: Plain text
10437 #: build/C/man3/remove.3:92
10438 msgid ""
10439 "B<rm>(1), B<unlink>(1), B<link>(2), B<mknod>(2), B<open>(2), B<rename>(2), "
10440 "B<rmdir>(2), B<unlink>(2), B<mkfifo>(3), B<symlink>(7)"
10441 msgstr ""
10442 "B<rm>(1), B<unlink>(1), B<link>(2), B<mknod>(2), B<open>(2), B<rename>(2), "
10443 "B<rmdir>(2), B<unlink>(2), B<mkfifo>(3), B<symlink>(7)"
10444
10445 #. type: TH
10446 #: build/C/man2/rename.2:32
10447 #, no-wrap
10448 msgid "RENAME"
10449 msgstr "RENAME"
10450
10451 #. type: Plain text
10452 #: build/C/man2/rename.2:35
10453 msgid "rename - change the name or location of a file"
10454 msgstr "rename - ファイルの名前や位置を変更する"
10455
10456 #. type: Plain text
10457 #: build/C/man2/rename.2:39
10458 msgid "B<int rename(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
10459 msgstr "B<int rename(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
10460
10461 #. type: Plain text
10462 #: build/C/man2/rename.2:48
10463 msgid ""
10464 "B<rename>()  renames a file, moving it between directories if required.  Any "
10465 "other hard links to the file (as created using B<link>(2))  are unaffected.  "
10466 "Open file descriptors for I<oldpath> are also unaffected."
10467 msgstr ""
10468 "B<rename>()  はファイルの名前を変更し、必要ならばディレクトリ間の移動を行な"
10469 "う。 そのファイルに対する (B<link>(2)  を使用して作られた) 他のハードリンク "
10470 "(hard link) には影響はない。 オープン済の I<oldpath> に対するファイルディスク"
10471 "リプタにも影響はない。"
10472
10473 #. type: Plain text
10474 #: build/C/man2/rename.2:56
10475 msgid ""
10476 "If I<newpath> already exists it will be atomically replaced (subject to a "
10477 "few conditions; see ERRORS below), so that there is no point at which "
10478 "another process attempting to access I<newpath> will find it missing."
10479 msgstr ""
10480 "I<newpath> が既に存在する場合、それは不可分操作で (atomically) 置き換えられ"
10481 "る (ただし、いくつかの条件がある; 以下の「エラー」のセクションを参照)。 その"
10482 "ため、 I<newpath> にアクセスしようとしている他のプロセスがファイルを見失うこ"
10483 "とはない (訳註: 常にアクセス可能である)。"
10484
10485 #. type: Plain text
10486 #: build/C/man2/rename.2:64
10487 msgid ""
10488 "If I<oldpath> and I<newpath> are existing hard links referring to the same "
10489 "file, then B<rename>()  does nothing, and returns a success status."
10490 msgstr ""
10491 "I<oldpath> と I<newpath> がどちらも既存のハードリンクで、同じファイルを参照し"
10492 "ている場合、 B<rename>()  は何も行わず、ステータスとして成功を返す。"
10493
10494 #. type: Plain text
10495 #: build/C/man2/rename.2:72
10496 msgid ""
10497 "If I<newpath> exists but the operation fails for some reason B<rename>()  "
10498 "guarantees to leave an instance of I<newpath> in place."
10499 msgstr ""
10500 "I<newpath> が存在し、何らかの理由で操作が失敗した場合、 B<rename>()  は "
10501 "I<newpath> の実体を元のまま残すことを保証する。"
10502
10503 #. type: Plain text
10504 #: build/C/man2/rename.2:78
10505 msgid ""
10506 "I<oldpath> can specify a directory.  In this case, I<newpath> must either "
10507 "not exist, or it must specify an empty directory."
10508 msgstr ""
10509 "I<oldpath> にはディレクトリを指定することもできる。 この場合、 I<newpath> は"
10510 "存在しないか、空のディレクトリでなければならない。"
10511
10512 #. type: Plain text
10513 #: build/C/man2/rename.2:85
10514 msgid ""
10515 "However, when overwriting there will probably be a window in which both "
10516 "I<oldpath> and I<newpath> refer to the file being renamed."
10517 msgstr ""
10518 "一方で、上書きを行なう場合は、rename が行なわれるファイルを I<oldpath> と "
10519 "I<newpath> の両方で参照できる瞬間がおそらく存在する。"
10520
10521 #. type: Plain text
10522 #: build/C/man2/rename.2:91
10523 msgid ""
10524 "If I<oldpath> refers to a symbolic link the link is renamed; if I<newpath> "
10525 "refers to a symbolic link the link will be overwritten."
10526 msgstr ""
10527 "I<oldpath> がシンボリックリンク (symbolic link) を参照している場合は、 リンク"
10528 "の名前が変更される。 また、 I<newpath> がシンボリックリンクを参照している場合"
10529 "は、リンクが上書きされる。"
10530
10531 #. type: Plain text
10532 #: build/C/man2/rename.2:116
10533 msgid ""
10534 "Write permission is denied for the directory containing I<oldpath> or "
10535 "I<newpath>, or, search permission is denied for one of the directories in "
10536 "the path prefix of I<oldpath> or I<newpath>, or I<oldpath> is a directory "
10537 "and does not allow write permission (needed to update the I<..> entry).  "
10538 "(See also B<path_resolution>(7).)"
10539 msgstr ""
10540 "I<oldpath> または I<newpath> を含んでいるディレクトリの書き込み許可がない。 "
10541 "または、 I<oldpath> または I<newpath> のディレクトリ部分のどれかに検索許可が"
10542 "ない。 または、 I<oldpath> がディレクトリで (I<..> エントリを更新するのに必要"
10543 "な) 書き込み許可がない (B<path_resolution>(7)  も参照)。"
10544
10545 #. type: TP
10546 #: build/C/man2/rename.2:116 build/C/man2/rmdir.2:55 build/C/man2/unlink.2:71
10547 #, no-wrap
10548 msgid "B<EBUSY>"
10549 msgstr "B<EBUSY>"
10550
10551 #. type: Plain text
10552 #: build/C/man2/rename.2:133
10553 msgid ""
10554 "The rename fails because I<oldpath> or I<newpath> is a directory that is in "
10555 "use by some process (perhaps as current working directory, or as root "
10556 "directory, or because it was open for reading) or is in use by the system "
10557 "(for example as mount point), while the system considers this an error.  "
10558 "(Note that there is no requirement to return B<EBUSY> in such cases"
10559 "\\(emthere is nothing wrong with doing the rename anyway\\(embut it is "
10560 "allowed to return B<EBUSY> if the system cannot otherwise handle such "
10561 "situations.)"
10562 msgstr ""
10563 "I<oldpath> または I<newpath> がディレクトリで、何らかのプロセスが使用中 (多"
10564 "分、カレントワーキングディレクトリか、ルートディレクトリか、 読み込みのために"
10565 "オープンされているかでろう)  もしくは、システムが使用中 (例えばマウントポイン"
10566 "トである)  であり、システムがこれをエラーであると判断したために rename が失敗"
10567 "した。 (このような場合に B<EBUSY> を返すことは規格では要求されていない点に注"
10568 "意すること。 このような場合に、rename をとにかく実行してみるのは何の問題もな"
10569 "い。 ただし、そのような状況で、システムが他に返すエラーがない場合には "
10570 "B<EBUSY> を返すことが許されている。)"
10571
10572 #. type: Plain text
10573 #: build/C/man2/rename.2:143
10574 msgid ""
10575 "The new pathname contained a path prefix of the old, or, more generally, an "
10576 "attempt was made to make a directory a subdirectory of itself."
10577 msgstr ""
10578 "I<newpath> が I<oldpath> のパス部分を含んでいる。ディレクトリを自分自身のサブ"
10579 "ディレクトリに 変更しようとした場合がほとんどである。"
10580
10581 #. type: Plain text
10582 #: build/C/man2/rename.2:149
10583 msgid "I<newpath> is an existing directory, but I<oldpath> is not a directory."
10584 msgstr ""
10585 "I<newpath> は存在しているディレクトリであるが、 I<oldpath> はディレクトリでな"
10586 "い。"
10587
10588 #. type: Plain text
10589 #: build/C/man2/rename.2:160
10590 msgid ""
10591 "I<oldpath> already has the maximum number of links to it, or it was a "
10592 "directory and the directory containing I<newpath> has the maximum number of "
10593 "links."
10594 msgstr ""
10595 "I<oldpath> は既に最大数までのリンクを持っているか、それがディレクトリで "
10596 "I<newpath> を含んでいるディレクトリが最大数までのリンクを持っている。"
10597
10598 #. type: Plain text
10599 #: build/C/man2/rename.2:176
10600 msgid ""
10601 "The link named by I<oldpath> does not exist; or, a directory component in "
10602 "I<newpath> does not exist; or, I<oldpath> or I<newpath> is an empty string."
10603 msgstr ""
10604 "I<oldpath> という名前のリンクが存在しない。 または、 I<newpath> というディレ"
10605 "クトリが存在しない。 または、 I<oldpath> か I<newpath> が空の文字列である。"
10606
10607 #. type: Plain text
10608 #: build/C/man2/rename.2:193
10609 msgid ""
10610 "A component used as a directory in I<oldpath> or I<newpath> is not, in fact, "
10611 "a directory.  Or, I<oldpath> is a directory, and I<newpath> exists but is "
10612 "not a directory."
10613 msgstr ""
10614 "I<oldpath> か I<newpath> に含まれているディレクトリ部分が 実際にはディレクト"
10615 "リでない。 または I<oldpath> がディレクトリで、 I<newpath> が存在してディレク"
10616 "トリでない。"
10617
10618 #. type: TP
10619 #: build/C/man2/rename.2:193
10620 #, no-wrap
10621 msgid "B<ENOTEMPTY> or B<EEXIST>"
10622 msgstr "B<ENOTEMPTY  または  EEXIST>"
10623
10624 #. type: Plain text
10625 #: build/C/man2/rename.2:197
10626 msgid ""
10627 "I<newpath> is a nonempty directory, that is, contains entries other than \"."
10628 "\" and \"..\"."
10629 msgstr ""
10630 "I<newpath> が空でないディレクトリである。すなわち \".\" と \"..\" 以外を含ん"
10631 "でいる。"
10632
10633 #. type: TP
10634 #: build/C/man2/rename.2:197 build/C/man2/unlink.2:126
10635 #, no-wrap
10636 msgid "B<EPERM> or B<EACCES>"
10637 msgstr "B<EPERM> または B<EACCES>"
10638
10639 #. type: Plain text
10640 #: build/C/man2/rename.2:221
10641 msgid ""
10642 "The directory containing I<oldpath> has the sticky bit (B<S_ISVTX>)  set and "
10643 "the process's effective user ID is neither the user ID of the file to be "
10644 "deleted nor that of the directory containing it, and the process is not "
10645 "privileged (Linux: does not have the B<CAP_FOWNER> capability); or "
10646 "I<newpath> is an existing file and the directory containing it has the "
10647 "sticky bit set and the process's effective user ID is neither the user ID of "
10648 "the file to be replaced nor that of the directory containing it, and the "
10649 "process is not privileged (Linux: does not have the B<CAP_FOWNER> "
10650 "capability); or the file system containing I<pathname> does not support "
10651 "renaming of the type requested."
10652 msgstr ""
10653 "I<oldpath> のあるディレクトリにスティッキービット (sticky bit)  "
10654 "(B<S_ISVTX>)  が設定されており、 プロセスの実効ユーザー ID が 削除しようとす"
10655 "るファイルのユーザー ID と そのファイルを含むディレクトリのユーザー ID のいず"
10656 "れとも一致せず、かつ プロセスに特権がない (Linux では B<CAP_FOWNER> ケーパビ"
10657 "リティ (capability) がない)。 または、 I<newpath> がすでに存在するファイル"
10658 "で、親ディレクトリにスティッキービットが設定されており、 プロセスの実効ユー"
10659 "ザー ID が 置き換えようとするファイルのユーザー ID と そのファイルを含むディ"
10660 "レクトリのユーザー ID のいずれとも一致せず、かつ プロセスに特権がない (Linux "
10661 "では B<CAP_FOWNER> ケーパビリティがない)。 または I<oldpath> と I<newpath> が"
10662 "存在するファイルシステムが、要求された種類の名前の変更を サポートしていない。"
10663
10664 #. type: Plain text
10665 #: build/C/man2/rename.2:232
10666 msgid ""
10667 "I<oldpath> and I<newpath> are not on the same mounted file system.  (Linux "
10668 "permits a file system to be mounted at multiple points, but B<rename>()  "
10669 "does not work across different mount points, even if the same file system is "
10670 "mounted on both.)"
10671 msgstr ""
10672 "I<oldpath> と I<newpath> が同じマウントされたファイルシステムに存在しない。 "
10673 "(Linux は 1 つのファイルシステムを複数のマウント位置に マウントすることを許可"
10674 "している。 しかし B<rename>()  は、たとえ同じファイルシステムであっても、 "
10675 "別々のマウント位置を跨いでは動作しない。)"
10676
10677 #. type: Plain text
10678 #: build/C/man2/rename.2:234
10679 msgid "4.3BSD, C89, C99, POSIX.1-2001."
10680 msgstr "4.3BSD, C89, C99, POSIX.1-2001."
10681
10682 #. type: Plain text
10683 #: build/C/man2/rename.2:245
10684 msgid ""
10685 "On NFS file systems, you can not assume that if the operation failed the "
10686 "file was not renamed.  If the server does the rename operation and then "
10687 "crashes, the retransmitted RPC which will be processed when the server is up "
10688 "again causes a failure.  The application is expected to deal with this.  See "
10689 "B<link>(2)  for a similar problem."
10690 msgstr ""
10691 "NFS ファイルシステムでは、操作が失敗したからといって、 ファイルの名前が変更で"
10692 "きなかったと決めてかかることはできない。 サーバが rename 操作を終えてからク"
10693 "ラッシュした場合、 サーバが再び立ち上がったときに、 再送信された RPC が処理さ"
10694 "れるが、これは失敗となる。 アプリケーションはこの問題を正しく取り扱うことが期"
10695 "待されている。 同様の問題について B<link>(2)  にも書かれている。"
10696
10697 #. type: Plain text
10698 #: build/C/man2/rename.2:254
10699 msgid ""
10700 "B<mv>(1), B<chmod>(2), B<link>(2), B<renameat>(2), B<symlink>(2), B<unlink>"
10701 "(2), B<path_resolution>(7), B<symlink>(7)"
10702 msgstr ""
10703 "B<mv>(1), B<chmod>(2), B<link>(2), B<renameat>(2), B<symlink>(2), B<unlink>"
10704 "(2), B<path_resolution>(7), B<symlink>(7)"
10705
10706 #. type: TH
10707 #: build/C/man2/rmdir.2:30
10708 #, no-wrap
10709 msgid "RMDIR"
10710 msgstr "RMDIR"
10711
10712 #. type: TH
10713 #: build/C/man2/rmdir.2:30
10714 #, no-wrap
10715 msgid "2008-05-08"
10716 msgstr "2008-05-08"
10717
10718 #. type: Plain text
10719 #: build/C/man2/rmdir.2:33
10720 msgid "rmdir - delete a directory"
10721 msgstr "rmdir - ディレクトリを削除する"
10722
10723 #. type: Plain text
10724 #: build/C/man2/rmdir.2:37
10725 msgid "B<int rmdir(const char *>I<pathname>B<);>"
10726 msgstr "B<int rmdir(const char *>I<pathname>B<);>"
10727
10728 #. type: Plain text
10729 #: build/C/man2/rmdir.2:40
10730 msgid "B<rmdir>()  deletes a directory, which must be empty."
10731 msgstr ""
10732 "B<rmdir>()  はディレクトリを削除する。削除するディレクトリは空でなければなら"
10733 "ない。"
10734
10735 #. type: Plain text
10736 #: build/C/man2/rmdir.2:55
10737 msgid ""
10738 "Write access to the directory containing I<pathname> was not allowed, or one "
10739 "of the directories in the path prefix of I<pathname> did not allow search "
10740 "permission.  (See also B<path_resolution>(7)."
10741 msgstr ""
10742 "I<pathname> を含んでいるディレクトリへの書き込みアクセスが プロセスの実効 "
10743 "(effective) UID に対して許可されていないか、 I<pathname> に含まれているディレ"
10744 "クトリのどれかに検索 (実行) 許可がないか、 I<pathname> に至るまでのディレクト"
10745 "リのいずれかに対する検索許可がなかった。 (B<path_resolution>(7)  も参照のこ"
10746 "と)"
10747
10748 #. type: Plain text
10749 #: build/C/man2/rmdir.2:64
10750 msgid ""
10751 "I<pathname> is currently in use by the system or some process that prevents "
10752 "its removal.  On Linux this means I<pathname> is currently used as a mount "
10753 "point or is the root directory of the calling process."
10754 msgstr ""
10755 "I<pathname> がシステムや別のプロセスにより使用中で削除することができない。 "
10756 "Linux では、 I<pathname> がマウントポイントとして使用されているか、 呼び出し"
10757 "たプロセスのルートディレクトリであることを意味する。"
10758
10759 #. type: Plain text
10760 #: build/C/man2/rmdir.2:73
10761 msgid "I<pathname> has I<.> as last component."
10762 msgstr "I<pathname> の最後のディレクトリ部分が I<.> である。"
10763
10764 #. type: Plain text
10765 #: build/C/man2/rmdir.2:77
10766 msgid "Too many symbolic links were encountered in resolving I<pathname>."
10767 msgstr "I<pathname> を解決する際に遭遇したシンボリックリンクが多過ぎる。"
10768
10769 #. type: Plain text
10770 #: build/C/man2/rmdir.2:85
10771 msgid ""
10772 "A directory component in I<pathname> does not exist or is a dangling "
10773 "symbolic link."
10774 msgstr ""
10775 "I<pathname> の中のディレクトリ部分が存在しないか、壊れた (dangling)  シンボ"
10776 "リックリンク (symbolic link) である。"
10777
10778 #. type: Plain text
10779 #: build/C/man2/rmdir.2:94
10780 msgid ""
10781 "I<pathname>, or a component used as a directory in I<pathname>, is not, in "
10782 "fact, a directory."
10783 msgstr ""
10784 "I<pathname> か I<pathname> に含まれているディレクトリ部分が、実際には、ディレ"
10785 "クトリでない。"
10786
10787 #. type: TP
10788 #: build/C/man2/rmdir.2:94
10789 #, no-wrap
10790 msgid "B<ENOTEMPTY>"
10791 msgstr "B<ENOTEMPTY>"
10792
10793 #. type: Plain text
10794 #: build/C/man2/rmdir.2:107
10795 msgid ""
10796 "I<pathname> contains entries other than I<.> and I<..> ; or, I<pathname> has "
10797 "I<..> as its final component.  POSIX.1-2001 also allows B<EEXIST> for this "
10798 "condition."
10799 msgstr ""
10800 "ディレクトリ I<pathname> に I<.> と I<..> 以外のエントリがある。または、 "
10801 "I<pathname> を構成する最後の要素が I<..> である。 POSIX.1-2001 は、この状況"
10802 "で B<EEXIST> を返すことを認めている。"
10803
10804 #. type: Plain text
10805 #: build/C/man2/rmdir.2:118
10806 msgid ""
10807 "The directory containing I<pathname> has the sticky bit (B<S_ISVTX>)  set "
10808 "and the process's effective user ID is neither the user ID of the file to be "
10809 "deleted nor that of the directory containing it, and the process is not "
10810 "privileged (Linux: does not have the B<CAP_FOWNER> capability)."
10811 msgstr ""
10812 "I<pathname> を含んでいるディレクトリにスティッキービット(sticky-bit)  "
10813 "(B<S_ISVTX>)  が設定されていて、プロセスの実効ユーザーID が削除しようとする"
10814 "ファイルの ユーザID とそのファイルを含むディレクトリのユーザーID のどちらとも"
10815 "異なり、 プロセスも権限 (Linux では B<CAP_FOWNER> ケーパビリティ) がない。"
10816
10817 #. type: Plain text
10818 #: build/C/man2/rmdir.2:123
10819 msgid ""
10820 "The file system containing I<pathname> does not support the removal of "
10821 "directories."
10822 msgstr ""
10823 "I<pathname> を含んでいるファイルシステムがディレクトリの 削除をサポートしてい"
10824 "ない。"
10825
10826 #. type: Plain text
10827 #: build/C/man2/rmdir.2:127
10828 msgid "I<pathname> refers to a directory on a read-only file system."
10829 msgstr ""
10830 "I<pathname> が読み込み専用のファイルシステム上のディレクトリを参照している。"
10831
10832 #. type: Plain text
10833 #: build/C/man2/rmdir.2:132
10834 msgid ""
10835 "Infelicities in the protocol underlying NFS can cause the unexpected "
10836 "disappearance of directories which are still being used."
10837 msgstr ""
10838 "NFS プロトコルに潜在している欠陥によって、まだ使用中のディレクトリが 突然消滅"
10839 "する現象が引き起こされることがある。"
10840
10841 #. type: Plain text
10842 #: build/C/man2/rmdir.2:141
10843 msgid ""
10844 "B<rm>(1), B<rmdir>(1), B<chdir>(2), B<chmod>(2), B<mkdir>(2), B<rename>(2), "
10845 "B<unlink>(2), B<unlinkat>(2)"
10846 msgstr ""
10847 "B<rm>(1), B<rmdir>(1), B<chdir>(2), B<chmod>(2), B<mkdir>(2), B<rename>(2), "
10848 "B<unlink>(2), B<unlinkat>(2)"
10849
10850 #. type: TH
10851 #: build/C/man3/scanf.3:52
10852 #, no-wrap
10853 msgid "SCANF"
10854 msgstr "SCANF"
10855
10856 #. type: TH
10857 #: build/C/man3/scanf.3:52
10858 #, no-wrap
10859 msgid "2013-01-30"
10860 msgstr "2013-01-30"
10861
10862 #. type: Plain text
10863 #: build/C/man3/scanf.3:55
10864 msgid ""
10865 "scanf, fscanf, sscanf, vscanf, vsscanf, vfscanf - input format conversion"
10866 msgstr "scanf, fscanf, sscanf, vscanf, vsscanf, vfscanf - 書式付き入力変換"
10867
10868 #. type: Plain text
10869 #: build/C/man3/scanf.3:62
10870 #, no-wrap
10871 msgid ""
10872 "B<int scanf(const char *>I<format>B<, ...);>\n"
10873 "B<int fscanf(FILE *>I<stream>B<, const char *>I<format>B<, ...);>\n"
10874 "B<int sscanf(const char *>I<str>B<, const char *>I<format>B<, ...);>\n"
10875 msgstr ""
10876 "B<int scanf(const char *>I<format>B<, ...);>\n"
10877 "B<int fscanf(FILE *>I<stream>B<, const char *>I<format>B<, ...);>\n"
10878 "B<int sscanf(const char *>I<str>B<, const char *>I<format>B<, ...);>\n"
10879
10880 #. type: Plain text
10881 #: build/C/man3/scanf.3:64
10882 #, no-wrap
10883 msgid "B<#include E<lt>stdarg.hE<gt>>\n"
10884 msgstr "B<#include E<lt>stdarg.hE<gt>>\n"
10885
10886 #. type: Plain text
10887 #: build/C/man3/scanf.3:68
10888 #, no-wrap
10889 msgid ""
10890 "B<int vscanf(const char *>I<format>B<, va_list >I<ap>B<);>\n"
10891 "B<int vsscanf(const char *>I<str>B<, const char *>I<format>B<, va_list >I<ap>B<);>\n"
10892 "B<int vfscanf(FILE *>I<stream>B<, const char *>I<format>B<, va_list >I<ap>B<);>\n"
10893 msgstr ""
10894 "B<int vscanf(const char *>I<format>B<, va_list >I<ap>B<);>\n"
10895 "B<int vsscanf(const char *>I<str>B<, const char *>I<format>B<, va_list >I<ap>B<);>\n"
10896 "B<int vfscanf(FILE *>I<stream>B<, const char *>I<format>B<, va_list >I<ap>B<);>\n"
10897
10898 #. type: Plain text
10899 #: build/C/man3/scanf.3:79
10900 msgid "B<vscanf>(), B<vsscanf>(), B<vfscanf>():"
10901 msgstr "B<vscanf>(), B<vsscanf>(), B<vfscanf>():"
10902
10903 #. type: Plain text
10904 #: build/C/man3/scanf.3:82
10905 msgid ""
10906 "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _ISOC99_SOURCE || _POSIX_C_SOURCE\\ E<gt>=\\ "
10907 "200112L;"
10908 msgstr ""
10909 "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _ISOC99_SOURCE || _POSIX_C_SOURCE\\ E<gt>=\\ "
10910 "200112L;"
10911
10912 #. type: Plain text
10913 #: build/C/man3/scanf.3:104
10914 msgid ""
10915 "The B<scanf>()  family of functions scans input according to I<format> as "
10916 "described below.  This format may contain I<conversion specifications>; the "
10917 "results from such conversions, if any, are stored in the locations pointed "
10918 "to by the I<pointer> arguments that follow I<format>.  Each I<pointer> "
10919 "argument must be of a type that is appropriate for the value returned by the "
10920 "corresponding conversion specification."
10921 msgstr ""
10922 "B<scanf>()  関数グループは、以下に述べるように、 I<format> に従って入力を読み"
10923 "込むものである。 この書式には I<「変換指定」 (conversion specifications)> を"
10924 "含めることができ、変換指定があれば、その変換の結果は I<format> に続く "
10925 "I<pointer> 引き数が指す場所に格納される。 それぞれの I<pointer> 引き数の型"
10926 "は、対応する変換指定が返す値に 適合していなければならない。"
10927
10928 #. type: Plain text
10929 #: build/C/man3/scanf.3:115
10930 msgid ""
10931 "If the number of conversion specifications in I<format> exceeds the number "
10932 "of I<pointer> arguments, the results are undefined.  If the number of "
10933 "I<pointer> arguments exceeds the number of conversion specifications, then "
10934 "the excess I<pointer> arguments are evaluated, but are otherwise ignored."
10935 msgstr ""
10936 "I<format> 中の変換指定の個数が I<pointer> 引き数の数より多かった場合の結果は"
10937 "未定義である。 I<pointer> 引き数の数が変換指定の個数よりも多かった場合、 余分"
10938 "な I<pointer> 引き数の評価は行われるが、それ以外は行われず無視される。"
10939
10940 #. type: Plain text
10941 #: build/C/man3/scanf.3:127
10942 msgid ""
10943 "The B<scanf>()  function reads input from the standard input stream "
10944 "I<stdin>, B<fscanf>()  reads input from the stream pointer I<stream>, and "
10945 "B<sscanf>()  reads its input from the character string pointed to by I<str>."
10946 msgstr ""
10947 "B<scanf>()  関数は標準入力ストリーム I<stdin> からの入力を読み込む。 "
10948 "B<fscanf>()  はストリームポインタ I<stream> からの入力を読み込む。 B<sscanf>"
10949 "()  は文字列ポインタ I<str> で示された文字列からの入力を読み込む。"
10950
10951 #. type: Plain text
10952 #: build/C/man3/scanf.3:145
10953 msgid ""
10954 "The B<vfscanf>()  function is analogous to B<vfprintf>(3)  and reads input "
10955 "from the stream pointer I<stream> using a variable argument list of pointers "
10956 "(see B<stdarg>(3).  The B<vscanf>()  function scans a variable argument list "
10957 "from the standard input and the B<vsscanf>()  function scans it from a "
10958 "string; these are analogous to the B<vprintf>(3)  and B<vsprintf>(3)  "
10959 "functions respectively."
10960 msgstr ""
10961 "B<vfscanf>()  関数は B<vfprintf>(3)  と同様に、ストリームポインタ I<stream> "
10962 "からの入力をポインタの可変長引き数リストを用いて読み込む (B<stdarg>(3)  を参"
10963 "照)。 B<vscanf>()  関数は、可変長引き数のリストに基づき標準入力からの読み取り"
10964 "を行う。 B<vsscanf>()  関数はそのリストに基づき文字列から読み取る。 これらの"
10965 "関係は B<vprintf>(3)  と B<vsprintf>(3)  関数の関係と同様である。"
10966
10967 #. type: Plain text
10968 #: build/C/man3/scanf.3:159
10969 msgid ""
10970 "The I<format> string consists of a sequence of I<directives> which describe "
10971 "how to process the sequence of input characters.  If processing of a "
10972 "directive fails, no further input is read, and B<scanf>()  returns.  A "
10973 "\"failure\" can be either of the following: I<input failure>, meaning that "
10974 "input characters were unavailable, or I<matching failure>, meaning that the "
10975 "input was inappropriate (see below)."
10976 msgstr ""
10977 "I<format> 文字列は I<「命令」 (directive)> の列で構成される。命令は入力文字の"
10978 "系列をどのように処理するかを指示する ものである。ある命令の処理が失敗すると、"
10979 "入力はそれ以上読み込まれず、 B<scanf>()  は返る。「失敗」は I<「入力の失敗」 "
10980 "(input failure)> と I<「一致の失敗」 (matching failure)> のいずれかである。 "
10981 "入力の失敗は入力文字が使用できなかったことを意味し、 一致の失敗は入力が不適切"
10982 "であったこと (下記参照) を意味する。"
10983
10984 #. type: Plain text
10985 #: build/C/man3/scanf.3:161
10986 msgid "A directive is one of the following:"
10987 msgstr "命令は以下のいずれかである:"
10988
10989 #. type: TP
10990 #: build/C/man3/scanf.3:161 build/C/man3/scanf.3:167 build/C/man3/scanf.3:171
10991 #: build/C/man3/scanf.3:190 build/C/man3/scanf.3:201 build/C/man3/scanf.3:220
10992 #: build/C/man3/scanf.3:232 build/C/man3/scanf.3:246
10993 #, no-wrap
10994 msgid "\\(bu"
10995 msgstr "\\(bu"
10996
10997 #. type: Plain text
10998 #: build/C/man3/scanf.3:167
10999 msgid ""
11000 "A sequence of white-space characters (space, tab, newline, etc.; see "
11001 "B<isspace>(3)).  This directive matches any amount of white space, including "
11002 "none, in the input."
11003 msgstr ""
11004 "ホワイトスペース (スペース、タブ、改行など; B<isspace>(3)  参照) の列。 この"
11005 "命令は、入力中の任意の個数のホワイトスペースに一致する。 (「何もなし」にも一"
11006 "致する)。"
11007
11008 #. type: Plain text
11009 #: build/C/man3/scanf.3:171
11010 msgid ""
11011 "An ordinary character (i.e., one other than white space or \\(aq%\\(aq).  "
11012 "This character must exactly match the next character of input."
11013 msgstr ""
11014 "通常文字 (つまり、ホワイトスペースと \\(aq%\\(aq 以外の文字)。 この文字は入力"
11015 "の次の文字に正確に一致しなければならない。"
11016
11017 #. type: Plain text
11018 #: build/C/man3/scanf.3:182
11019 msgid ""
11020 "A conversion specification, which commences with a \\(aq%\\(aq (percent) "
11021 "character.  A sequence of characters from the input is converted according "
11022 "to this specification, and the result is placed in the corresponding "
11023 "I<pointer> argument.  If the next item of input does not match the "
11024 "conversion specification, the conversion fails\\(emthis is a I<matching "
11025 "failure>."
11026 msgstr ""
11027 "変換指定。変換指定は \\(aq%\\(aq (パーセント) 文字で始まる。 入力された文字の"
11028 "系列はこの指定にもとづいて変換され、 変換結果は対応する I<pointer> 引き数が指"
11029 "す場所に格納される。 入力の次の文字が変換指定と一致しない場合は、変換は失敗す"
11030 "る \\(emこれが I<「一致の失敗」 (matching failure)> である。"
11031
11032 #. type: Plain text
11033 #: build/C/man3/scanf.3:190
11034 msgid ""
11035 "Each I<conversion specification> in I<format> begins with either the "
11036 "character \\(aq%\\(aq or the character sequence \"B<%>I<n>B<$>\" (see below "
11037 "for the distinction) followed by:"
11038 msgstr ""
11039 "I<format> 中の各々の I<「変換指定」> は文字 \\(aq%\\(aq か文字系列 \"B<"
11040 "%>I<n>B<$>\" (違いについては後述) で始まり、以下の要素が続く。"
11041
11042 #. type: Plain text
11043 #: build/C/man3/scanf.3:201
11044 msgid ""
11045 "An optional \\(aq*\\(aq assignment-suppression character: B<scanf>()  reads "
11046 "input as directed by the conversion specification, but discards the input.  "
11047 "No corresponding I<pointer> argument is required, and this specification is "
11048 "not included in the count of successful assignments returned by B<scanf>()."
11049 msgstr ""
11050 "代入抑制文字 \\(aq*\\(aq (省略可能)。 B<scanf>()  は変換指定に指示された通り"
11051 "入力を読み込むが、その入力は捨てられる。 対応する I<pointer> 引き数は必要な"
11052 "く、 B<scanf>()  が返す代入が成功した数にこの指定は含まれない。"
11053
11054 #. type: Plain text
11055 #: build/C/man3/scanf.3:220
11056 msgid ""
11057 "An optional \\(aqm\\(aq character.  This is used with string conversions (I<"
11058 "%s>, I<%c>, I<%[>), and relieves the caller of the need to allocate a "
11059 "corresponding buffer to hold the input: instead, B<scanf>()  allocates a "
11060 "buffer of sufficient size, and assigns the address of this buffer to the "
11061 "corresponding I<pointer> argument, which should be a pointer to a I<char\\ "
11062 "*> variable (this variable does not need to be initialized before the "
11063 "call).  The caller should subsequently B<free>(3)  this buffer when it is no "
11064 "longer required."
11065 msgstr "文字 \\(aqm\\(aq (省略可能)。これは文字列変換 (I<%s>, I<%c>, I<%[>) とともに使用され、これを使うと 呼び出し元が入力を保持する対応するバッファを確保する必要がなくなる。 代わりに B<scanf>()  が必要な大きさのバッファを確保し、このバッファのアドレスを 対応する I<pointer> 引き数に代入する。 I<pointer> 引き数は I<char\\ *> 型の変数へのポインタでなければならない (変数自体は呼び出し前に初期化されている必要はない)。 呼び出し元は、不要になった時点で、このバッファを B<free>(3) すべきである。"
11066
11067 #. type: Plain text
11068 #: build/C/man3/scanf.3:232
11069 msgid ""
11070 "An optional decimal integer which specifies the I<maximum field width>.  "
11071 "Reading of characters stops either when this maximum is reached or when a "
11072 "nonmatching character is found, whichever happens first.  Most conversions "
11073 "discard initial white space characters (the exceptions are noted below), and "
11074 "these discarded characters don't count toward the maximum field width.  "
11075 "String input conversions store a terminating null byte (\\(aq\\e0\\(aq)  to "
11076 "mark the end of the input; the maximum field width does not include this "
11077 "terminator."
11078 msgstr ""
11079 "I<「最大フィールド幅」> を指定する 10進数 (省略可能)。 この最大値に達するか、"
11080 "一致しない文字が見つかるか、のどちらかに なると、文字の読み込みを停止する。 "
11081 "ほとんどの変換では、先頭のホワイトスペース文字は捨てられ (例外については後述"
11082 "する)、 捨てられたこれらの文字は最大フィールド幅の計算には含まれない。 文字列"
11083 "の入力変換では、入力の末尾を示す終端の NULL バイト (\\(aq\\e0\\(aq)  も格納さ"
11084 "れるが、最大フィールド幅にはこの終端バイトは含まれない。"
11085
11086 #. type: Plain text
11087 #: build/C/man3/scanf.3:246
11088 msgid ""
11089 "An optional I<type modifier character>.  For example, the B<l> type modifier "
11090 "is used with integer conversions such as B<%d> to specify that the "
11091 "corresponding I<pointer> argument refers to a I<long int> rather than a "
11092 "pointer to an I<int>."
11093 msgstr ""
11094 "I<「型修飾子」 (type modifier characters)> (省略可能)。 例えば、型修飾子 "
11095 "B<l> を B<%d> などの整数変換と一緒に使うと、対応する I<pointer> 引き数が "
11096 "I<int> ではなく I<long int> を参照していることを指定できる。"
11097
11098 #. type: Plain text
11099 #: build/C/man3/scanf.3:251
11100 msgid ""
11101 "A I<conversion specifier> that specifies the type of input conversion to be "
11102 "performed."
11103 msgstr "I<「変換指定」> : 実行すべき入力変換の種類を指定する。"
11104
11105 #. type: Plain text
11106 #: build/C/man3/scanf.3:280
11107 msgid ""
11108 "The conversion specifications in I<format> are of two forms, either "
11109 "beginning with \\(aq%\\(aq or beginning with \"B<%>I<n>B<$>\".  The two "
11110 "forms should not be mixed in the same I<format> string, except that a string "
11111 "containing \"B<%>I<n>B<$>\" specifications can include B<%%> and B<%*>.  If "
11112 "I<format> contains \\(aq%\\(aq specifications then these correspond in order "
11113 "with successive I<pointer> arguments.  In the \"B<%>I<n>B<$>\" form (which "
11114 "is specified in POSIX.1-2001, but not C99), I<n> is a decimal integer that "
11115 "specifies that the converted input should be placed in the location referred "
11116 "to by the I<n>-th I<pointer> argument following I<format>."
11117 msgstr ""
11118 "I<format> 中の変換指定は、\\(aq%\\(aq で始まるか、 \"B<%>I<n>B<$>\" で始まる"
11119 "かの、いずれかの形式である。 これら 2つの形式を同じ I<format> 文字列に混ぜる"
11120 "ことはできない。但し、\"B<%>I<n>B<$>\" を 含む文字列に B<%%> と B<%*> を含め"
11121 "ることはできる。 I<format> に \\(aq%\\(aq 指定が含まれている場合、各々の "
11122 "\\(aq%\\(aq 指定と 後続の I<pointer> 引き数はその順番通りに対応する。 \"B<"
11123 "%>I<n>B<$>\" 形式 (POSIX.1-2001 では規定されているが、C99 にはない)  では、 "
11124 "I<n> は 10進数であり、変換後の入力を I<format> の後ろの I<n> 番目の "
11125 "I<pointer> 引き数が参照する場所に格納することを指定する。"
11126
11127 #. type: SS
11128 #: build/C/man3/scanf.3:280
11129 #, no-wrap
11130 msgid "Conversions"
11131 msgstr "変換"
11132
11133 #. type: Plain text
11134 #: build/C/man3/scanf.3:284
11135 msgid ""
11136 "The following I<type modifier characters> can appear in a conversion "
11137 "specification:"
11138 msgstr "変換指定には、以下の I<「型修飾子」> を入れることができる。"
11139
11140 #. type: Plain text
11141 #: build/C/man3/scanf.3:294
11142 msgid ""
11143 "Indicates that the conversion will be one of B<d>, B<i>, B<o>, B<u>, B<x>, "
11144 "B<X>, or B<n> and the next pointer is a pointer to a I<short int> or "
11145 "I<unsigned short int> (rather than I<int>)."
11146 msgstr ""
11147 "変換が B<d>, B<i>, B<o>, B<u>, B<x>, B<X>, B<n> のいずれかであり、次のポイン"
11148 "タが (I<int> ではなく)  I<short int> か I<unsigned short int> へのポインタで"
11149 "あることを示す。"
11150
11151 #. type: Plain text
11152 #: build/C/man3/scanf.3:302
11153 msgid ""
11154 "As for B<h>, but the next pointer is a pointer to a I<signed char> or "
11155 "I<unsigned char>."
11156 msgstr ""
11157 "B<h> と同じだが、次のポインタが I<signed char> か I<unsigned char> へのポイン"
11158 "タであることを示す。"
11159
11160 #. type: Plain text
11161 #: build/C/man3/scanf.3:311
11162 msgid ""
11163 "As for B<h>, but the next pointer is a pointer to an I<intmax_t> or a "
11164 "I<uintmax_t>.  This modifier was introduced in C99."
11165 msgstr ""
11166 "B<h> と同じだが、次のポインタが I<intmax_t> か I<uintmax_t> へのポインタであ"
11167 "ることを示す。 この修飾子は C99 で導入された。"
11168
11169 #.  This use of l was introduced in Amendment 1 to ISO C90.
11170 #. type: Plain text
11171 #: build/C/man3/scanf.3:338
11172 msgid ""
11173 "Indicates either that the conversion will be one of B<d>, B<i>, B<o>, B<u>, "
11174 "B<x>, B<X>, or B<n> and the next pointer is a pointer to a I<long int> or "
11175 "I<unsigned long int> (rather than I<int>), or that the conversion will be "
11176 "one of B<e>, B<f>, or B<g> and the next pointer is a pointer to I<double> "
11177 "(rather than I<float>).  Specifying two B<l> characters is equivalent to "
11178 "B<L>.  If used with B<%c> or B<%s> the corresponding parameter is considered "
11179 "as a pointer to a wide character or wide-character string respectively."
11180 msgstr ""
11181 "変換が B<d>, B<i>, B<o>, B<u>, B<x>, B<X>, B<n> か B<n> のいずれかであり次の"
11182 "ポインタが (I<int> ではなく)  I<long int> か I<unsigned long int> へのポイン"
11183 "タであること、または、変換が B<e>, B<f>, B<g> のうちのひとつであり次のポイン"
11184 "タが (I<float> ではなく)  I<double> へのポインタであることのいずれかであるこ"
11185 "とを示す。 B<l> 文字を二つ指定すると、 B<L> と同じ意味となる。 B<%c> や B<"
11186 "%s> とともに使用すると、 パラメータはそれぞれワイド文字やワイド文字列へのポイ"
11187 "ンタであると みなされる。"
11188
11189 #.  MTK, Jul 05: The following is no longer true for modern
11190 #.  ANSI C (i.e., C99):
11191 #.  (Note that long long is not an
11192 #.  ANSI C
11193 #.  type. Any program using this will not be portable to all
11194 #.  architectures).
11195 #. type: Plain text
11196 #: build/C/man3/scanf.3:354
11197 msgid ""
11198 "Indicates that the conversion will be either B<e>, B<f>, or B<g> and the "
11199 "next pointer is a pointer to I<long double> or the conversion will be B<d>, "
11200 "B<i>, B<o>, B<u>, or B<x> and the next pointer is a pointer to I<long long>."
11201 msgstr ""
11202 "B<e>, B<f>, B<g> 変換で、次のポインタが I<long double> へのポインタであること"
11203 "を示す。もしくは、 B<d>, B<i>, B<o>, B<u>, B<x> 変換で、次のポインタが "
11204 "I<long long> へのポインタであることのいずれかであることを示す。"
11205
11206 #. type: Plain text
11207 #: build/C/man3/scanf.3:359
11208 msgid "equivalent to B<L>.  This specifier does not exist in ANSI C."
11209 msgstr "B<L> と同一である。 この修飾子は ANSI C には存在しない。"
11210
11211 #. type: Plain text
11212 #: build/C/man3/scanf.3:366
11213 msgid ""
11214 "As for B<h>, but the next pointer is a pointer to a I<ptrdiff_t>.  This "
11215 "modifier was introduced in C99."
11216 msgstr ""
11217 "B<h> と同様だが、次のポインタが I<ptrdiff_t> へのポインタであることを示す。 "
11218 "この修飾子は C99 で導入された。"
11219
11220 #. type: Plain text
11221 #: build/C/man3/scanf.3:373
11222 msgid ""
11223 "As for B<h>, but the next pointer is a pointer to a I<size_t>.  This "
11224 "modifier was introduced in C99."
11225 msgstr ""
11226 "B<h> と同様だが、次のポインタが I<size_t> へのポインタであることを示す。 この"
11227 "修飾子は C99 で導入された。"
11228
11229 #. type: Plain text
11230 #: build/C/man3/scanf.3:377
11231 msgid "The following I<conversion specifiers> are available:"
11232 msgstr "以下の I<「変換指定子」> が利用可能である。"
11233
11234 #. type: Plain text
11235 #: build/C/man3/scanf.3:386
11236 msgid ""
11237 "Matches a literal \\(aq%\\(aq.  That is, B<%\\&%> in the format string "
11238 "matches a single input \\(aq%\\(aq character.  No conversion is done (but "
11239 "initial white space characters are discarded), and assignment does not occur."
11240 msgstr ""
11241 "文字 \\(aq%\\(aq に対応する。 書式文字列の中の B<%\\&%> は単一の文字 \\(aq%"
11242 "\\(aq に対応する。 変換は行われず (但し、先頭のホワイトスペース文字は捨てられ"
11243 "る)、 変数への代入は生じない。"
11244
11245 #. type: TP
11246 #: build/C/man3/scanf.3:386
11247 #, no-wrap
11248 msgid "B<d>"
11249 msgstr "B<d>"
11250
11251 #. type: Plain text
11252 #: build/C/man3/scanf.3:391
11253 msgid ""
11254 "Matches an optionally signed decimal integer; the next pointer must be a "
11255 "pointer to I<int>."
11256 msgstr ""
11257 "符号つきの 10進の整数に対応する。 次のポインタは I<int> へのポインタでなけれ"
11258 "ばならない。"
11259
11260 #. type: TP
11261 #: build/C/man3/scanf.3:391
11262 #, no-wrap
11263 msgid "B<D>"
11264 msgstr "B<D>"
11265
11266 #. type: Plain text
11267 #: build/C/man3/scanf.3:400
11268 msgid ""
11269 "Equivalent to I<ld>; this exists only for backward compatibility.  (Note: "
11270 "thus only in libc4.  In libc5 and glibc the B<%D> is silently ignored, "
11271 "causing old programs to fail mysteriously.)"
11272 msgstr ""
11273 "I<ld> と同一である。これは以前の仕様との互換性だけのためにある。 (注意: これ"
11274 "は libc4 の場合だけである。 libc5 や glibc では B<%D> は暗黙のうちに無視さ"
11275 "れ、古いプログラムにおいて謎に満ちた失敗の原因となる。)"
11276
11277 #. type: TP
11278 #: build/C/man3/scanf.3:400
11279 #, no-wrap
11280 msgid "B<i>"
11281 msgstr "B<i>"
11282
11283 #. type: Plain text
11284 #: build/C/man3/scanf.3:412
11285 msgid ""
11286 "Matches an optionally signed integer; the next pointer must be a pointer to "
11287 "I<int>.  The integer is read in base 16 if it begins with I<0x> or I<0X>, in "
11288 "base 8 if it begins with I<0>, and in base 10 otherwise.  Only characters "
11289 "that correspond to the base are used."
11290 msgstr ""
11291 "符号つき整数に対応する。 次のポインタは I<int> へのポインタでなければならな"
11292 "い。 この整数は I<0x> または I<0X> で開始する場合には 16 進数、 I<0> で開始す"
11293 "る場合には 8 進数、その他の場合には 10進数として読み込まれる。 この変換で使用"
11294 "される文字は、これらの基数に対応しているものだけである。"
11295
11296 #. type: TP
11297 #: build/C/man3/scanf.3:412
11298 #, no-wrap
11299 msgid "B<o>"
11300 msgstr "B<o>"
11301
11302 #. type: Plain text
11303 #: build/C/man3/scanf.3:416
11304 msgid ""
11305 "Matches an unsigned octal integer; the next pointer must be a pointer to "
11306 "I<unsigned int>."
11307 msgstr ""
11308 "符号なしの 8 進の整数に対応する。 次のポインタは I<unsigned int> でなければな"
11309 "らない。"
11310
11311 #. type: TP
11312 #: build/C/man3/scanf.3:416
11313 #, no-wrap
11314 msgid "B<u>"
11315 msgstr "B<u>"
11316
11317 #. type: Plain text
11318 #: build/C/man3/scanf.3:421
11319 msgid ""
11320 "Matches an unsigned decimal integer; the next pointer must be a pointer to "
11321 "I<unsigned int>."
11322 msgstr ""
11323 "符号なしの 10進の整数に対応する。 次のポインタは I<unsigned int> へのポインタ"
11324 "でなければならない。"
11325
11326 #. type: Plain text
11327 #: build/C/man3/scanf.3:426
11328 msgid ""
11329 "Matches an unsigned hexadecimal integer; the next pointer must be a pointer "
11330 "to I<unsigned int>."
11331 msgstr ""
11332 "符号なしの 16 進の整数に対応する。 次のポインタは I<unsigned int> へのポイン"
11333 "タでなければならない。"
11334
11335 #. type: TP
11336 #: build/C/man3/scanf.3:426
11337 #, no-wrap
11338 msgid "B<X>"
11339 msgstr "B<X>"
11340
11341 #. type: Plain text
11342 #: build/C/man3/scanf.3:430
11343 msgid "Equivalent to B<x>."
11344 msgstr "B<x> と同一である。"
11345
11346 #. type: TP
11347 #: build/C/man3/scanf.3:430
11348 #, no-wrap
11349 msgid "B<f>"
11350 msgstr "B<f>"
11351
11352 #. type: Plain text
11353 #: build/C/man3/scanf.3:435
11354 msgid ""
11355 "Matches an optionally signed floating-point number; the next pointer must be "
11356 "a pointer to I<float>."
11357 msgstr ""
11358 "符号つき浮動小数点実数に対応する。 次のポインタは I<float> へのポインタでなけ"
11359 "ればならない。"
11360
11361 #. type: TP
11362 #: build/C/man3/scanf.3:435
11363 #, no-wrap
11364 msgid "B<e>"
11365 msgstr "B<e>"
11366
11367 #. type: Plain text
11368 #: build/C/man3/scanf.3:439 build/C/man3/scanf.3:443 build/C/man3/scanf.3:447
11369 msgid "Equivalent to B<f>."
11370 msgstr "B<f> と同一である。"
11371
11372 #. type: TP
11373 #: build/C/man3/scanf.3:439
11374 #, no-wrap
11375 msgid "B<g>"
11376 msgstr "B<g>"
11377
11378 #. type: TP
11379 #: build/C/man3/scanf.3:443
11380 #, no-wrap
11381 msgid "B<E>"
11382 msgstr "B<E>"
11383
11384 #. type: Plain text
11385 #: build/C/man3/scanf.3:451
11386 msgid "(C99) Equivalent to B<f>."
11387 msgstr "(C99)  B<f> と同一である。"
11388
11389 #. type: Plain text
11390 #: build/C/man3/scanf.3:459
11391 msgid ""
11392 "Matches a sequence of non-white-space characters; the next pointer must be a "
11393 "pointer to character array that is long enough to hold the input sequence "
11394 "and the terminating null byte (\\(aq\\e0\\(aq), which is added "
11395 "automatically.  The input string stops at white space or at the maximum "
11396 "field width, whichever occurs first."
11397 msgstr ""
11398 "ホワイトスペースではない文字で構成された文字列に対応する。 次のポインタは文字"
11399 "の配列へのポインタでなければならず、 その文字配列は、入力された文字列と (自動"
11400 "的に追加される) 終端の NULL バイト (\\(aq\\e0\\(aq) を格納するのに十分な大き"
11401 "さでなければならない。 文字列の入力は、ホワイトスペースが入力されるか、最大"
11402 "フィールド幅に 達するか、のどちらかが起こると停止される。"
11403
11404 #. type: Plain text
11405 #: build/C/man3/scanf.3:469
11406 msgid ""
11407 "Matches a sequence of characters whose length is specified by the I<maximum "
11408 "field width> (default 1); the next pointer must be a pointer to I<char>, and "
11409 "there must be enough room for all the characters (no terminating null byte "
11410 "is added).  The usual skip of leading white space is suppressed.  To skip "
11411 "white space first, use an explicit space in the format."
11412 msgstr ""
11413 "I<「最大フィールド幅」> (デフォルトは 1) で指定された幅の文字の列に対応す"
11414 "る。 次のポインタは I<char> へのポインタで、すべての文字を格納するのに十分な"
11415 "領域が なければならない (終端の NULL バイトは追加されない)。 通常行われる先頭"
11416 "のホワイトスペースの読み飛ばしは行われない。 先頭のホワイトスペースを読み飛ば"
11417 "すためには、 フォーマット文の中で明示的にスペースを使用すれば良い。"
11418
11419 #. type: TP
11420 #: build/C/man3/scanf.3:469
11421 #, no-wrap
11422 msgid "B<\\&[>"
11423 msgstr "B<\\&[>"
11424
11425 #. type: Plain text
11426 #: build/C/man3/scanf.3:502
11427 msgid ""
11428 "Matches a nonempty sequence of characters from the specified set of accepted "
11429 "characters; the next pointer must be a pointer to I<char>, and there must be "
11430 "enough room for all the characters in the string, plus a terminating null "
11431 "byte.  The usual skip of leading white space is suppressed.  The string is "
11432 "to be made up of characters in (or not in) a particular set; the set is "
11433 "defined by the characters between the open bracket B<[> character and a "
11434 "close bracket B<]> character.  The set I<excludes> those characters if the "
11435 "first character after the open bracket is a circumflex (B<^>).  To include a "
11436 "close bracket in the set, make it the first character after the open bracket "
11437 "or the circumflex; any other position will end the set.  The hyphen "
11438 "character B<-> is also special; when placed between two other characters, it "
11439 "adds all intervening characters to the set.  To include a hyphen, make it "
11440 "the last character before the final close bracket.  For instance, B<[^]0-9-]"
11441 "> means the set \"everything except close bracket, zero through nine, and "
11442 "hyphen\".  The string ends with the appearance of a character not in the "
11443 "(or, with a circumflex, in) set or when the field width runs out."
11444 msgstr ""
11445 "格納された文字列のうちから取り出された、 指定された文字の集合で構成される空で"
11446 "はない文字の列に対応する。 次のポインタは I<char> へのポインタでなければなら"
11447 "ず、 そこには文字列中のすべての文字と終端の NULL バイト を格納するための十分"
11448 "な領域がなければならない。 通常行われる先頭のホワイトスペースの読み飛ばしは行"
11449 "われない。 この文字列は特別な集合の中の文字で構成されている。 この集合は 開き"
11450 "括弧 B<[> と閉じ括弧 B<]> の間の文字で定義される。 開き括弧のあとの最初の文字"
11451 "が曲アクセント記号 (B<^>)  の場合、集合はこれらの文字を含まないものとなる。 "
11452 "閉じ括弧を集合に含ませるためには、この文字を開き括弧または 曲アクセント記号の"
11453 "あとの最初の文字にすればよい。 つまり、他の位置に閉じ括弧を置くと文字の集合が"
11454 "終る。 ハイフン B<-> もまた特殊文字である。 二つの異なる文字の間に置かれた"
11455 "時、この文字は、 その間にある全ての文字を集合に加える。 ハイフン自体を含ませ"
11456 "るためには、 括弧が閉じる前の最後の一文字をハイフンにすればよい。 例えば、 B<"
11457 "[^]0-9-]> は「閉じ括弧、0 〜 9、ハイフンの 3 種類を除く全ての文字」の集合を意"
11458 "味する。 この文字列は 集合に含まれていない (曲アクセントの場合には含まれる) "
11459 "文字の 出現または確保された領域が使い切られた時に終了する。"
11460
11461 #. type: Plain text
11462 #: build/C/man3/scanf.3:510
11463 msgid ""
11464 "Matches a pointer value (as printed by B<%p> in B<printf>(3); the next "
11465 "pointer must be a pointer to a pointer to I<void>."
11466 msgstr ""
11467 "(B<printf>(3)  の B<%p> で印字されるような) ポインタ値に対応する。 次のポイン"
11468 "タは I<void> へのポインタへのポインタでなければならない。"
11469
11470 #. type: Plain text
11471 #: build/C/man3/scanf.3:530
11472 msgid ""
11473 "Nothing is expected; instead, the number of characters consumed thus far "
11474 "from the input is stored through the next pointer, which must be a pointer "
11475 "to I<int>.  This is I<not> a conversion, although it can be suppressed with "
11476 "the B<*> assignment-suppression character.  The C standard says: \"Execution "
11477 "of a B<%n> directive does not increment the assignment count returned at the "
11478 "completion of execution\" but the Corrigendum seems to contradict this.  "
11479 "Probably it is wise not to make any assumptions on the effect of B<%n> "
11480 "conversions on the return value."
11481 msgstr ""
11482 "どんな入力も必要としない。 そのかわりに、 入力からここまで消費された文字数が"
11483 "次のポインタで指定された場所に 格納される。 このポインタは I<int> へのポイン"
11484 "タでなければならない。 変換を抑制するのであれば B<*> 代入抑制文字を使って抑制"
11485 "することができるのだが、 この変換指定子は変換では「ない」。 C 言語の標準規格"
11486 "では「実行の完了時に返される代入の回数は B<%n> 命令の実行では増加しない」と"
11487 "なっているが、 正誤表の内容はこれと矛盾するようである。おそらく、 B<%n> 変換"
11488 "が返り値に与える影響についてはどのような仮定もしないのが 賢明であろう。"
11489
11490 #. type: Plain text
11491 #: build/C/man3/scanf.3:535
11492 msgid ""
11493 "These functions return the number of input items successfully matched and "
11494 "assigned, which can be fewer than provided for, or even zero in the event of "
11495 "an early matching failure."
11496 msgstr ""
11497 "これらの関数は、一致と代入が成功した入力要素の個数を返す。 返される値は渡され"
11498 "た変換の個数よりも少ないこともあり、 最初に一致の失敗があった場合には 0 にな"
11499 "ることもある。"
11500
11501 #. type: Plain text
11502 #: build/C/man3/scanf.3:547
11503 msgid ""
11504 "The value B<EOF> is returned if the end of input is reached before either "
11505 "the first successful conversion or a matching failure occurs.  B<EOF> is "
11506 "also returned if a read error occurs, in which case the error indicator for "
11507 "the stream (see B<ferror>(3))  is set, and I<errno> is set indicate the "
11508 "error."
11509 msgstr ""
11510 "最初の変換が成功する前に入力の最後に達して、一致の失敗が起こった場合には、 "
11511 "B<EOF> が返される。また、 読み込みエラーが発生した場合にも B<EOF> が返され"
11512 "る。読み込みエラーの場合には、そのストリームの エラー指示子がセットされ "
11513 "(B<ferror>(3)  参照)、 I<errno> にエラーを示す値がセットされる。"
11514
11515 #. type: Plain text
11516 #: build/C/man3/scanf.3:553
11517 msgid ""
11518 "The file descriptor underlying I<stream> is marked nonblocking, and the read "
11519 "operation would block."
11520 msgstr ""
11521 "I<stream> に対応するファイルディスクリプタが nonblocking となっており、 読み"
11522 "込み操作は停止 (block) することになる。"
11523
11524 #. type: Plain text
11525 #: build/C/man3/scanf.3:558
11526 msgid ""
11527 "The file descriptor underlying I<stream> is invalid, or not open for reading."
11528 msgstr ""
11529 "I<stream> に対応するファイルディスクリプタが無効であるが、 読み込み用にオープ"
11530 "ンされていない。"
11531
11532 #. type: Plain text
11533 #: build/C/man3/scanf.3:561
11534 msgid "Input byte sequence does not form a valid character."
11535 msgstr "入力されたバイト列が有効な文字を構成していない。"
11536
11537 #. type: Plain text
11538 #: build/C/man3/scanf.3:565
11539 msgid "The read operation was interrupted by a signal; see B<signal>(7)."
11540 msgstr "読み込み操作がシグナルにより割り込まれた。 B<signal>(7)  参照。"
11541
11542 #. type: Plain text
11543 #: build/C/man3/scanf.3:570
11544 msgid "Not enough arguments; or I<format> is NULL."
11545 msgstr "引き数が十分でない。または I<format> が NULL である。"
11546
11547 #. type: Plain text
11548 #: build/C/man3/scanf.3:573
11549 msgid "Out of memory."
11550 msgstr "メモリ不足。"
11551
11552 #. type: TP
11553 #: build/C/man3/scanf.3:573
11554 #, no-wrap
11555 msgid "B<ERANGE>"
11556 msgstr "B<ERANGE>"
11557
11558 #. type: Plain text
11559 #: build/C/man3/scanf.3:577
11560 msgid ""
11561 "The result of an integer conversion would exceed the size that can be stored "
11562 "in the corresponding integer type."
11563 msgstr "整数変換の結果が、対応する整数型に格納できるサイズを越えてしまう。"
11564
11565 #. type: Plain text
11566 #: build/C/man3/scanf.3:587
11567 msgid ""
11568 "The functions B<fscanf>(), B<scanf>(), and B<sscanf>()  conform to C89 and "
11569 "C99 and POSIX.1-2001.  These standards do not specify the B<ERANGE> error."
11570 msgstr ""
11571 "B<fscanf>(), B<scanf>(), B<sscanf>()  関数は C89, C99, POSIX.1-2001 に準拠し"
11572 "ている。 これらの標準では、エラー B<ERANGE> は規定されていない。"
11573
11574 #. type: Plain text
11575 #: build/C/man3/scanf.3:597
11576 msgid ""
11577 "The B<q> specifier is the 4.4BSD notation for I<long long>, while B<ll> or "
11578 "the usage of B<L> in integer conversions is the GNU notation."
11579 msgstr ""
11580 "B<q> 指定子は I<long long> の 4.4BSD での記述方法である。 一方、整数変換での "
11581 "B<ll> または B<L> の使用は GNU での拡張である。"
11582
11583 #. type: Plain text
11584 #: build/C/man3/scanf.3:608
11585 msgid ""
11586 "The Linux version of these functions is based on the I<GNU> I<libio> "
11587 "library.  Take a look at the I<info> documentation of I<GNU> I<libc "
11588 "(glibc-1.08)> for a more concise description."
11589 msgstr ""
11590 "これらの関数の Linux 版は I<GNU> I<libio> ライブラリーを元にしている。 より簡"
11591 "潔な説明には I<GNU> I<libc (glibc-1.08)> の I<info> 文書に目を通すこと。"
11592
11593 #. type: Plain text
11594 #: build/C/man3/scanf.3:614
11595 msgid ""
11596 "The GNU C library supported the dynamic allocation conversion specifier (as "
11597 "a nonstandard extension) via the B<a> character.  This feature seems to be "
11598 "present at least as far back as glibc 2.0."
11599 msgstr ""
11600 "GNU C ライブラリ (glibc) では、 B<a> 文字による動的割り当て変換指定子 "
11601 "(dynamic allocation conversion specifier) を (非標準の拡張として) サポートし"
11602 "ている。この機能は少なくとも glibc 2.0 以降で存在しているようである。"
11603
11604 #. type: Plain text
11605 #: build/C/man3/scanf.3:624
11606 msgid ""
11607 "It is not available if the program is compiled with I<gcc -std=c99> or I<gcc "
11608 "-D_ISOC99_SOURCE> (unless B<_GNU_SOURCE> is also specified), in which case "
11609 "the B<a> is interpreted as a specifier for floating-point numbers (see "
11610 "above)."
11611 msgstr ""
11612 "この修飾子は I<gcc -std=c99> や I<gcc -D_ISOC99_SOURCE> でコンパイルしたプロ"
11613 "グラムでは (B<_GNU_SOURCE> も同時に指定していない場合) 利用できない。この場"
11614 "合、 B<a> は (上述の通り) 浮動小数点数を示す変換指定子と解釈される。"
11615
11616 #. type: Plain text
11617 #: build/C/man3/scanf.3:633
11618 msgid ""
11619 "Since version 2.7, glibc also provides the B<m> modifier for the same "
11620 "purpose as the B<a> modifier.  The B<m> modifier has the following "
11621 "advantages:"
11622 msgstr ""
11623 "バージョン 2.7 以降では、glibc は B<a> 修飾子と同じ目的で B<m> 修飾子も提供し"
11624 "ている。 B<m> 修飾子は以下の利点がある。"
11625
11626 #. type: Plain text
11627 #: build/C/man3/scanf.3:638
11628 msgid "It may also be applied to B<%c> conversion specifiers (e.g., B<%3mc>)."
11629 msgstr "B<%c> 変換指定子にも適用できる (例えば B<%3mc>)。"
11630
11631 #. type: Plain text
11632 #: build/C/man3/scanf.3:644
11633 msgid ""
11634 "It avoids ambiguity with respect to the B<%a> floating-point conversion "
11635 "specifier (and is unaffected by I<gcc -std=c99> etc.)"
11636 msgstr ""
11637 "浮動小数点変換指定子としての B<%a> との紛らわしさが避けられる (また I<gcc -"
11638 "std=c99> などの影響も避けられる)。"
11639
11640 #. type: Plain text
11641 #: build/C/man3/scanf.3:646
11642 msgid "It is specified in the POSIX.1-2008 standard."
11643 msgstr "POSIX.1-2008 標準で規定されている。"
11644
11645 #. type: Plain text
11646 #: build/C/man3/scanf.3:659
11647 msgid ""
11648 "All functions are fully C89 conformant, but provide the additional "
11649 "specifiers B<q> and B<a> as well as an additional behavior of the B<L> and "
11650 "B<l> specifiers.  The latter may be considered to be a bug, as it changes "
11651 "the behavior of specifiers defined in C89."
11652 msgstr ""
11653 "全ての関数は、完全に C89 に準拠している。しかし 追加で B<q> と B<a> 指定子が"
11654 "提供されており、同様に B<L> と B<l> 指定子の付加的な振る舞いもある。後者は、 "
11655 "C89 で定義された指定子の振る舞いを変更するものなので、 バグとみなされるかもし"
11656 "れない。"
11657
11658 #. type: Plain text
11659 #: build/C/man3/scanf.3:675
11660 msgid ""
11661 "Some combinations of the type modifiers and conversion specifiers defined by "
11662 "ANSI C do not make sense (e.g., B<%Ld>).  While they may have a well-defined "
11663 "behavior on Linux, this need not to be so on other architectures.  Therefore "
11664 "it usually is better to use modifiers that are not defined by ANSI C at all, "
11665 "that is, use B<q> instead of B<L> in combination with B<d>, B<i>, B<o>, "
11666 "B<u>, B<x>, and B<X> conversions or B<ll>."
11667 msgstr ""
11668 "ANSI C で定義された型修飾子と変換指定子の組み合わせの中には 意味を\n"
11669 "なさないものがある (例えば、 B<%Ld>)。 これらが指定された場合、 \n"
11670 "Linux 上でははっきりと定義された振る舞いをするかもしれないが、\n"
11671 "他のアーキテクチャでも同様になっているとは限らない。\n"
11672 "それゆえに、ほとんどの場合、 ANSI C で定義されていない修飾子を使用した\n"
11673 "方が良い。すなわち、 B<d>, B<i>, B<o>, B<u>, B<x>, B<X> 変換や B<ll>\n"
11674 "と組み合わせる場合には、 B<L> の代わりに B<q> を使用した方が良い。"
11675
11676 #. type: Plain text
11677 #: build/C/man3/scanf.3:681
11678 msgid ""
11679 "The usage of B<q> is not the same as on 4.4BSD, as it may be used in float "
11680 "conversions equivalently to B<L>."
11681 msgstr ""
11682 "B<q> の使用方法は 4.4BSD と同じではない。 4.4BSD では B<q> は B<L> と同等に浮"
11683 "動小数の変換に使用される。"
11684
11685 #. type: Plain text
11686 #: build/C/man3/scanf.3:691
11687 msgid ""
11688 "To use the dynamic allocation conversion specifier, specify B<m> as a length "
11689 "modifier (thus B<%ms> or B<%m[>I<range>B<]>).  The caller must B<free>(3)  "
11690 "the returned string, as in the following example:"
11691 msgstr ""
11692 "動的割り当て変換指定子を使用するには、長さ修飾子として B<m> を指定する (つま"
11693 "り、全体としては B<%ms> や B<%m[>I<range>B<]> となる)。以下の例にあるように、"
11694 "呼び出し側は返された文字列を B<free>(3) しなければならない。"
11695
11696 #. type: Plain text
11697 #: build/C/man3/scanf.3:696
11698 #, no-wrap
11699 msgid ""
11700 "char *p;\n"
11701 "int n;\n"
11702 msgstr ""
11703 "char *p;\n"
11704 "int n;\n"
11705
11706 #. type: Plain text
11707 #: build/C/man3/scanf.3:707
11708 #, no-wrap
11709 msgid ""
11710 "errno = 0;\n"
11711 "n = scanf(\"%m[a-z]\", &p);\n"
11712 "if (n == 1) {\n"
11713 "    printf(\"read: %s\\en\", p);\n"
11714 "    free(p);\n"
11715 "} else if (errno != 0) {\n"
11716 "    perror(\"scanf\");\n"
11717 "} else {\n"
11718 "    fprintf(stderr, \"No matching characters\\en\");\n"
11719 "}\n"
11720 msgstr ""
11721 "errno = 0;\n"
11722 "n = scanf(\"%m[a-z]\", &p);\n"
11723 "if (n == 1) {\n"
11724 "    printf(\"read: %s\\en\", p);\n"
11725 "    free(p);\n"
11726 "} else if (errno != 0) {\n"
11727 "    perror(\"scanf\");\n"
11728 "} else {\n"
11729 "    fprintf(stderr, \"No matching characters\\en\");\n"
11730 "}\n"
11731
11732 #. type: Plain text
11733 #: build/C/man3/scanf.3:715
11734 msgid ""
11735 "As shown in the above example, it is necessary to call B<free>(3)  only if "
11736 "the B<scanf>()  call successfully read a string."
11737 msgstr ""
11738 "上記の例にあるように、 B<scanf>()  が文字列の読み込みに成功した場合にだけ、 "
11739 "B<free>(3)  を呼び出す必要がある。"
11740
11741 #. type: Plain text
11742 #: build/C/man3/scanf.3:722
11743 msgid ""
11744 "B<getc>(3), B<printf>(3), B<setlocale>(3), B<strtod>(3), B<strtol>(3), "
11745 "B<strtoul>(3)"
11746 msgstr ""
11747 "B<getc>(3), B<printf>(3)  B<setlocale>(3), B<strtod>(3), B<strtol>(3), "
11748 "B<strtoul>(3),"
11749
11750 #. type: TH
11751 #: build/C/man3/setbuf.3:48
11752 #, no-wrap
11753 msgid "SETBUF"
11754 msgstr "SETBUF"
11755
11756 #. type: TH
11757 #: build/C/man3/setbuf.3:48
11758 #, no-wrap
11759 msgid "2012-08-03"
11760 msgstr "2012-08-03"
11761
11762 #. type: Plain text
11763 #: build/C/man3/setbuf.3:51
11764 msgid "setbuf, setbuffer, setlinebuf, setvbuf - stream buffering operations"
11765 msgstr ""
11766 "setbuf, setbuffer, setlinebuf, setvbuf - ストリームのバッファリングの操作"
11767
11768 #. type: Plain text
11769 #: build/C/man3/setbuf.3:56
11770 #, no-wrap
11771 msgid "B<void setbuf(FILE *>I<stream>B<, char *>I<buf>B<);>\n"
11772 msgstr "B<void setbuf(FILE *>I<stream>B<, char *>I<buf>B<);>\n"
11773
11774 #. type: Plain text
11775 #: build/C/man3/setbuf.3:58
11776 #, no-wrap
11777 msgid "B<void setbuffer(FILE *>I<stream>B<, char *>I<buf>B<, size_t >I<size>B<);>\n"
11778 msgstr "B<void setbuffer(FILE *>I<stream>B<, char *>I<buf>B<, size_t >I<size>B<);>\n"
11779
11780 #. type: Plain text
11781 #: build/C/man3/setbuf.3:60
11782 #, no-wrap
11783 msgid "B<void setlinebuf(FILE *>I<stream>B<);>\n"
11784 msgstr "B<void setlinebuf(FILE *>I<stream>B<);>\n"
11785
11786 #. type: Plain text
11787 #: build/C/man3/setbuf.3:63
11788 #, no-wrap
11789 msgid "B<int setvbuf(FILE *>I<stream>B<, char *>I<buf>B<, int >I<mode>B<, size_t >I<size>B<);>\n"
11790 msgstr "B<int setvbuf(FILE *>I<stream>B<, char *>I<buf>B<, int >I<mode>B<, size_t >I<size>B<);>\n"
11791
11792 #. type: Plain text
11793 #: build/C/man3/setbuf.3:73
11794 msgid "B<setbuffer>(), B<setlinebuf>(): _BSD_SOURCE"
11795 msgstr "B<setbuffer>(), B<setlinebuf>(): _BSD_SOURCE"
11796
11797 #. type: Plain text
11798 #: build/C/man3/setbuf.3:96
11799 msgid ""
11800 "The three types of buffering available are unbuffered, block buffered, and "
11801 "line buffered.  When an output stream is unbuffered, information appears on "
11802 "the destination file or terminal as soon as written; when it is block "
11803 "buffered many characters are saved up and written as a block; when it is "
11804 "line buffered characters are saved up until a newline is output or input is "
11805 "read from any stream attached to a terminal device (typically I<stdin>).  "
11806 "The function B<fflush>(3)  may be used to force the block out early.  (See "
11807 "B<fclose>(3).)  Normally all files are block buffered.  When the first I/O "
11808 "operation occurs on a file, B<malloc>(3)  is called, and a buffer is "
11809 "obtained.  If a stream refers to a terminal (as I<stdout> normally does) it "
11810 "is line buffered.  The standard error stream I<stderr> is always unbuffered "
11811 "by default."
11812 msgstr ""
11813 "バッファリングには unbuffered, block buffered, line buffered の3つのタイプが "
11814 "ある。出力ストリームのタイプが unbuffered の場合、データを書き込むとすぐに出 "
11815 "力先ファイルに書き込まれるかターミナルに表示される。block buffered の場合、"
11816 "文 字の読み書きはブロック単位でいっぺんに行われる。line buffered の場合、 新"
11817 "しい行が出力されるか、ターミナルデバイスに接続しているストリーム (通常、"
11818 "I<stdin>) から新しい行が入力されるまで文字がたくわえられる。 ブロックを強制的"
11819 "に出力するには B<fflush>(3)  関数を使う。 (B<fclose>(3)  を参照のこと) 通常、"
11820 "ファイルはすべて block buffered である。ファイルに対して 初めて入出力処理を行"
11821 "うと B<malloc>(3)  が呼び出されバッファが獲得される。もし ストリームが (通"
11822 "常、 I<stdout> がそうであるように) ターミナルを参照する場合には、ファイルは "
11823 "line buffered と なる。標準エラー出力 I<stderr> はデフォルトでは常に "
11824 "unbuffered である。"
11825
11826 #. type: Plain text
11827 #: build/C/man3/setbuf.3:103
11828 msgid ""
11829 "The B<setvbuf>()  function may be used on any open stream to change its "
11830 "buffer.  The I<mode> argument must be one of the following three macros:"
11831 msgstr ""
11832 "B<setvbuf>()  関数は、オープンしている任意のストリームに対してバッファを変更"
11833 "できる。 引き数 I<mode> は、次の 3 つのマクロのうちいずれかである:"
11834
11835 #. type: TP
11836 #: build/C/man3/setbuf.3:104
11837 #, no-wrap
11838 msgid "B<_IONBF>"
11839 msgstr "B<_IONBF>"
11840
11841 #. type: Plain text
11842 #: build/C/man3/setbuf.3:107
11843 msgid "unbuffered"
11844 msgstr "unbuffered"
11845
11846 #. type: TP
11847 #: build/C/man3/setbuf.3:107
11848 #, no-wrap
11849 msgid "B<_IOLBF>"
11850 msgstr "B<_IOLBF>"
11851
11852 #. type: Plain text
11853 #: build/C/man3/setbuf.3:110
11854 msgid "line buffered"
11855 msgstr "line buffered"
11856
11857 #. type: TP
11858 #: build/C/man3/setbuf.3:110
11859 #, no-wrap
11860 msgid "B<_IOFBF>"
11861 msgstr "B<_IOFBF>"
11862
11863 #. type: Plain text
11864 #: build/C/man3/setbuf.3:113
11865 msgid "fully buffered"
11866 msgstr "fully buffered"
11867
11868 #. type: Plain text
11869 #: build/C/man3/setbuf.3:129
11870 msgid ""
11871 "Except for unbuffered files, the I<buf> argument should point to a buffer at "
11872 "least I<size> bytes long; this buffer will be used instead of the current "
11873 "buffer.  If the argument I<buf> is NULL, only the mode is affected; a new "
11874 "buffer will be allocated on the next read or write operation.  The B<setvbuf>"
11875 "()  function may be used only after opening a stream and before any other "
11876 "operations have been performed on it."
11877 msgstr ""
11878 "unbuffered のファイルを除き、 I<buf> 引数は I<size> バイト以上の大きさのバッ"
11879 "ファを指していなければならない。このバッファは現在の バッファの代わりに用いら"
11880 "れる。もし、引数 I<buf> が NULL ならば、モードだけが変更される。 新しいバッ"
11881 "ファは次に読み書きした際に割り当てられる。 B<setvbuf>()  関数は、ストリームを"
11882 "オープンした後、 そのストリームに対して何らかの操作をする前にのみ使用できる。"
11883
11884 #. type: Plain text
11885 #: build/C/man3/setbuf.3:135
11886 msgid ""
11887 "The other three calls are, in effect, simply aliases for calls to B<setvbuf>"
11888 "().  The B<setbuf>()  function is exactly equivalent to the call"
11889 msgstr ""
11890 "他の 3 つの関数は B<setvbuf>()  の呼び出しに単純に置き換えることができる。 "
11891 "B<setbuf>()  関数は、"
11892
11893 #. type: Plain text
11894 #: build/C/man3/setbuf.3:138
11895 msgid "setvbuf(stream, buf, buf ? _IOFBF : _IONBF, BUFSIZ);"
11896 msgstr "setvbuf(stream, buf, buf ? _IOFBF : _IONBF, BUFSIZ);"
11897
11898 #. type: Plain text
11899 #: build/C/man3/setbuf.3:148
11900 msgid ""
11901 "The B<setbuffer>()  function is the same, except that the size of the buffer "
11902 "is up to the caller, rather than being determined by the default B<BUFSIZ>.  "
11903 "The B<setlinebuf>()  function is exactly equivalent to the call:"
11904 msgstr ""
11905 "と全く同等だし、 B<setbuffer>()  関数は、バッファサイズがデフォルト値 "
11906 "B<BUFSIZ> ではなく引数で与えられる点以外は同じである。 B<setlinebuf>()  関数"
11907 "は以下と同じである。"
11908
11909 #. type: Plain text
11910 #: build/C/man3/setbuf.3:151
11911 msgid "setvbuf(stream, NULL, _IOLBF, 0);"
11912 msgstr "setvbuf(stream, NULL, _IOLBF, 0);"
11913
11914 #. type: Plain text
11915 #: build/C/man3/setbuf.3:162
11916 msgid ""
11917 "The function B<setvbuf>()  returns 0 on success.  It returns nonzero on "
11918 "failure (I<mode> is invalid or the request cannot be honored).  It may set "
11919 "I<errno> on failure."
11920 msgstr ""
11921 "B<setvbuf>()  関数は、成功した場合 0 を返す。 失敗した場合、0 以外の値を返す "
11922 "(失敗とは、 I<mode> が不正な場合またはリクエストが条件を満たさない場合であ"
11923 "る)。 B<setvbuf>()  関数が失敗した場合は I<errno> を設定することもある。"
11924
11925 #. type: Plain text
11926 #: build/C/man3/setbuf.3:164
11927 msgid "The other functions do not return a value."
11928 msgstr "その他の関数は値を返さない。"
11929
11930 #. type: Plain text
11931 #: build/C/man3/setbuf.3:170
11932 msgid "The B<setbuf>()  and B<setvbuf>()  functions conform to C89 and C99."
11933 msgstr ""
11934 "B<setbuf>()  関数および B<setvbuf>()  関数は C89 と C99 に準拠している。"
11935
11936 #. type: Plain text
11937 #: build/C/man3/setbuf.3:180
11938 msgid ""
11939 "The B<setbuffer>()  and B<setlinebuf>()  functions are not portable to "
11940 "versions of BSD before 4.2BSD, and are available under Linux since libc "
11941 "4.5.21.  On 4.2BSD and 4.3BSD systems, B<setbuf>()  always uses a suboptimal "
11942 "buffer size and should be avoided."
11943 msgstr ""
11944 "B<setbuffer>()  関数および B<setlinebuf>()  関数は 4.2BSD より前の BSD とは互"
11945 "換性がない。また Linux でも(古いバージョン では)利用できないかもしれない。"
11946 "4.2BSD および 4.3BSD のシステムでは B<setbuf>()  は必ず追加のバッファーのサイ"
11947 "ズを使用するので、これも使うべきでない。"
11948
11949 #. type: Plain text
11950 #: build/C/man3/setbuf.3:187
11951 msgid ""
11952 "You must make sure that the space that I<buf> points to still exists by the "
11953 "time I<stream> is closed, which also happens at program termination.  For "
11954 "example, the following is invalid:"
11955 msgstr ""
11956 "I<stream> を閉じる時 (プログラムを終了する際にもこれは起きる) には、 I<buf> "
11957 "が指し示す空間とが存在していることを保証しなければならない。 例えば、次のよう"
11958 "な使い方は許されない:"
11959
11960 #. type: Plain text
11961 #: build/C/man3/setbuf.3:190
11962 #, no-wrap
11963 msgid "#include E<lt>stdio.hE<gt>\n"
11964 msgstr "#include E<lt>stdio.hE<gt>\n"
11965
11966 #. type: Plain text
11967 #: build/C/man3/setbuf.3:199
11968 #, no-wrap
11969 msgid ""
11970 "int\n"
11971 "main(void)\n"
11972 "{\n"
11973 "    char buf[BUFSIZ];\n"
11974 "    setbuf(stdin, buf);\n"
11975 "    printf(\"Hello, world!\\en\");\n"
11976 "    return 0;\n"
11977 "}\n"
11978 msgstr ""
11979 "int\n"
11980 "main(void)\n"
11981 "{\n"
11982 "    char buf[BUFSIZ];\n"
11983 "    setbuf(stdin, buf);\n"
11984 "    printf(\"Hello, world!\\en\");\n"
11985 "    return 0;\n"
11986 "}\n"
11987
11988 #. type: Plain text
11989 #: build/C/man3/setbuf.3:208
11990 msgid ""
11991 "B<fclose>(3), B<fflush>(3), B<fopen>(3), B<fread>(3), B<malloc>(3), B<printf>"
11992 "(3), B<puts>(3)"
11993 msgstr ""
11994 "B<fclose>(3), B<fflush>(3), B<fopen>(3), B<fread>(3), B<malloc>(3), B<printf>"
11995 "(3), B<puts>(3)"
11996
11997 #. type: TH
11998 #: build/C/man3/stdin.3:13
11999 #, no-wrap
12000 msgid "STDIN"
12001 msgstr "STDIN"
12002
12003 #. type: TH
12004 #: build/C/man3/stdin.3:13 build/C/man3/tmpfile.3:31
12005 #, no-wrap
12006 msgid "2008-07-14"
12007 msgstr "2008-07-14"
12008
12009 #. type: Plain text
12010 #: build/C/man3/stdin.3:16
12011 msgid "stdin, stdout, stderr - standard I/O streams"
12012 msgstr "stdin, stdout, stderr - 標準入出力ストリーム"
12013
12014 #. type: Plain text
12015 #: build/C/man3/stdin.3:23
12016 #, no-wrap
12017 msgid ""
12018 "B<extern FILE *>I<stdin>B<;>\n"
12019 "B<extern FILE *>I<stdout>B<;>\n"
12020 "B<extern FILE *>I<stderr>B<;>\n"
12021 msgstr ""
12022 "B<extern FILE *>I<stdin>B<;>\n"
12023 "B<extern FILE *>I<stdout>B<;>\n"
12024 "B<extern FILE *>I<stderr>B<;>\n"
12025
12026 #. type: Plain text
12027 #: build/C/man3/stdin.3:35
12028 msgid ""
12029 "Under normal circumstances every UNIX program has three streams opened for "
12030 "it when it starts up, one for input, one for output, and one for printing "
12031 "diagnostic or error messages.  These are typically attached to the user's "
12032 "terminal (see B<tty>(4)  but might instead refer to files or other devices, "
12033 "depending on what the parent process chose to set up.  (See also the "
12034 "\"Redirection\" section of B<sh>(1).)"
12035 msgstr ""
12036 "標準の環境では、 UNIX プログラムは起動時に、オープンされているストリー ムを "
12037 "3 つ与えられる。それぞれ入力用、出力用、診断メッセージやエラーメッ セージの表"
12038 "示用のものである。これらは通常ユーザの端末 (B<tty>(4)  を見よ) に接続されてい"
12039 "るが、親プロセスでの選択・設定によってファイル や他のデバイスに関連づけられて"
12040 "いることもある (B<sh>(1)  の「リダイレクション」セクションも参照のこと)。"
12041
12042 #. type: Plain text
12043 #: build/C/man3/stdin.3:45
12044 msgid ""
12045 "The input stream is referred to as \"standard input\"; the output stream is "
12046 "referred to as \"standard output\"; and the error stream is referred to as "
12047 "\"standard error\".  These terms are abbreviated to form the symbols used to "
12048 "refer to these files, namely I<stdin>, I<stdout>, and I<stderr>."
12049 msgstr ""
12050 "入力ストリームは \"standard input\" と呼ばれる。出力ストリームは \"standard "
12051 "output\"、エラーストリームは \"standard error\" と呼ばれる。 これらの用語を短"
12052 "縮したものがそれぞれのファイルを示すシンボルとなる。つ まり I<stdin>, "
12053 "I<stdout>, I<stderr> である。"
12054
12055 #. type: Plain text
12056 #: build/C/man3/stdin.3:54
12057 msgid ""
12058 "Each of these symbols is a B<stdio>(3)  macro of type pointer to I<FILE>, "
12059 "and can be used with functions like B<fprintf>(3)  or B<fread>(3)."
12060 msgstr ""
12061 "これらのシンボルは B<stdio>(3)  のマクロで、 FILE へのポインタ型である。した"
12062 "がって B<fprintf>(3)  や B<fread>(3)  などの関数とともに用いることができる。"
12063
12064 #. type: Plain text
12065 #: build/C/man3/stdin.3:63
12066 msgid ""
12067 "Since I<FILE>s are a buffering wrapper around UNIX file descriptors, the "
12068 "same underlying files may also be accessed using the raw UNIX file "
12069 "interface, that is, the functions like B<read>(2)  and B<lseek>(2)."
12070 msgstr ""
12071 "I<FILE> は UNIX のファイルディスクリプタにバッファ機能を追加したラッパー であ"
12072 "るから、これらのマクロにも対応するファイルがあり、 UNIX の raw ファ イルイン"
12073 "タフェース (B<read>(2)  や B<lseek>(2)  など) によってアクセスすることもでき"
12074 "る。"
12075
12076 #. type: Plain text
12077 #: build/C/man3/stdin.3:82
12078 msgid ""
12079 "On program startup, the integer file descriptors associated with the streams "
12080 "I<stdin>, I<stdout>, and I<stderr> are 0, 1, and 2, respectively.  The "
12081 "preprocessor symbols B<STDIN_FILENO>, B<STDOUT_FILENO>, and B<STDERR_FILENO> "
12082 "are defined with these values in I<E<lt>unistd.hE<gt>>.  (Applying B<freopen>"
12083 "(3)  to one of these streams can change the file descriptor number "
12084 "associated with the stream.)"
12085 msgstr ""
12086 "プログラムの起動時には、 ストリーム I<stdin>, I<stdout>, I<stderr> に結びつけ"
12087 "られているファイルディスクリプタの番号は、 それぞれ 0, 1, 2 である。 プリプロ"
12088 "セッサシンボル B<STDIN_FILENO>, B<STDOUT_FILENO>, B<STDERR_FILENO> は "
12089 "I<E<lt>unistd.hE<gt>> 中でそれぞれこれらの値に定義されている。 (これらのスト"
12090 "リームに対して B<freopen>(3)  を適用することで、そのストリームに関連付けられ"
12091 "たファイルディスクリプタ の番号を変更することができる。)"
12092
12093 #. type: Plain text
12094 #: build/C/man3/stdin.3:95
12095 msgid ""
12096 "Note that mixing use of I<FILE>s and raw file descriptors can produce "
12097 "unexpected results and should generally be avoided.  (For the masochistic "
12098 "among you: POSIX.1, section 8.2.3, describes in detail how this interaction "
12099 "is supposed to work.)  A general rule is that file descriptors are handled "
12100 "in the kernel, while stdio is just a library.  This means for example, that "
12101 "after an B<exec>(3), the child inherits all open file descriptors, but all "
12102 "old streams have become inaccessible."
12103 msgstr ""
12104 "I<FILE> と raw なファイルディスクリプタの併用は、予期できない結果を生じ るこ"
12105 "とがあるので、通常は避けるべきである。 (マゾヒスティックな人に: POSIX.1 のセ"
12106 "クション 8.2.3 には、この混用で動作がどのようになりそう かが詳しく記述されて"
12107 "いる。)  一般的なルールは以下の通り: ファイルディスクリプタはカーネルによっ"
12108 "て 扱われ、 stdio は単にライブラリによって扱われるのである。すなわち例えば "
12109 "B<exec>(3)  の後には、子プロセスはオープンされているファイルディスクリプタ を"
12110 "すべて継承するが、親からのストリームはすべてアクセス不可となる。"
12111
12112 #. type: Plain text
12113 #: build/C/man3/stdin.3:113
12114 msgid ""
12115 "Since the symbols I<stdin>, I<stdout>, and I<stderr> are specified to be "
12116 "macros, assigning to them is nonportable.  The standard streams can be made "
12117 "to refer to different files with help of the library function B<freopen>(3), "
12118 "specially introduced to make it possible to reassign I<stdin>, I<stdout>, "
12119 "and I<stderr>.  The standard streams are closed by a call to B<exit>(3)  and "
12120 "by normal program termination."
12121 msgstr ""
12122 "シンボル I<stdin>, I<stdout>, I<stderr> はすべてマクロとして定義されているの"
12123 "で、これらへの代入 は移植性を保証されない。標準ストリームはライブラリ関数 "
12124 "B<freopen>(3)  を用いれば、別のファイルを示すように変更することもできる。 こ"
12125 "のライブラリ関数は I<stdin>, I<stdout>, I<stderr> の再割り当てが可能なように"
12126 "特別に導入されたものである。 標準ストリームは B<exit>(3)  の呼び出しと、プロ"
12127 "グラムの正常終了によってクローズされる。"
12128
12129 #. type: Plain text
12130 #: build/C/man3/stdin.3:122
12131 msgid ""
12132 "The I<stdin>, I<stdout>, and I<stderr> macros conform to C89 and this "
12133 "standard also stipulates that these three streams shall be open at program "
12134 "startup."
12135 msgstr ""
12136 "I<stdin>, I<stdout>, I<stderr> マクロは C89 に準拠している。 また C89 では、"
12137 "これら 3 つのストリームがプログラム の起動時にオープンされているべきであるこ"
12138 "とが規定されている。"
12139
12140 #. type: Plain text
12141 #: build/C/man3/stdin.3:154
12142 msgid ""
12143 "The stream I<stderr> is unbuffered.  The stream I<stdout> is line-buffered "
12144 "when it points to a terminal.  Partial lines will not appear until B<fflush>"
12145 "(3)  or B<exit>(3)  is called, or a newline is printed.  This can produce "
12146 "unexpected results, especially with debugging output.  The buffering mode of "
12147 "the standard streams (or any other stream)  can be changed using the "
12148 "B<setbuf>(3)  or B<setvbuf>(3)  call.  Note that in case I<stdin> is "
12149 "associated with a terminal, there may also be input buffering in the "
12150 "terminal driver, entirely unrelated to stdio buffering.  (Indeed, normally "
12151 "terminal input is line buffered in the kernel.)  This kernel input handling "
12152 "can be modified using calls like B<tcsetattr>(3); see also B<stty>(1), and "
12153 "B<termios>(3)."
12154 msgstr ""
12155 "I<stderr> ストリームはバッファリングされていない。 I<stdout> ストリームは、端"
12156 "末に接続されているときには行単位でバッファリング されている。一行に満たない内"
12157 "容は、 B<fflush>(3)  か B<exit>(3)  が呼び出されるか、改行文字が印字されるま"
12158 "で表示されない。これは、 特にデバッグ時において、予期しない結果を生じる原因と"
12159 "なるかもしれない。 標準ストリームの (あるいは他のすべてのストリームの)  バッ"
12160 "ファリングモードは、 B<setbuf>(3)  または B<setvbuf>(3)  を呼び出すことによっ"
12161 "て変更できる。 ただし、 I<stdin> が端末に接続されているときは、端末のドライバ"
12162 "でバッファリングされている 可能性がある点にも注意すること。これは stdio の"
12163 "バッファリングとは全く 関係なく存在しうる。 (実際、通常だと端末入力はカーネル"
12164 "によって行単位 でバッファリングされている。) このカーネルによる入力の扱いは "
12165 "B<tcsetattr>(3)  などの呼び出しによって変更することができる。 B<stty>(1)  と "
12166 "B<termios>(3)  も参照すること。"
12167
12168 #. type: Plain text
12169 #: build/C/man3/stdin.3:160
12170 msgid "B<csh>(1), B<sh>(1), B<open>(2), B<fopen>(3), B<stdio>(3)"
12171 msgstr "B<csh>(1), B<sh>(1), B<open>(2), B<fopen>(3), B<stdio>(3)"
12172
12173 #. type: TH
12174 #: build/C/man3/stdio.3:39
12175 #, no-wrap
12176 msgid "STDIO"
12177 msgstr "STDIO"
12178
12179 #. type: TH
12180 #: build/C/man3/stdio.3:39
12181 #, no-wrap
12182 msgid "2001-12-26"
12183 msgstr "2001-12-26"
12184
12185 #. type: Plain text
12186 #: build/C/man3/stdio.3:42
12187 msgid "stdio - standard input/output library functions"
12188 msgstr "stdio - 標準入出力ライブラリ関数"
12189
12190 #. type: Plain text
12191 #: build/C/man3/stdio.3:46
12192 msgid "B<FILE *>I<stdin>B<;>"
12193 msgstr "B<FILE *>I<stdin>B<;>"
12194
12195 #. type: Plain text
12196 #: build/C/man3/stdio.3:48
12197 msgid "B<FILE *>I<stdout>B<;>"
12198 msgstr "B<FILE *>I<stdout>B<;>"
12199
12200 #. type: Plain text
12201 #: build/C/man3/stdio.3:50
12202 msgid "B<FILE *>I<stderr>B<;>"
12203 msgstr "B<FILE *>I<stderr>B<;>"
12204
12205 #. type: Plain text
12206 #: build/C/man3/stdio.3:57
12207 msgid ""
12208 "The standard I/O library provides a simple and efficient buffered stream I/O "
12209 "interface.  Input and output is mapped into logical data streams and the "
12210 "physical I/O characteristics are concealed.  The functions and macros are "
12211 "listed below; more information is available from the individual man pages."
12212 msgstr ""
12213 "標準入出力ライブラリは、簡単かつ効果のよい、 バッファリングされたストリーム入"
12214 "出力インターフェースを提供する。 入力と出力は論理データストリームに割り付けら"
12215 "れ、 入出力の物理的な特徴は隠蔽される。 このライブラリに属する関数とマクロを"
12216 "以下に挙げる。 より詳しい情報は個々の man ページから得ることができる。"
12217
12218 #. type: Plain text
12219 #: build/C/man3/stdio.3:80
12220 msgid ""
12221 "A stream is associated with an external file (which may be a physical "
12222 "device) by I<opening> a file, which may involve creating a new file.  "
12223 "Creating an existing file causes its former contents to be discarded.  If a "
12224 "file can support positioning requests (such as a disk file, as opposed to a "
12225 "terminal) then a I<file position indicator> associated with the stream is "
12226 "positioned at the start of the file (byte zero), unless the file is opened "
12227 "with append mode.  If append mode is used, it is unspecified whether the "
12228 "position indicator will be placed at the start or the end of the file.  The "
12229 "position indicator is maintained by subsequent reads, writes and positioning "
12230 "requests.  All input occurs as if the characters were read by successive "
12231 "calls to the B<fgetc>(3)  function; all output takes place as if all "
12232 "characters were written by successive calls to the B<fputc>(3)  function."
12233 msgstr ""
12234 "ファイルを I<オープン (open) する> ことによって、 ストリームは外部ファイル "
12235 "(通常は物理デバイス) に連結される。 この操作には新しくファイルを作成すること"
12236 "も含まれる。 既存のファイルと同じ名前のファイルを新たに作ると、 もとのファイ"
12237 "ルの中身が捨てられてしまう。 ファイルが位置指定リクエストをサポートしている "
12238 "(ディスクファイルなどが相当する。逆の例としては端末が挙げられる) 場合、 その"
12239 "ストリームに連結された I<ファイル位置指示子 (file position indicator)> は、追"
12240 "加モードで開かれない限りファイルの先頭 (0 バイト目) に位置する。 追加モードを"
12241 "使用した場合、 位置指示子をファイルの先頭に置かれるか末尾に置かれるかは規定さ"
12242 "れていない。 位置指示子は、 以降の読み書きや位置指定リクエストによって変更さ"
12243 "れる。 すべての入力は、 B<fgetc>(3)  関数を次々に呼び出して文字を読み込んだか"
12244 "のように行われる。 一方すべての出力は、 B<fputc>(3)  関数を次々に呼び出して文"
12245 "字を書き込んだかのように行われる。"
12246
12247 #. type: Plain text
12248 #: build/C/man3/stdio.3:90
12249 msgid ""
12250 "A file is disassociated from a stream by I<closing> the file.  Output "
12251 "streams are flushed (any unwritten buffer contents are transferred to the "
12252 "host environment) before the stream is disassociated from the file.  The "
12253 "value of a pointer to a I<FILE> object is indeterminate after a file is "
12254 "closed (garbage)."
12255 msgstr ""
12256 "ファイルを I<クローズ (close) する> ことによって、そのファイルはストリームか"
12257 "ら切り離される。 出力ストリームは、そのストリームがファイルから切り離される前"
12258 "にフラッシュされる (書き込まれていないすべてのバッファの内容がホスト環境に転"
12259 "送される)。 I<FILE> オブジェクトへのポインタの値は、 ファイルを閉じた後では不"
12260 "確定になる (ゴミになってしまう)。"
12261
12262 #. type: Plain text
12263 #: build/C/man3/stdio.3:103
12264 msgid ""
12265 "A file may be subsequently reopened, by the same or another program "
12266 "execution, and its contents reclaimed or modified (if it can be repositioned "
12267 "at the start).  If the main function returns to its original caller, or the "
12268 "B<exit>(3)  function is called, all open files are closed (hence all output "
12269 "streams are flushed) before program termination.  Other methods of program "
12270 "termination, such as B<abort>(3)  do not bother about closing files properly."
12271 msgstr ""
12272 "ファイルはその後 (同じまたは別のプログラムによって)  再びオープンされることも"
12273 "あり、 その内容が修正されたり変更されたりする (そのファイルで先頭への位置移動"
12274 "が可能であれば)。 main 関数がもとの呼び出し側に返ったり、 B<exit>(3)  関数が"
12275 "呼ばれた場合、 プログラムの終了の前に 現在開いているすべてのファイルは閉じら"
12276 "れる (その結果、すべての出力ストリームはフラッシュされる)。 プログラムの停止"
12277 "に B<abort>(3)  のような他の方法を用いた場合には、 ファイルが正しく閉じられる"
12278 "保証はない。"
12279
12280 #. type: Plain text
12281 #: build/C/man3/stdio.3:119
12282 msgid ""
12283 "At program startup, three text streams are predefined and need not be opened "
12284 "explicitly: I<standard input> (for reading conventional input), I<standard "
12285 "output> (for writing conventional input), and I<standard error> (for writing "
12286 "diagnostic output).  These streams are abbreviated I<stdin>,I<stdout> and "
12287 "I<stderr>.  When opened, the standard error stream is not fully buffered; "
12288 "the standard input and output streams are fully buffered if and only if the "
12289 "streams do not refer to an interactive device."
12290 msgstr ""
12291 "プログラムの起動時に 3 個のテキストストリームが予め定義されており、 それらは"
12292 "明示的に開く必要がない。 I<標準入力 (standard input)> (通常の入力を読み取るの"
12293 "に使う)、 I<標準出力 (standard output)> (通常の出力を書き込むのに使う)、 I<標"
12294 "準エラー出力 (standard error)> (診断出力を書き込むのに使う) である。 これらの"
12295 "ストリームは I<stdin>, I<stdout>, I<stderr> と短縮して表現される。 オープンさ"
12296 "れたときには、 標準エラーストリームは 完全にはバッファリングされていない。 標"
12297 "準入力ストリームと標準出力ストリームは、 ストリームがインタラクティブなデバイ"
12298 "スを参照していなければ、 完全にバッファリングされている。"
12299
12300 #. type: Plain text
12301 #: build/C/man3/stdio.3:129
12302 msgid ""
12303 "Output streams that refer to terminal devices are always line buffered by "
12304 "default; pending output to such streams is written automatically whenever an "
12305 "input stream that refers to a terminal device is read.  In cases where a "
12306 "large amount of computation is done after printing part of a line on an "
12307 "output terminal, it is necessary to B<fflush>(3)  the standard output before "
12308 "going off and computing so that the output will appear."
12309 msgstr ""
12310 "端末デバイスを参照する出力ストリームは、 デフォルトでは常に行単位でバッファリ"
12311 "ングされている。 ただしそのようなストリームにおけるバッファ内の出力は、 端末"
12312 "デバイスを参照している入力ストリームからの読み込みがあるたびに、 自動的に書き"
12313 "込まれる。 出力端末に行の一部を書き込んだ後で大量の計算を行う場合、 出力が表"
12314 "示されるように、計算に取りかかる前に標準出力に対して B<fflush>(3)  を実行する"
12315 "必要がある。"
12316
12317 #. type: Plain text
12318 #: build/C/man3/stdio.3:143
12319 msgid ""
12320 "The I<stdio> library is a part of the library B<libc> and routines are "
12321 "automatically loaded as needed by the compilers B<cc>(1)  and B<pc>(1).  The "
12322 "SYNOPSIS sections of the following manual pages indicate which include files "
12323 "are to be used, what the compiler declaration for the function looks like "
12324 "and which external variables are of interest."
12325 msgstr ""
12326 "I<stdio> ライブラリは B<libc> ライブラリの一部であり、ルーチンは コンパイ"
12327 "ラー B<cc>(1)  と B<pc>(1)  によって必要な時に自動的に読み込まれる。 後述す"
12328 "る man ページ中の「書式」の節には、 どのインクルードファイルを使用しなければ"
12329 "ならないか、 その関数のコンパイラー宣言はどのようなものか、 どのような外部変"
12330 "数が関係するのかが示されている。"
12331
12332 #.  Not on Linux: .BR fropen ,
12333 #.  Not on Linux: .BR fwopen ,
12334 #. type: Plain text
12335 #: build/C/man3/stdio.3:183
12336 msgid ""
12337 "The following are defined as macros; these names may not be reused without "
12338 "first removing their current definitions with B<#undef>: B<BUFSIZ>, B<EOF>, "
12339 "B<FILENAME_MAX>, B<FOPEN_MAX>, B<L_cuserid>, B<L_ctermid>, B<L_tmpnam>, "
12340 "B<NULL>, B<SEEK_END>, B<SEEK_SET>, B<SEEK_CUR>, B<TMP_MAX>, B<clearerr>, "
12341 "B<feof>, B<ferror>, B<fileno>, B<getc>, B<getchar>, B<putc>, B<putchar>, "
12342 "B<stderr>, B<stdin>, B<stdout>.  Function versions of the macro functions "
12343 "B<feof>, B<ferror>, B<clearerr>, B<fileno>, B<getc>, B<getchar>, B<putc>, "
12344 "and B<putchar> exist and will be used if the macros definitions are "
12345 "explicitly removed."
12346 msgstr ""
12347 "B<BUFSIZ>, B<EOF>, B<FILENAME_MAX>, B<FOPEN_MAX>, B<L_cuserid>, "
12348 "B<L_ctermid>, B<L_tmpnam>, B<NULL>, B<SEEK_END>, B<SEEK_SET>, B<SEEK_CUR>, "
12349 "B<TMP_MAX>, B<clearerr>, B<feof>, B<ferror>, B<fileno>, B<getc>, B<getchar>, "
12350 "B<putc>, B<putchar>, B<stderr>, B<stdin>, B<stdout> はマクロとして定義されて"
12351 "いる。 これらの名前は、現在の定義を B<#undef> で削除しない限り、再利用するこ"
12352 "とはできない。 マクロ関数の関数版として、 B<feof>, B<ferror>, B<clearerr>, "
12353 "B<fileno>, B<getc>, B<getchar>, B<putc>, B<putchar> がある。 マクロの定義が明"
12354 "示的に消去されている場合には、 これらを使用することになるだろう。"
12355
12356 #. type: SS
12357 #: build/C/man3/stdio.3:183
12358 #, no-wrap
12359 msgid "List of functions"
12360 msgstr "関数のリスト"
12361
12362 #. type: tbl table
12363 #: build/C/man3/stdio.3:188
12364 #, no-wrap
12365 msgid "Function\tDescription\n"
12366 msgstr "関数\t説明\n"
12367
12368 #. type: tbl table
12369 #: build/C/man3/stdio.3:189
12370 #, no-wrap
12371 msgid "_\n"
12372 msgstr "_\n"
12373
12374 #. type: tbl table
12375 #: build/C/man3/stdio.3:190
12376 #, no-wrap
12377 msgid "clearerr\tcheck and reset stream status\n"
12378 msgstr "clearerr\tストリームの状態の確認とリセット\n"
12379
12380 #. type: tbl table
12381 #: build/C/man3/stdio.3:191
12382 #, no-wrap
12383 msgid "fclose\tclose a stream\n"
12384 msgstr "fclose\tストリームをクローズする\n"
12385
12386 #. type: tbl table
12387 #: build/C/man3/stdio.3:192
12388 #, no-wrap
12389 msgid "fdopen\tstream open functions\n"
12390 msgstr "fdopen\tストリームをオープンする\n"
12391
12392 #. type: tbl table
12393 #: build/C/man3/stdio.3:193
12394 #, no-wrap
12395 msgid "feof\tcheck and reset stream status\n"
12396 msgstr "feof\tストリームの状態の確認とリセット\n"
12397
12398 #. type: tbl table
12399 #: build/C/man3/stdio.3:194
12400 #, no-wrap
12401 msgid "ferror\tcheck and reset stream status\n"
12402 msgstr "ferror\tストリームの状態の確認とリセット\n"
12403
12404 #. type: tbl table
12405 #: build/C/man3/stdio.3:195
12406 #, no-wrap
12407 msgid "fflush\tflush a stream\n"
12408 msgstr "fflush\tストリームをフラッシュする\n"
12409
12410 #. type: tbl table
12411 #: build/C/man3/stdio.3:196
12412 #, no-wrap
12413 msgid "fgetc\tget next character or word from input stream\n"
12414 msgstr "fgetc\t次の文字または語を入力ストリームから獲得する\n"
12415
12416 #. type: tbl table
12417 #: build/C/man3/stdio.3:197
12418 #, no-wrap
12419 msgid "fgetpos\treposition a stream\n"
12420 msgstr "fgetpos\tストリームの位置を取得する\n"
12421
12422 #. type: tbl table
12423 #: build/C/man3/stdio.3:198
12424 #, no-wrap
12425 msgid "fgets\tget a line from a stream\n"
12426 msgstr "fgets\tストリームから行を取得する\n"
12427
12428 #. type: tbl table
12429 #: build/C/man3/stdio.3:199
12430 #, no-wrap
12431 msgid "fileno\treturn the integer descriptor of the argument stream\n"
12432 msgstr "fileno\t引き数であるストリームの整数値のディスクリプタを返す\n"
12433
12434 #. type: tbl table
12435 #: build/C/man3/stdio.3:200
12436 #, no-wrap
12437 msgid "fopen\tstream open functions\n"
12438 msgstr "fopen\tストリームをオープンする\n"
12439
12440 #. type: tbl table
12441 #: build/C/man3/stdio.3:201
12442 #, no-wrap
12443 msgid "fprintf\tformatted output conversion\n"
12444 msgstr "fprintf\t書式付き出力変換\n"
12445
12446 #. type: tbl table
12447 #: build/C/man3/stdio.3:202
12448 #, no-wrap
12449 msgid "fpurge\tflush a stream\n"
12450 msgstr "fpurge\tストリームをフラッシュする\n"
12451
12452 #. type: tbl table
12453 #: build/C/man3/stdio.3:203
12454 #, no-wrap
12455 msgid "fputc\toutput a character or word to a stream\n"
12456 msgstr "fputc\t文字または語をストリームに出力する\n"
12457
12458 #. type: tbl table
12459 #: build/C/man3/stdio.3:204
12460 #, no-wrap
12461 msgid "fputs\toutput a line to a stream\n"
12462 msgstr "fputs\t行をストリームに出力する\n"
12463
12464 #. type: tbl table
12465 #: build/C/man3/stdio.3:205
12466 #, no-wrap
12467 msgid "fread\tbinary stream input/output\n"
12468 msgstr "fread\tバイナリーストリーム入出力\n"
12469
12470 #. type: tbl table
12471 #: build/C/man3/stdio.3:206
12472 #, no-wrap
12473 msgid "freopen\tstream open functions\n"
12474 msgstr "freopen\tストリームをオープンする\n"
12475
12476 #. type: tbl table
12477 #: build/C/man3/stdio.3:207
12478 #, no-wrap
12479 msgid "fscanf\tinput format conversion\n"
12480 msgstr "fscanf\t書式付き入力変換\n"
12481
12482 #. type: tbl table
12483 #: build/C/man3/stdio.3:208
12484 #, no-wrap
12485 msgid "fseek\treposition a stream\n"
12486 msgstr "fseek\tストリームの位置指示子を移動する\n"
12487
12488 #. type: tbl table
12489 #: build/C/man3/stdio.3:209
12490 #, no-wrap
12491 msgid "fsetpos\treposition a stream\n"
12492 msgstr "fsetpos\tストリームの位置指示子を移動する\n"
12493
12494 #. type: tbl table
12495 #: build/C/man3/stdio.3:210
12496 #, no-wrap
12497 msgid "ftell\treposition a stream\n"
12498 msgstr "ftell\tストリームの位置を取得する\n"
12499
12500 #. type: tbl table
12501 #: build/C/man3/stdio.3:211
12502 #, no-wrap
12503 msgid "fwrite\tbinary stream input/output\n"
12504 msgstr "fwrite\tバイナリーストリーム入出力\n"
12505
12506 #. type: tbl table
12507 #: build/C/man3/stdio.3:212
12508 #, no-wrap
12509 msgid "getc\tget next character or word from input stream\n"
12510 msgstr "getc\t次の文字または語を入力ストリームから取得する\n"
12511
12512 #. type: tbl table
12513 #: build/C/man3/stdio.3:213
12514 #, no-wrap
12515 msgid "getchar\tget next character or word from input stream\n"
12516 msgstr "getchar\t次の文字または語を入力ストリームから取得する\n"
12517
12518 #. type: tbl table
12519 #: build/C/man3/stdio.3:214
12520 #, no-wrap
12521 msgid "gets\tget a line from a stream\n"
12522 msgstr "gets\t行を入力ストリームから取得する\n"
12523
12524 #. type: tbl table
12525 #: build/C/man3/stdio.3:215
12526 #, no-wrap
12527 msgid "getw\tget next character or word from input stream\n"
12528 msgstr "getw\t次の文字または語を入力ストリームから取得する\n"
12529
12530 #. type: tbl table
12531 #: build/C/man3/stdio.3:216
12532 #, no-wrap
12533 msgid "mktemp\tmake temporary filename (unique)\n"
12534 msgstr "mktemp\t他と重ならないテンポラリファイル名を作る\n"
12535
12536 #. type: tbl table
12537 #: build/C/man3/stdio.3:217
12538 #, no-wrap
12539 msgid "perror\tsystem error messages\n"
12540 msgstr "perror\tシステムエラーメッセージ\n"
12541
12542 #. type: tbl table
12543 #: build/C/man3/stdio.3:218
12544 #, no-wrap
12545 msgid "printf\tformatted output conversion\n"
12546 msgstr "printf\t書式付き出力変換\n"
12547
12548 #. type: tbl table
12549 #: build/C/man3/stdio.3:219
12550 #, no-wrap
12551 msgid "putc\toutput a character or word to a stream\n"
12552 msgstr "putc\t文字または語をストリームに出力する\n"
12553
12554 #. type: tbl table
12555 #: build/C/man3/stdio.3:220
12556 #, no-wrap
12557 msgid "putchar\toutput a character or word to a stream\n"
12558 msgstr "putchar\t文字または語をストリームに出力する\n"
12559
12560 #. type: tbl table
12561 #: build/C/man3/stdio.3:221
12562 #, no-wrap
12563 msgid "puts\toutput a line to a stream\n"
12564 msgstr "puts\t行をストリームに出力する\n"
12565
12566 #. type: tbl table
12567 #: build/C/man3/stdio.3:222
12568 #, no-wrap
12569 msgid "putw\toutput a character or word to a stream\n"
12570 msgstr "putw\t文字または語をストリームに出力する\n"
12571
12572 #. type: tbl table
12573 #: build/C/man3/stdio.3:223
12574 #, no-wrap
12575 msgid "remove\tremove directory entry\n"
12576 msgstr "remove\tディレクトリエントリを削除する\n"
12577
12578 #. type: tbl table
12579 #: build/C/man3/stdio.3:224
12580 #, no-wrap
12581 msgid "rewind\treposition a stream\n"
12582 msgstr "rewind\tストリームの位置指示子を移動する\n"
12583
12584 #. type: tbl table
12585 #: build/C/man3/stdio.3:225
12586 #, no-wrap
12587 msgid "scanf\tinput format conversion\n"
12588 msgstr "scanf\t書式付き入力変換\n"
12589
12590 #. type: tbl table
12591 #: build/C/man3/stdio.3:226
12592 #, no-wrap
12593 msgid "setbuf\tstream buffering operations\n"
12594 msgstr "setbuf\tストリームのバッファリングの操作\n"
12595
12596 #. type: tbl table
12597 #: build/C/man3/stdio.3:227
12598 #, no-wrap
12599 msgid "setbuffer\tstream buffering operations\n"
12600 msgstr "setbuffer\tストリームのバッファリングの操作\n"
12601
12602 #. type: tbl table
12603 #: build/C/man3/stdio.3:228
12604 #, no-wrap
12605 msgid "setlinebuf\tstream buffering operations\n"
12606 msgstr "setlinebuf\tストリームのバッファリングの操作\n"
12607
12608 #. type: tbl table
12609 #: build/C/man3/stdio.3:229
12610 #, no-wrap
12611 msgid "setvbuf\tstream buffering operations\n"
12612 msgstr "setvbuf\tストリームのバッファリングの操作\n"
12613
12614 #. type: tbl table
12615 #: build/C/man3/stdio.3:230
12616 #, no-wrap
12617 msgid "sprintf\tformatted output conversion\n"
12618 msgstr "sprintf\t書式付き出力変換\n"
12619
12620 #. type: tbl table
12621 #: build/C/man3/stdio.3:231
12622 #, no-wrap
12623 msgid "sscanf\tinput format conversion\n"
12624 msgstr "sscanf\t書式付き入力変換\n"
12625
12626 #. type: tbl table
12627 #: build/C/man3/stdio.3:232
12628 #, no-wrap
12629 msgid "strerror\tsystem error messages\n"
12630 msgstr "strerror\tシステムエラーメッセージ\n"
12631
12632 #. type: tbl table
12633 #: build/C/man3/stdio.3:233
12634 #, no-wrap
12635 msgid "sys_errlist\tsystem error messages\n"
12636 msgstr "sys_errlist\tシステムエラーメッセージ\n"
12637
12638 #. type: tbl table
12639 #: build/C/man3/stdio.3:234
12640 #, no-wrap
12641 msgid "sys_nerr\tsystem error messages\n"
12642 msgstr "sys_nerr\tシステムエラーメッセージ\n"
12643
12644 #. type: tbl table
12645 #: build/C/man3/stdio.3:235
12646 #, no-wrap
12647 msgid "tempnam\ttemporary file routines\n"
12648 msgstr "tempnam\tテンポラリファイルの操作\n"
12649
12650 #. type: tbl table
12651 #: build/C/man3/stdio.3:236
12652 #, no-wrap
12653 msgid "tmpfile\ttemporary file routines\n"
12654 msgstr "tmpfile\tテンポラリファイルの操作\n"
12655
12656 #. type: tbl table
12657 #: build/C/man3/stdio.3:237
12658 #, no-wrap
12659 msgid "tmpnam\ttemporary file routines\n"
12660 msgstr "tmpnam\tテンポラリファイルの操作\n"
12661
12662 #. type: tbl table
12663 #: build/C/man3/stdio.3:238
12664 #, no-wrap
12665 msgid "ungetc\tun-get character from input stream\n"
12666 msgstr "ungetc\t入力ストリームへ 1 文字戻す。\n"
12667
12668 #. type: tbl table
12669 #: build/C/man3/stdio.3:239
12670 #, no-wrap
12671 msgid "vfprintf\tformatted output conversion\n"
12672 msgstr "vfprintf\t書式付き出力変換\n"
12673
12674 #. type: tbl table
12675 #: build/C/man3/stdio.3:240
12676 #, no-wrap
12677 msgid "vfscanf\tinput format conversion\n"
12678 msgstr "vfscanf\t書式付き入力変換\n"
12679
12680 #. type: tbl table
12681 #: build/C/man3/stdio.3:241
12682 #, no-wrap
12683 msgid "vprintf\tformatted output conversion\n"
12684 msgstr "vprintf\t書式付き出力変換\n"
12685
12686 #. type: tbl table
12687 #: build/C/man3/stdio.3:242
12688 #, no-wrap
12689 msgid "vscanf\tinput format conversion\n"
12690 msgstr "vscanf\t書式付き入力変換\n"
12691
12692 #. type: tbl table
12693 #: build/C/man3/stdio.3:243
12694 #, no-wrap
12695 msgid "vsprintf\tformatted output conversion\n"
12696 msgstr "vsprintf\t書式付き出力変換\n"
12697
12698 #. type: tbl table
12699 #: build/C/man3/stdio.3:244
12700 #, no-wrap
12701 msgid "vsscanf\tinput format conversion\n"
12702 msgstr "vsscanf\t書式付き入力変換\n"
12703
12704 #. type: Plain text
12705 #: build/C/man3/stdio.3:250
12706 msgid "The I<stdio> library conforms to C89."
12707 msgstr "I<stdio> ライブラリは C89 に準拠している。"
12708
12709 #. type: Plain text
12710 #: build/C/man3/stdio.3:257
12711 msgid ""
12712 "B<close>(2), B<open>(2), B<read>(2), B<write>(2), B<stdout>(3), "
12713 "B<unlocked_stdio>(3)"
12714 msgstr ""
12715 "B<close>(2), B<open>(2), B<read>(2), B<write>(2), B<stdout>(3), "
12716 "B<unlocked_stdio>(3)"
12717
12718 #. type: TH
12719 #: build/C/man3/stdio_ext.3:25
12720 #, no-wrap
12721 msgid "STDIO_EXT"
12722 msgstr "STDIO_EXT"
12723
12724 #. type: Plain text
12725 #: build/C/man3/stdio_ext.3:30
12726 msgid ""
12727 "__fbufsize, __flbf, __fpending, __fpurge, __freadable, __freading, "
12728 "__fsetlocking, __fwritable, __fwriting, _flushlbf - interfaces to stdio FILE "
12729 "structure"
12730 msgstr ""
12731 "__fbufsize, __flbf, __fpending, __fpurge, __freadable, __freading, "
12732 "__fsetlocking, __fwritable, __fwriting, _flushlbf - 標準入出力ファイル構造体"
12733 "へのインタフェース"
12734
12735 #. type: Plain text
12736 #: build/C/man3/stdio_ext.3:34
12737 msgid "B<#include E<lt>stdio_ext.hE<gt>>"
12738 msgstr "B<#include E<lt>stdio_ext.hE<gt>>"
12739
12740 #. type: Plain text
12741 #: build/C/man3/stdio_ext.3:36
12742 msgid "B<size_t __fbufsize(FILE *>I<stream>B<);>"
12743 msgstr "B<size_t __fbufsize(FILE *>I<stream>B<);>"
12744
12745 #. type: Plain text
12746 #: build/C/man3/stdio_ext.3:38
12747 msgid "B<size_t __fpending(FILE *>I<stream>B<);>"
12748 msgstr "B<size_t __fpending(FILE *>I<stream>B<);>"
12749
12750 #. type: Plain text
12751 #: build/C/man3/stdio_ext.3:40
12752 msgid "B<int __flbf(FILE *>I<stream>B<);>"
12753 msgstr "B<int __flbf(FILE *>I<stream>B<);>"
12754
12755 #. type: Plain text
12756 #: build/C/man3/stdio_ext.3:42
12757 msgid "B<int __freadable(FILE *>I<stream>B<);>"
12758 msgstr "B<int __freadable(FILE *>I<stream>B<);>"
12759
12760 #. type: Plain text
12761 #: build/C/man3/stdio_ext.3:44
12762 msgid "B<int __fwritable(FILE *>I<stream>B<);>"
12763 msgstr "B<int __fwritable(FILE *>I<stream>B<);>"
12764
12765 #. type: Plain text
12766 #: build/C/man3/stdio_ext.3:46
12767 msgid "B<int __freading(FILE *>I<stream>B<);>"
12768 msgstr "B<int __freading(FILE *>I<stream>B<);>"
12769
12770 #. type: Plain text
12771 #: build/C/man3/stdio_ext.3:48
12772 msgid "B<int __fwriting(FILE *>I<stream>B<);>"
12773 msgstr "B<int __fwriting(FILE *>I<stream>B<);>"
12774
12775 #. type: Plain text
12776 #: build/C/man3/stdio_ext.3:50
12777 msgid "B<int __fsetlocking(FILE *>I<stream>B<, int >I<type>B<);>"
12778 msgstr "B<int __fsetlocking(FILE *>I<stream>B<, int >I<type>B<);>"
12779
12780 #. type: Plain text
12781 #: build/C/man3/stdio_ext.3:52
12782 msgid "B<void _flushlbf(void);>"
12783 msgstr "B<void _flushlbf(void);>"
12784
12785 #. type: Plain text
12786 #: build/C/man3/stdio_ext.3:54
12787 msgid "B<void __fpurge(FILE *>I<stream>B<);>"
12788 msgstr "B<void __fpurge(FILE *>I<stream>B<);>"
12789
12790 #. type: Plain text
12791 #: build/C/man3/stdio_ext.3:59
12792 msgid ""
12793 "Solaris introduced routines to allow portable access to the internals of the "
12794 "I<FILE> structure, and glibc also implemented these."
12795 msgstr ""
12796 "Solaris では、 I<FILE> 構造体の内部へポータブルなかたちで アクセスできる手段"
12797 "が導入されており、これらは glibc でも実装されている。"
12798
12799 #. type: Plain text
12800 #: build/C/man3/stdio_ext.3:64
12801 msgid ""
12802 "The B<__fbufsize>()  function returns the size of the buffer currently used "
12803 "by the given stream."
12804 msgstr ""
12805 "B<__fbufsize>()  関数は、指定されたストリームが使用しているバッファサイズを返"
12806 "す。"
12807
12808 #. type: Plain text
12809 #: build/C/man3/stdio_ext.3:71
12810 msgid ""
12811 "The B<__fpending>()  function returns the number of bytes in the output "
12812 "buffer.  For wide-oriented streams the unit is wide characters.  This "
12813 "function is undefined on buffers in reading mode, or opened read-only."
12814 msgstr ""
12815 "B<__fpending>()  関数は、出力バッファに入っているデータのバイト数を返す。 ワ"
12816 "イドキャラクタを扱うストリームの場合、ワイドキャラクタ単位で計算される。 バッ"
12817 "ファが読み出しモードの場合や読み出し専用で開かれている場合の この関数の振舞い"
12818 "は未定義である。"
12819
12820 #. type: Plain text
12821 #: build/C/man3/stdio_ext.3:76
12822 msgid ""
12823 "The B<__flbf>()  function returns a nonzero value if the stream is line-"
12824 "buffered, and zero otherwise."
12825 msgstr ""
12826 "B<__flbf>()  関数は、ストリームがラインバッファの場合は 0 以外を、 それ以外の"
12827 "場合は 0 を返す。"
12828
12829 #. type: Plain text
12830 #: build/C/man3/stdio_ext.3:81
12831 msgid ""
12832 "The B<__freadable>()  function returns a nonzero value if the stream allows "
12833 "reading, and zero otherwise."
12834 msgstr ""
12835 "B<__freadable>()  関数は、ストリームが読み出し可能な場合は 0 以外を、 それ以"
12836 "外の場合は 0 を返す。"
12837
12838 #. type: Plain text
12839 #: build/C/man3/stdio_ext.3:86
12840 msgid ""
12841 "The B<__fwritable>()  function returns a nonzero value if the stream allows "
12842 "writing, and zero otherwise."
12843 msgstr ""
12844 "B<__fwritable>()  関数は、ストリームが書き込み可能な場合は 0 以外を、 それ以"
12845 "外の場合は 0 を返す。"
12846
12847 #. type: Plain text
12848 #: build/C/man3/stdio_ext.3:92
12849 msgid ""
12850 "The B<__freading>()  function returns a nonzero value if the stream is read-"
12851 "only, or if the last operation on the stream was a read operation, and zero "
12852 "otherwise."
12853 msgstr ""
12854 "B<__freading>()  関数は、ストリームが読み出し専用の場合、またはストリームに対"
12855 "する直前の操作が 読み出し操作であった場合は 0 以外を返し、それ以外の場合は 0 "
12856 "を返す。"
12857
12858 #. type: Plain text
12859 #: build/C/man3/stdio_ext.3:98
12860 msgid ""
12861 "The B<__fwriting>()  function returns a nonzero value if the stream is write-"
12862 "only (or append-only), or if the last operation on the stream was a write "
12863 "operation, and zero otherwise."
12864 msgstr ""
12865 "B<__fwriting>()  関数は、ストリームが書き込み専用(もしくは追加専用)の場合、 "
12866 "またはストリームに対する直前の操作が書き込み操作であった場合は 0 以外を返"
12867 "し、 それ以外の場合は 0 を返す。"
12868
12869 #. type: Plain text
12870 #: build/C/man3/stdio_ext.3:106
12871 msgid ""
12872 "The B<__fsetlocking>()  function can be used to select the desired type of "
12873 "locking on the stream.  It returns the current type.  The I<type> argument "
12874 "can take the following three values:"
12875 msgstr ""
12876 "B<__fsetlocking>()  関数は、ストリームのロック形式を選択するために使用でき"
12877 "る。 返り値は、現在のロック形式である。 I<type> 引き数は以下の 3 種類の値をと"
12878 "ることができる :"
12879
12880 #. type: TP
12881 #: build/C/man3/stdio_ext.3:106
12882 #, no-wrap
12883 msgid "B<FSETLOCKING_INTERNAL>"
12884 msgstr "B<FSETLOCKING_INTERNAL>"
12885
12886 #. type: Plain text
12887 #: build/C/man3/stdio_ext.3:111
12888 msgid ""
12889 "Perform implicit locking around every operation on the given stream (except "
12890 "for the *_unlocked ones).  This is the default."
12891 msgstr ""
12892 "指定されたストリームに対して操作が行われる度に、操作の前後で 明示的に指示しな"
12893 "くてもストリームのロック処理を行う (但し、*_unlocked 関数を使用した場合は例外"
12894 "である)。 これがデフォルトのロック形式である。"
12895
12896 #. type: TP
12897 #: build/C/man3/stdio_ext.3:111
12898 #, no-wrap
12899 msgid "B<FSETLOCKING_BYCALLER>"
12900 msgstr "B<FSETLOCKING_BYCALLER>"
12901
12902 #. type: Plain text
12903 #: build/C/man3/stdio_ext.3:118
12904 msgid ""
12905 "The caller will take care of the locking (possibly using B<flockfile>(3)  in "
12906 "case there is more than one thread), and the stdio routines will not do "
12907 "locking until the state is reset to B<FSETLOCKING_INTERNAL>."
12908 msgstr ""
12909 "関数の呼び出し元でロックの面倒をみる。 (おそらく、複数のスレッドが存在する状"
12910 "況では B<flockfile>(3)  を使うことになるだろう)  ロック形式が "
12911 "B<FSETLOCKING_INTERNAL> にリセットされるまでは標準入出力関連の関数はロック処"
12912 "理を行わない。"
12913
12914 #. type: TP
12915 #: build/C/man3/stdio_ext.3:118
12916 #, no-wrap
12917 msgid "B<FSETLOCKING_QUERY>"
12918 msgstr "B<FSETLOCKING_QUERY>"
12919
12920 #. type: Plain text
12921 #: build/C/man3/stdio_ext.3:122
12922 msgid "Don't change the type of locking.  (Only return it.)"
12923 msgstr "ロック形式の変更を行わない。(現在の形式を返すだけである)"
12924
12925 #. type: Plain text
12926 #: build/C/man3/stdio_ext.3:128
12927 msgid ""
12928 "The B<_flushlbf>()  function flushes all line-buffered streams.  (Presumably "
12929 "so that output to a terminal is forced out, say before reading keyboard "
12930 "input.)"
12931 msgstr ""
12932 "B<_flushlbf>()  関数は、すべてのラインバッファ (line-buffered) タイプのスト"
12933 "リームの 内容を出力(フラッシュ)する。 (当然ながら、端末への出力が強制的に行わ"
12934 "れることになるので、 キーボードからの入力を読みこむ前にこの関数を呼んだ方がい"
12935 "いだろう)"
12936
12937 #. type: Plain text
12938 #: build/C/man3/stdio_ext.3:132
12939 msgid ""
12940 "The B<__fpurge>()  function discards the contents of the stream's buffer."
12941 msgstr "B<__fpurge>()  関数は、ストリームのバッファの内容を廃棄する。"
12942
12943 #. type: Plain text
12944 #: build/C/man3/stdio_ext.3:141
12945 msgid ""
12946 "The B<__fbufsize>(), B<__fpending>(), B<__fpurge>()  and B<__fsetlocking>()  "
12947 "functions do not lock the stream, so they are not thread-safe."
12948 msgstr ""
12949
12950 #. type: Plain text
12951 #: build/C/man3/stdio_ext.3:151
12952 msgid ""
12953 "The B<__flbf>(), B<__freadable>(), B<__freading>(), B<__fwritable>(), "
12954 "B<__fwriting>()  and B<_flushlbf>()  functions are thread-safe."
12955 msgstr ""
12956
12957 #. type: Plain text
12958 #: build/C/man3/stdio_ext.3:154
12959 msgid "B<flockfile>(3), B<fpurge>(3)"
12960 msgstr "B<flockfile>(3), B<fpurge>(3)"
12961
12962 #. type: TH
12963 #: build/C/man2/symlink.2:32 build/C/man7/symlink.7:36
12964 #, no-wrap
12965 msgid "SYMLINK"
12966 msgstr "SYMLINK"
12967
12968 #. type: Plain text
12969 #: build/C/man2/symlink.2:35
12970 msgid "symlink - make a new name for a file"
12971 msgstr "symlink - ファイルに新しい名前を付ける"
12972
12973 #. type: Plain text
12974 #: build/C/man2/symlink.2:39
12975 msgid "B<int symlink(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
12976 msgstr "B<int symlink(const char *>I<oldpath>B<, const char *>I<newpath>B<);>"
12977
12978 #. type: Plain text
12979 #: build/C/man2/symlink.2:47
12980 msgid "B<symlink>():"
12981 msgstr "B<symlink>():"
12982
12983 #. type: Plain text
12984 #: build/C/man2/symlink.2:58
12985 msgid ""
12986 "B<symlink>()  creates a symbolic link named I<newpath> which contains the "
12987 "string I<oldpath>."
12988 msgstr ""
12989 "B<symlink>()  は I<oldpath> という文字列をファイルの内容として持つ "
12990 "I<newpath> というシンボリックリンク (symbolic link) を作成する。"
12991
12992 #. type: Plain text
12993 #: build/C/man2/symlink.2:62
12994 msgid ""
12995 "Symbolic links are interpreted at run time as if the contents of the link "
12996 "had been substituted into the path being followed to find a file or "
12997 "directory."
12998 msgstr ""
12999 "シンボリックリンクは実行時に解釈され、 リンクの内容でパスを置き換えて、そのパ"
13000 "スを辿ることで、 ファイルやディレクトリに到達する。"
13001
13002 #. type: Plain text
13003 #: build/C/man2/symlink.2:67
13004 msgid ""
13005 "Symbolic links may contain I<..> path components, which (if used at the "
13006 "start of the link) refer to the parent directories of that in which the link "
13007 "resides."
13008 msgstr ""
13009 "シンボリックリンクはパスの部分に I<..> を含むかもしれない。これは (もしリンク"
13010 "の最初に使用された場合は) リンクの 存在するディレクトリの親ディレクトリが参照"
13011 "される。"
13012
13013 #. type: Plain text
13014 #: build/C/man2/symlink.2:71
13015 msgid ""
13016 "A symbolic link (also known as a soft link) may point to an existing file or "
13017 "to a nonexistent one; the latter case is known as a dangling link."
13018 msgstr ""
13019 "シンボリックリンクは (ソフトリンク (soft link) とも呼ばれ)  存在するファイル"
13020 "を指しているかもしれないし、 存在しないファイルを指しているかもしれない; 後者"
13021 "の場合は壊れたリンク (dangling link) とも呼ばれる。"
13022
13023 #. type: Plain text
13024 #: build/C/man2/symlink.2:78
13025 msgid ""
13026 "The permissions of a symbolic link are irrelevant; the ownership is ignored "
13027 "when following the link, but is checked when removal or renaming of the link "
13028 "is requested and the link is in a directory with the sticky bit "
13029 "(B<S_ISVTX>)  set."
13030 msgstr ""
13031 "シンボリックリンクの許可 (permission) は無意味である; リンクを追跡する場合に"
13032 "は所有権 (ownership) は無視される。 ただし、リンクの削除や名前の変更が要求さ"
13033 "れ、かつリンクが存在する ディレクトリにスティッキービット (sticky bit)  "
13034 "(B<S_ISVTX>)  が設定されている場合には、所有権のチェックが行われる。"
13035
13036 #. type: Plain text
13037 #: build/C/man2/symlink.2:99
13038 msgid ""
13039 "Write access to the directory containing I<newpath> is denied, or one of the "
13040 "directories in the path prefix of I<newpath> did not allow search "
13041 "permission.  (See also B<path_resolution>(7).)"
13042 msgstr ""
13043 "I<newpath> を含んでいるディレクトリへの書き込みが拒否されたか、 I<newpath> に"
13044 "含まれているディレクトリのどれかに検索許可が与えられていない "
13045 "(B<path_resolution>(7)  も参照すること)。"
13046
13047 #. type: Plain text
13048 #: build/C/man2/symlink.2:104
13049 msgid ""
13050 "The user's quota of resources on the file system has been exhausted.  The "
13051 "resources could be inodes or disk blocks, depending on the file system "
13052 "implementation."
13053 msgstr ""
13054 "そのファイルシステムのリソース使用量がユーザクォータに達している。対象となる"
13055 "リソースは inode かディスクブロックで、どちらになるかはファイルシステムの実装"
13056 "依存である。"
13057
13058 #. type: Plain text
13059 #: build/C/man2/symlink.2:118
13060 msgid "Too many symbolic links were encountered in resolving I<newpath>."
13061 msgstr "I<newpath> を解決する際に遭遇したシンボリックリンクが多過ぎる。"
13062
13063 #. type: Plain text
13064 #: build/C/man2/symlink.2:128
13065 msgid ""
13066 "A directory component in I<newpath> does not exist or is a dangling symbolic "
13067 "link, or I<oldpath> is the empty string."
13068 msgstr ""
13069 "I<newpath> に含まれるディレクトリ部分が存在しないか、壊れたリンクであるか、 "
13070 "I<oldpath> が空文字列である。"
13071
13072 #. type: Plain text
13073 #: build/C/man2/symlink.2:140
13074 msgid ""
13075 "A component used as a directory in I<newpath> is not, in fact, a directory."
13076 msgstr ""
13077 "I<newpath> に含まれるディレクトリ部分が、実際には、ディレクトリではない。"
13078
13079 #. type: Plain text
13080 #: build/C/man2/symlink.2:145
13081 msgid ""
13082 "The file system containing I<newpath> does not support the creation of "
13083 "symbolic links."
13084 msgstr ""
13085 "I<newpath> を含んでいるファイルシステム (file system) が シンボリックリンクの"
13086 "作成をサポートしていない。"
13087
13088 #. type: Plain text
13089 #: build/C/man2/symlink.2:149
13090 msgid "I<newpath> is on a read-only file system."
13091 msgstr "I<newpath> が読み込み専用のファイルシステムに存在している。"
13092
13093 #. type: Plain text
13094 #: build/C/man2/symlink.2:159
13095 msgid "No checking of I<oldpath> is done."
13096 msgstr "I<oldpath> についてのチェックは行なわれない。"
13097
13098 #. type: Plain text
13099 #: build/C/man2/symlink.2:164
13100 msgid ""
13101 "Deleting the name referred to by a symlink will actually delete the file "
13102 "(unless it also has other hard links).  If this behavior is not desired, use "
13103 "B<link>(2)."
13104 msgstr ""
13105 "symlink によって参照される名前を削除すると (それが他にハードリンク (hard "
13106 "link) を持たなければ) 実際にファイルが削除される。 この動作が望んだものでない"
13107 "場合は、 B<link>(2)  を使用すること。"
13108
13109 #. type: Plain text
13110 #: build/C/man2/symlink.2:176
13111 msgid ""
13112 "B<ln>(1), B<lchown>(2), B<link>(2), B<lstat>(2), B<open>(2), B<readlink>(2), "
13113 "B<rename>(2), B<symlinkat>(2), B<unlink>(2), B<path_resolution>(7), "
13114 "B<symlink>(7)"
13115 msgstr ""
13116 "B<ln>(1), B<lchown>(2), B<link>(2), B<lstat>(2), B<open>(2), B<readlink>(2), "
13117 "B<rename>(2), B<symlinkat>(2), B<unlink>(2), B<path_resolution>(7), "
13118 "B<symlink>(7)"
13119
13120 #. type: TH
13121 #: build/C/man7/symlink.7:36
13122 #, no-wrap
13123 msgid "2008-06-18"
13124 msgstr "2008-06-18"
13125
13126 #. type: Plain text
13127 #: build/C/man7/symlink.7:39
13128 msgid "symlink - symbolic link handling"
13129 msgstr ""
13130
13131 #. type: SH
13132 #: build/C/man7/symlink.7:39
13133 #, no-wrap
13134 msgid "SYMBOLIC LINK HANDLING"
13135 msgstr ""
13136
13137 #. type: Plain text
13138 #: build/C/man7/symlink.7:43
13139 msgid ""
13140 "Symbolic links are files that act as pointers to other files.  To understand "
13141 "their behavior, you must first understand how hard links work."
13142 msgstr ""
13143
13144 #. type: Plain text
13145 #: build/C/man7/symlink.7:59
13146 msgid ""
13147 "A hard link to a file is indistinguishable from the original file because it "
13148 "is a reference to the object underlying the original filename.  (To be "
13149 "precise: each of the hard links to a file is a reference to the same I<i-"
13150 "node number>, where an i-node number is an index into the i-node table, "
13151 "which contains metadata about all files on a file system.  See B<stat>(2).)  "
13152 "Changes to a file are independent of the name used to reference the file.  "
13153 "Hard links may not refer to directories (to prevent the possibility of loops "
13154 "within the file system tree, which would confuse many programs)  and may not "
13155 "refer to files on different file systems (because i-node numbers are not "
13156 "unique across file systems)."
13157 msgstr ""
13158
13159 #. type: Plain text
13160 #: build/C/man7/symlink.7:66
13161 msgid ""
13162 "A symbolic link is a special type of file whose contents are a string that "
13163 "is the pathname another file, the file to which the link refers.  In other "
13164 "words, a symbolic link is a pointer to another name, and not to an "
13165 "underlying object.  For this reason, symbolic links may refer to directories "
13166 "and may cross file system boundaries."
13167 msgstr ""
13168
13169 #. type: Plain text
13170 #: build/C/man7/symlink.7:72
13171 msgid ""
13172 "There is no requirement that the pathname referred to by a symbolic link "
13173 "should exist.  A symbolic link that refers to a pathname that does not exist "
13174 "is said to be a I<dangling link>."
13175 msgstr ""
13176
13177 #. type: Plain text
13178 #: build/C/man7/symlink.7:84
13179 msgid ""
13180 "Because a symbolic link and its referenced object coexist in the file system "
13181 "name space, confusion can arise in distinguishing between the link itself "
13182 "and the referenced object.  On historical systems, commands and system calls "
13183 "adopted their own link-following conventions in a somewhat ad-hoc fashion.  "
13184 "Rules for a more uniform approach, as they are implemented on Linux and "
13185 "other systems, are outlined here.  It is important that site-local "
13186 "applications also conform to these rules, so that the user interface can be "
13187 "as consistent as possible."
13188 msgstr ""
13189
13190 #. type: SS
13191 #: build/C/man7/symlink.7:84
13192 #, no-wrap
13193 msgid "Symbolic link ownership, permissions, and timestamps"
13194 msgstr ""
13195
13196 #. type: Plain text
13197 #: build/C/man7/symlink.7:92
13198 msgid ""
13199 "The owner and group of an existing symbolic link can be changed using "
13200 "B<lchown>(2).  The only time that the ownership of a symbolic link matters "
13201 "is when the link is being removed or renamed in a directory that has the "
13202 "sticky bit set (see B<stat>(2))."
13203 msgstr ""
13204
13205 #. type: Plain text
13206 #: build/C/man7/symlink.7:98
13207 msgid ""
13208 "The last access and last modification timestamps of a symbolic link can be "
13209 "changed using B<utimensat>(2)  or B<lutimes>(3)."
13210 msgstr ""
13211
13212 #.  Linux does not currently implement an lchmod(2).
13213 #.  The
13214 #.  4.4BSD
13215 #.  system differs from historical
13216 #.  4BSD
13217 #.  systems in that the system call
13218 #.  .BR chown (2)
13219 #.  has been changed to follow symbolic links.
13220 #.  The
13221 #.  .BR lchown (2)
13222 #.  system call was added later when the limitations of the new
13223 #.  .BR chown (2)
13224 #.  became apparent.
13225 #. type: Plain text
13226 #: build/C/man7/symlink.7:117
13227 msgid ""
13228 "On Linux, the permissions of a symbolic link are not used in any operations; "
13229 "the permissions are always 0777 (read, write, and execute for all user "
13230 "categories), and can't be changed."
13231 msgstr ""
13232
13233 #. type: SS
13234 #: build/C/man7/symlink.7:117
13235 #, no-wrap
13236 msgid "Handling of symbolic links by system calls and commands"
13237 msgstr ""
13238
13239 #. type: Plain text
13240 #: build/C/man7/symlink.7:132
13241 msgid ""
13242 "Symbolic links are handled either by operating on the link itself, or by "
13243 "operating on the object referred to by the link.  In the latter case, an "
13244 "application or system call is said to I<follow> the link.  Symbolic links "
13245 "may refer to other symbolic links, in which case the links are dereferenced "
13246 "until an object that is not a symbolic link is found, a symbolic link that "
13247 "refers to a file which does not exist is found, or a loop is detected.  "
13248 "(Loop detection is done by placing an upper limit on the number of links "
13249 "that may be followed, and an error results if this limit is exceeded.)"
13250 msgstr ""
13251
13252 #. type: Plain text
13253 #: build/C/man7/symlink.7:135
13254 msgid ""
13255 "There are three separate areas that need to be discussed.  They are as "
13256 "follows:"
13257 msgstr ""
13258
13259 #. type: IP
13260 #: build/C/man7/symlink.7:135
13261 #, no-wrap
13262 msgid "1."
13263 msgstr "1."
13264
13265 #. type: Plain text
13266 #: build/C/man7/symlink.7:137
13267 msgid "Symbolic links used as filename arguments for system calls."
13268 msgstr ""
13269
13270 #. type: IP
13271 #: build/C/man7/symlink.7:137
13272 #, no-wrap
13273 msgid "2."
13274 msgstr "2."
13275
13276 #. type: Plain text
13277 #: build/C/man7/symlink.7:140
13278 msgid ""
13279 "Symbolic links specified as command-line arguments to utilities that are not "
13280 "traversing a file tree."
13281 msgstr ""
13282
13283 #. type: IP
13284 #: build/C/man7/symlink.7:140
13285 #, no-wrap
13286 msgid "3."
13287 msgstr "3."
13288
13289 #. type: Plain text
13290 #: build/C/man7/symlink.7:144
13291 msgid ""
13292 "Symbolic links encountered by utilities that are traversing a file tree "
13293 "(either specified on the command line or encountered as part of the file "
13294 "hierarchy walk)."
13295 msgstr ""
13296
13297 #. type: SS
13298 #: build/C/man7/symlink.7:144
13299 #, no-wrap
13300 msgid "System calls"
13301 msgstr ""
13302
13303 #. type: Plain text
13304 #: build/C/man7/symlink.7:147
13305 msgid ""
13306 "The first area is symbolic links used as filename arguments for system calls."
13307 msgstr ""
13308
13309 #. type: Plain text
13310 #: build/C/man7/symlink.7:157
13311 msgid ""
13312 "Except as noted below, all system calls follow symbolic links.  For example, "
13313 "if there were a symbolic link I<slink> which pointed to a file named "
13314 "I<afile>, the system call I<open(\"slink\" ...\\&)> would return a file "
13315 "descriptor referring to the file I<afile>."
13316 msgstr ""
13317
13318 #.  Maybe one day: .BR fchownat (2)
13319 #. type: Plain text
13320 #: build/C/man7/symlink.7:207
13321 msgid ""
13322 "Various system calls do not follow links, and operate on the symbolic link "
13323 "itself.  They are: B<lchown>(2), B<lgetxattr>(2), B<llistxattr>(2), "
13324 "B<lremovexattr>(2), B<lsetxattr>(2), B<lstat>(2), B<readlink>(2), B<rename>"
13325 "(2), B<rmdir>(2), and B<unlink>(2).  Certain other system calls optionally "
13326 "follow symbolic links.  They are: B<faccessat>(2), B<fchownat>(2), B<fstatat>"
13327 "(2), B<linkat>(2), B<open>(2), B<openat>(2), and B<utimensat>(2); see their "
13328 "manual pages for details.  Because B<remove>(3)  is an alias for B<unlink>"
13329 "(2), that library function also does not follow symbolic links.  When "
13330 "B<rmdir>(2)  is applied to a symbolic link, it fails with the error "
13331 "B<ENOTDIR>.  The B<link>(2)  warrants special discussion.  POSIX.1-2001 "
13332 "specifies that B<link>(2)  should dereference I<oldpath> if it is a symbolic "
13333 "link.  However, Linux does not do this.  (By default Solaris is the same, "
13334 "but the POSIX.1-2001 specified behavior can be obtained with suitable "
13335 "compiler options.)  The upcoming POSIX.1 revision changes the specification "
13336 "to allow either behavior in an implementation."
13337 msgstr ""
13338
13339 #. type: SS
13340 #: build/C/man7/symlink.7:207
13341 #, no-wrap
13342 msgid "Commands not traversing a file tree"
13343 msgstr ""
13344
13345 #. type: Plain text
13346 #: build/C/man7/symlink.7:210
13347 msgid ""
13348 "The second area is symbolic links, specified as command-line filename "
13349 "arguments, to commands which are not traversing a file tree."
13350 msgstr ""
13351
13352 #. type: Plain text
13353 #: build/C/man7/symlink.7:221
13354 msgid ""
13355 "Except as noted below, commands follow symbolic links named as command-line "
13356 "arguments.  For example, if there were a symbolic link I<slink> which "
13357 "pointed to a file named I<afile>, the command I<cat slink> would display the "
13358 "contents of the file I<afile>."
13359 msgstr ""
13360
13361 #. type: Plain text
13362 #: build/C/man7/symlink.7:229
13363 msgid ""
13364 "It is important to realize that this rule includes commands which may "
13365 "optionally traverse file trees, e.g., the command I<chown file> is included "
13366 "in this rule, while the command I<chown\\ -R file>, which performs a tree "
13367 "traversal, is not.  (The latter is described in the third area, below.)"
13368 msgstr ""
13369
13370 #. type: Plain text
13371 #: build/C/man7/symlink.7:247
13372 msgid ""
13373 "If it is explicitly intended that the command operate on the symbolic link "
13374 "instead of following the symbolic link, e.g., it is desired that I<chown "
13375 "slink> change the ownership of the file that I<slink> is, whether it is a "
13376 "symbolic link or not, the I<-h> option should be used.  In the above "
13377 "example, I<chown root slink> would change the ownership of the file referred "
13378 "to by I<slink>, while I<chown\\ -h root slink> would change the ownership of "
13379 "I<slink> itself."
13380 msgstr ""
13381
13382 #. type: Plain text
13383 #: build/C/man7/symlink.7:249
13384 msgid "There are some exceptions to this rule:"
13385 msgstr ""
13386
13387 #. type: Plain text
13388 #: build/C/man7/symlink.7:259
13389 msgid ""
13390 "The B<mv>(1)  and B<rm>(1)  commands do not follow symbolic links named as "
13391 "arguments, but respectively attempt to rename and delete them.  (Note, if "
13392 "the symbolic link references a file via a relative path, moving it to "
13393 "another directory may very well cause it to stop working, since the path may "
13394 "no longer be correct.)"
13395 msgstr ""
13396
13397 #. type: Plain text
13398 #: build/C/man7/symlink.7:289
13399 msgid ""
13400 "The B<ls>(1)  command is also an exception to this rule.  For compatibility "
13401 "with historic systems (when B<ls>(1)  is not doing a tree walk, i.e., the I<-"
13402 "R> option is not specified), the B<ls>(1)  command follows symbolic links "
13403 "named as arguments if the I<-H> or I<-L> option is specified, or if the I<-"
13404 "F>, I<-d>, or I<-l> options are not specified.  (The B<ls>(1)  command is "
13405 "the only command where the I<-H> and I<-L> options affect its behavior even "
13406 "though it is not doing a walk of a file tree.)"
13407 msgstr ""
13408
13409 #. The 4.4BSD system differs from historical 4BSD systems in that the
13410 #. .BR chown (1)
13411 #. and
13412 #. .BR chgrp (1)
13413 #. commands follow symbolic links specified on the command line.
13414 #. type: Plain text
13415 #: build/C/man7/symlink.7:307
13416 msgid ""
13417 "The B<file>(1)  command is also an exception to this rule.  The B<file>(1)  "
13418 "command does not follow symbolic links named as argument by default.  The "
13419 "B<file>(1)  command does follow symbolic links named as argument if the I<-"
13420 "L> option is specified."
13421 msgstr ""
13422
13423 #. type: SS
13424 #: build/C/man7/symlink.7:307
13425 #, no-wrap
13426 msgid "Commands traversing a file tree"
13427 msgstr ""
13428
13429 #. type: Plain text
13430 #: build/C/man7/symlink.7:320
13431 msgid ""
13432 "The following commands either optionally or always traverse file trees: "
13433 "B<chgrp>(1), B<chmod>(1), B<chown>(1), B<cp>(1), B<du>(1), B<find>(1), B<ls>"
13434 "(1), B<pax>(1), B<rm>(1), and B<tar>(1)."
13435 msgstr ""
13436
13437 #. type: Plain text
13438 #: build/C/man7/symlink.7:324
13439 msgid ""
13440 "It is important to realize that the following rules apply equally to "
13441 "symbolic links encountered during the file tree traversal and symbolic links "
13442 "listed as command-line arguments."
13443 msgstr ""
13444
13445 #. type: Plain text
13446 #: build/C/man7/symlink.7:329
13447 msgid ""
13448 "The I<first rule> applies to symbolic links that reference files other than "
13449 "directories.  Operations that apply to symbolic links are performed on the "
13450 "links themselves, but otherwise the links are ignored."
13451 msgstr ""
13452
13453 #. type: Plain text
13454 #: build/C/man7/symlink.7:341
13455 msgid ""
13456 "The command I<rm\\ -r slink directory> will remove I<slink>, as well as any "
13457 "symbolic links encountered in the tree traversal of I<directory>, because "
13458 "symbolic links may be removed.  In no case will B<rm>(1)  affect the file "
13459 "referred to by I<slink>."
13460 msgstr ""
13461
13462 #. type: Plain text
13463 #: build/C/man7/symlink.7:346
13464 msgid ""
13465 "The I<second rule> applies to symbolic links that refer to directories.  "
13466 "Symbolic links that refer to directories are never followed by default.  "
13467 "This is often referred to as a \"physical\" walk, as opposed to a \"logical"
13468 "\" walk (where symbolic links the refer to directories are followed)."
13469 msgstr ""
13470
13471 #. type: Plain text
13472 #: build/C/man7/symlink.7:349
13473 msgid ""
13474 "Certain conventions are (should be) followed as consistently as possible by "
13475 "commands that perform file tree walks:"
13476 msgstr ""
13477
13478 #. type: Plain text
13479 #: build/C/man7/symlink.7:362
13480 msgid ""
13481 "A command can be made to follow any symbolic links named on the command "
13482 "line, regardless of the type of file they reference, by specifying the I<-H> "
13483 "(for \"half-logical\") flag.  This flag is intended to make the command-line "
13484 "name space look like the logical name space.  (Note, for commands that do "
13485 "not always do file tree traversals, the I<-H> flag will be ignored if the I<-"
13486 "R> flag is not also specified.)"
13487 msgstr ""
13488
13489 #. type: Plain text
13490 #: build/C/man7/symlink.7:378
13491 msgid ""
13492 "For example, the command I<chown\\ -HR user slink> will traverse the file "
13493 "hierarchy rooted in the file pointed to by I<slink>.  Note, the I<-H> is not "
13494 "the same as the previously discussed I<-h> flag.  The I<-H> flag causes "
13495 "symbolic links specified on the command line to be dereferenced for the "
13496 "purposes of both the action to be performed and the tree walk, and it is as "
13497 "if the user had specified the name of the file to which the symbolic link "
13498 "pointed."
13499 msgstr ""
13500
13501 #. type: Plain text
13502 #: build/C/man7/symlink.7:392
13503 msgid ""
13504 "A command can be made to follow any symbolic links named on the command "
13505 "line, as well as any symbolic links encountered during the traversal, "
13506 "regardless of the type of file they reference, by specifying the I<-L> (for "
13507 "\"logical\") flag.  This flag is intended to make the entire name space look "
13508 "like the logical name space.  (Note, for commands that do not always do file "
13509 "tree traversals, the I<-L> flag will be ignored if the I<-R> flag is not "
13510 "also specified.)"
13511 msgstr ""
13512
13513 #. type: Plain text
13514 #: build/C/man7/symlink.7:407
13515 msgid ""
13516 "For example, the command I<chown\\ -LR user slink> will change the owner of "
13517 "the file referred to by I<slink>.  If I<slink> refers to a directory, "
13518 "B<chown> will traverse the file hierarchy rooted in the directory that it "
13519 "references.  In addition, if any symbolic links are encountered in any file "
13520 "tree that B<chown> traverses, they will be treated in the same fashion as "
13521 "I<slink>."
13522 msgstr ""
13523
13524 #. type: Plain text
13525 #: build/C/man7/symlink.7:414
13526 msgid ""
13527 "A command can be made to provide the default behavior by specifying the I<-"
13528 "P> (for \"physical\") flag.  This flag is intended to make the entire name "
13529 "space look like the physical name space."
13530 msgstr ""
13531
13532 #. type: Plain text
13533 #: build/C/man7/symlink.7:432
13534 msgid ""
13535 "For commands that do not by default do file tree traversals, the I<-H>, I<-"
13536 "L>, and I<-P> flags are ignored if the I<-R> flag is not also specified.  In "
13537 "addition, you may specify the I<-H>, I<-L>, and I<-P> options more than "
13538 "once; the last one specified determines the command's behavior.  This is "
13539 "intended to permit you to alias commands to behave one way or the other, and "
13540 "then override that behavior on the command line."
13541 msgstr ""
13542
13543 #. type: Plain text
13544 #: build/C/man7/symlink.7:438
13545 msgid "The B<ls>(1)  and B<rm>(1)  commands have exceptions to these rules:"
13546 msgstr ""
13547
13548 #. type: Plain text
13549 #: build/C/man7/symlink.7:451
13550 msgid ""
13551 "The B<rm>(1)  command operates on the symbolic link, and not the file it "
13552 "references, and therefore never follows a symbolic link.  The B<rm>(1)  "
13553 "command does not support the I<-H>, I<-L>, or I<-P> options."
13554 msgstr ""
13555
13556 #. type: Plain text
13557 #: build/C/man7/symlink.7:471
13558 msgid ""
13559 "To maintain compatibility with historic systems, the B<ls>(1)  command acts "
13560 "a little differently.  If you do not specify the I<-F>, I<-d> or I<-l> "
13561 "options, B<ls>(1)  will follow symbolic links specified on the command "
13562 "line.  If the I<-L> flag is specified, B<ls>(1)  follows all symbolic links, "
13563 "regardless of their type, whether specified on the command line or "
13564 "encountered in the tree walk."
13565 msgstr ""
13566
13567 #. type: Plain text
13568 #: build/C/man7/symlink.7:489
13569 msgid ""
13570 "B<chgrp>(1), B<chmod>(1), B<find>(1), B<ln>(1), B<ls>(1), B<mv>(1), B<rm>"
13571 "(1), B<lchown>(2), B<link>(2), B<lstat>(2), B<readlink>(2), B<rename>(2), "
13572 "B<symlink>(2), B<unlink>(2), B<utimensat>(2), B<lutimes>(3), "
13573 "B<path_resolution>(7)"
13574 msgstr ""
13575 "B<chgrp>(1), B<chmod>(1), B<find>(1), B<ln>(1), B<ls>(1), B<mv>(1),\n"
13576 "B<rm>(1), B<lchown>(2), B<link>(2), B<lstat>(2), B<readlink>(2),\n"
13577 "B<rename>(2), B<symlink>(2), B<unlink>(2), B<utimensat>(2),\n"
13578 "B<lutimes>(3), B<path_resolution>(7)"
13579
13580 #. type: TH
13581 #: build/C/man3/tempnam.3:25
13582 #, no-wrap
13583 msgid "TEMPNAM"
13584 msgstr "TEMPNAM"
13585
13586 #. type: Plain text
13587 #: build/C/man3/tempnam.3:28
13588 msgid "tempnam - create a name for a temporary file"
13589 msgstr "tempnam - テンポラリファイルの名前を作成する"
13590
13591 #. type: Plain text
13592 #: build/C/man3/tempnam.3:33
13593 #, no-wrap
13594 msgid "B<char *tempnam(const char *>I<dir>B<, const char *>I<pfx>B<);>\n"
13595 msgstr "B<char *tempnam(const char *>I<dir>B<, const char *>I<pfx>B<);>\n"
13596
13597 #. type: Plain text
13598 #: build/C/man3/tempnam.3:42
13599 msgid "B<tempnam>(): _BSD_SOURCE || _SVID_SOURCE"
13600 msgstr "B<tempnam>(): _BSD_SOURCE || _SVID_SOURCE"
13601
13602 #. type: Plain text
13603 #: build/C/man3/tempnam.3:56
13604 msgid ""
13605 "The B<tempnam>()  function returns a pointer to a string that is a valid "
13606 "filename, and such that a file with this name did not exist when B<tempnam>"
13607 "()  checked.  The filename suffix of the pathname generated will start with "
13608 "I<pfx> in case I<pfx> is a non-NULL string of at most five bytes.  The "
13609 "directory prefix part of the pathname generated is required to be "
13610 "\"appropriate\" (often that at least implies writable)."
13611 msgstr ""
13612 "B<tempnam>()  関数はファイル名として正しい文字列へのポインタを返す。 このファ"
13613 "イル名を持つファイルは、 B<tempnam>()  がチェックした時点においては存在しな"
13614 "い (しなかった)。 I<pfx> が NULL でない 5 バイト以内の文字列であれば、 生成さ"
13615 "れるパス名のうちのファイル名の部分は I<pfx> から始まるものになる。 生成される"
13616 "ディレクトリの部分は、「適切」でなければならない (大抵の場合、「適切」である"
13617 "ためにはまず少なくとも 書き込み可能でなければならない)。"
13618
13619 #. type: Plain text
13620 #: build/C/man3/tempnam.3:59
13621 msgid ""
13622 "Attempts to find an appropriate directory go through the following steps:"
13623 msgstr "適切なディレクトリの探索は、以下の手順にしたがって行われる。"
13624
13625 #. type: TP
13626 #: build/C/man3/tempnam.3:59
13627 #, no-wrap
13628 msgid "a)"
13629 msgstr "a)"
13630
13631 #. type: Plain text
13632 #: build/C/man3/tempnam.3:65
13633 msgid ""
13634 "In case the environment variable B<TMPDIR> exists and contains the name of "
13635 "an appropriate directory, that is used."
13636 msgstr ""
13637 "環境変数 B<TMPDIR> が設定されていて、 その内容が適切なディレクトリの名前な"
13638 "ら、それを用いる。"
13639
13640 #. type: TP
13641 #: build/C/man3/tempnam.3:65
13642 #, no-wrap
13643 msgid "b)"
13644 msgstr "b)"
13645
13646 #. type: Plain text
13647 #: build/C/man3/tempnam.3:70
13648 msgid ""
13649 "Otherwise, if the I<dir> argument is non-NULL and appropriate, it is used."
13650 msgstr ""
13651 "それ以外の場合、 I<dir> 引き数が NULL でない文字列でかつ適切なら、それを用い"
13652 "る。"
13653
13654 #. type: TP
13655 #: build/C/man3/tempnam.3:70
13656 #, no-wrap
13657 msgid "c)"
13658 msgstr "c)"
13659
13660 #. type: Plain text
13661 #: build/C/man3/tempnam.3:77
13662 msgid ""
13663 "Otherwise, I<P_tmpdir> (as defined in I<E<lt>stdio.hE<gt>>)  is used when "
13664 "appropriate."
13665 msgstr ""
13666 "それ以外の場合、 (I<E<lt>stdio.hE<gt>> で定義されている)  I<P_tmpdir> が適切"
13667 "なら、それを用いる。"
13668
13669 #. type: TP
13670 #: build/C/man3/tempnam.3:77
13671 #, no-wrap
13672 msgid "d)"
13673 msgstr "d)"
13674
13675 #. type: Plain text
13676 #: build/C/man3/tempnam.3:80
13677 msgid "Finally an implementation-defined directory may be used."
13678 msgstr "最後に実装で定義されたディレクトリが用いられることになる。"
13679
13680 #. type: Plain text
13681 #: build/C/man3/tempnam.3:87
13682 msgid ""
13683 "The string returned by B<tempnam>()  is allocated using B<malloc>(3)  and "
13684 "hence should be freed by B<free>(3)."
13685 msgstr ""
13686 "B<tempnam>()  が返す文字列は B<malloc>(3)  を使って確保される。そのため、 "
13687 "B<free>(3)  で解放すべきである。"
13688
13689 #. type: Plain text
13690 #: build/C/man3/tempnam.3:94
13691 msgid ""
13692 "On succes, the B<tempnam>()  function returns a pointer to a unique "
13693 "temporary filename.  It returns NULL if a unique name cannot be generated, "
13694 "with I<errno> set to indicate the cause of the error."
13695 msgstr "成功すると B<tempnam>()  関数は、一意なテンポラリファイル名へのポインタを返す。 一意な名前が生成できなければ NULL を返し、 I<errno> にエラーの原因を示す値を設定する。"
13696
13697 #. type: Plain text
13698 #: build/C/man3/tempnam.3:98
13699 msgid "Allocation of storage failed."
13700 msgstr "保存領域の割り当てに失敗した。"
13701
13702 #. type: Plain text
13703 #: build/C/man3/tempnam.3:103
13704 msgid ""
13705 "SVr4, 4.3BSD, POSIX.1-2001.  POSIX.1-2008 marks B<tempnam>()  as obsolete."
13706 msgstr ""
13707 "SVr4, 4.3BSD, POSIX.1-2001.  POSIX.1-2008 は B<tempnam>()  を廃止予定としてい"
13708 "る。"
13709
13710 #. type: Plain text
13711 #: build/C/man3/tempnam.3:122
13712 msgid ""
13713 "Although B<tempnam>()  generates names that are difficult to guess, it is "
13714 "nevertheless possible that between the time that B<tempnam>()  returns a "
13715 "pathname, and the time that the program opens it, another program might "
13716 "create that pathname using B<open>(2), or create it as a symbolic link.  "
13717 "This can lead to security holes.  To avoid such possibilities, use the "
13718 "B<open>(2)  B<O_EXCL> flag to open the pathname.  Or better yet, use "
13719 "B<mkstemp>(3)  or B<tmpfile>(3)."
13720 msgstr ""
13721 "B<tempnam>()  は推測が難しい名前を生成するが、それにもかかわらず、 B<tempnam>"
13722 "()  がパス名を返してから、プログラムがそのファイルをオープンする までの間に、"
13723 "別のプログラムが同じパス名で、ファイルを B<open>(2)  で作成したり、シンボリッ"
13724 "クリンクを作成したりする可能性がある。 これはセキュリティホールにつながる可能"
13725 "性がある。 そのような可能性を回避するためには、 B<open>(2)  の B<O_EXCL> フラ"
13726 "グを使ってパス名をオープンすればよい。 もっといいのは、 B<mkstemp>(3)  や "
13727 "B<tmpfile>(3)  を使うことである。"
13728
13729 #. type: Plain text
13730 #: build/C/man3/tempnam.3:130
13731 msgid ""
13732 "SUSv2 does not mention the use of B<TMPDIR>; glibc will use it only when the "
13733 "program is not set-user-ID.  On SVr4, the directory used under B<d)> is I</"
13734 "tmp> (and this is what glibc does)."
13735 msgstr ""
13736 "SUSv2 では B<TMPDIR> に付いて言及されていない。 glibc は、プログラムが set-"
13737 "user-ID されていない場合に限ってこれを用いる。 SVr4 では B<d)> で使用される"
13738 "ディレクトリを I</tmp> と定めている (glibc もこの通りである)。"
13739
13740 #. type: Plain text
13741 #: build/C/man3/tempnam.3:135
13742 msgid ""
13743 "Because it dynamically allocates memory used to return the pathname, "
13744 "B<tempnam>()  is reentrant, and thus thread safe, unlike B<tmpnam>(3)."
13745 msgstr ""
13746 "パス名を返すのに使用するメモリを動的に確保するので、 B<tmpnam>(3)  と違い、 "
13747 "B<tempnam>()  はリエントラントであり、スレッドセーフである。"
13748
13749 #. type: Plain text
13750 #: build/C/man3/tempnam.3:148
13751 msgid ""
13752 "The B<tempnam>()  function generates a different string each time it is "
13753 "called, up to B<TMP_MAX> (defined in I<E<lt>stdio.hE<gt>>)  times.  If it is "
13754 "called more than B<TMP_MAX> times, the behavior is implementation defined."
13755 msgstr ""
13756 "B<tempnam>()  関数は最大 B<TMP_MAX> 回まで、呼び出される度に異なる文字列を作"
13757 "成する (B<TMP_MAX> は I<E<lt>stdio.hE<gt>> で定義されている)。 もし "
13758 "B<TMP_MAX> 回以上呼び出された場合、動作は実装依存である。"
13759
13760 #. type: Plain text
13761 #: build/C/man3/tempnam.3:152
13762 msgid "B<tempnam>()  uses at most the first five bytes from I<pfx>."
13763 msgstr "B<tempnam>()  は最大で I<pfx> の先頭 5 バイトを使用する。"
13764
13765 #. type: Plain text
13766 #: build/C/man3/tempnam.3:158
13767 msgid ""
13768 "The glibc implementation of B<tempnam>()  will fail with the error B<EEXIST> "
13769 "upon failure to find a unique name."
13770 msgstr ""
13771 "他と重ならない名前が見つけられなかった場合、glibc の B<tempnam>()  の実装はエ"
13772 "ラー B<EEXIST> で失敗する。"
13773
13774 #. type: Plain text
13775 #: build/C/man3/tempnam.3:161
13776 msgid ""
13777 "The precise meaning of \"appropriate\" is undefined; it is unspecified how "
13778 "accessibility of a directory is determined."
13779 msgstr ""
13780 "「適切」という言葉の正確な意味は定義されていない。 ディレクトリに対してどの程"
13781 "度のアクセス権限が必要なのかは指定されていない。"
13782
13783 #. type: Plain text
13784 #: build/C/man3/tempnam.3:168 build/C/man3/tmpnam.3:163
13785 msgid "Never use this function.  Use B<mkstemp>(3)  or B<tmpfile>(3)  instead."
13786 msgstr ""
13787 "決してこの関数を使ってはならない。代わりに B<mkstemp>(3)  か B<tmpfile>(3)  "
13788 "を使うこと。"
13789
13790 #. type: Plain text
13791 #: build/C/man3/tempnam.3:173
13792 msgid "B<mkstemp>(3), B<mktemp>(3), B<tmpfile>(3), B<tmpnam>(3)"
13793 msgstr "B<mkstemp>(3), B<mktemp>(3), B<tmpfile>(3), B<tmpnam>(3)"
13794
13795 #. type: TH
13796 #: build/C/man3/tmpfile.3:31
13797 #, no-wrap
13798 msgid "TMPFILE"
13799 msgstr "TMPFILE"
13800
13801 #. type: Plain text
13802 #: build/C/man3/tmpfile.3:34
13803 msgid "tmpfile - create a temporary file"
13804 msgstr "tmpfile - テンポラリファイルを作成する"
13805
13806 #. type: Plain text
13807 #: build/C/man3/tmpfile.3:39
13808 #, no-wrap
13809 msgid "B<FILE *tmpfile(void);>\n"
13810 msgstr "B<FILE *tmpfile(void);>\n"
13811
13812 #. type: Plain text
13813 #: build/C/man3/tmpfile.3:47
13814 msgid ""
13815 "The B<tmpfile>()  function opens a unique temporary file in binary read/"
13816 "write (w+b) mode.  The file will be automatically deleted when it is closed "
13817 "or the program terminates."
13818 msgstr ""
13819 "B<tmpfile>()  関数はユニークなテンポラリファイルを バイナリリードライトモー"
13820 "ド (w+b) でオープンする。 このファイルはクローズ時またはプログラムの終了時に"
13821 "自動的に削除される。"
13822
13823 #. type: Plain text
13824 #: build/C/man3/tmpfile.3:56
13825 msgid ""
13826 "The B<tmpfile>()  function returns a stream descriptor, or NULL if a unique "
13827 "filename cannot be generated or the unique file cannot be opened.  In the "
13828 "latter case, I<errno> is set to indicate the error."
13829 msgstr ""
13830 "B<tmpfile>()  関数はファイルポインタを返すか、 ユニークなファイルが作れなかっ"
13831 "たかオープンできなかった場合は NULL を返す。 後者の場合、エラーを表す "
13832 "I<errno> を設定する。"
13833
13834 #. type: Plain text
13835 #: build/C/man3/tmpfile.3:60
13836 msgid "Search permission denied for directory in file's path prefix."
13837 msgstr ""
13838 "ファイルのあるディレクトリにサーチのアクセス権 (search permission) がない。"
13839
13840 #. type: Plain text
13841 #: build/C/man3/tmpfile.3:63
13842 msgid "Unable to generate a unique filename."
13843 msgstr "ユニークなファイル名が作成できなかった。"
13844
13845 #. type: Plain text
13846 #: build/C/man3/tmpfile.3:66
13847 msgid "The call was interrupted by a signal."
13848 msgstr "呼び出しがシグナルによって中断された。"
13849
13850 #. type: Plain text
13851 #: build/C/man3/tmpfile.3:69
13852 msgid "Too many file descriptors in use by the process."
13853 msgstr "1 つのプロセスで使用可能なファイルディスクリプタ数を超過した。"
13854
13855 #. type: Plain text
13856 #: build/C/man3/tmpfile.3:72
13857 msgid "Too many files open in the system."
13858 msgstr "システム全体でオープン可能なファイル数を超過した。"
13859
13860 #. type: Plain text
13861 #: build/C/man3/tmpfile.3:75
13862 msgid "There was no room in the directory to add the new filename."
13863 msgstr "ディレクトリに新しいファイルを追加するための空き領域がない。"
13864
13865 #. type: Plain text
13866 #: build/C/man3/tmpfile.3:78
13867 msgid "Read-only file system."
13868 msgstr "読みだし専用ファイルシステムである。"
13869
13870 #. type: Plain text
13871 #: build/C/man3/tmpfile.3:80
13872 msgid "SVr4, 4.3BSD, C89, C99, SUSv2, POSIX.1-2001."
13873 msgstr "SVr4, 4.3BSD, C89, C99, SUSv2, POSIX.1-2001."
13874
13875 #. type: Plain text
13876 #: build/C/man3/tmpfile.3:86
13877 msgid ""
13878 "POSIX.1-2001 specifies: an error message may be written to I<stdout> if the "
13879 "stream cannot be opened."
13880 msgstr ""
13881 "POSIX.1-2001 では、 ストリームをオープンできなかった場合、 I<stdout> にエラー"
13882 "メッセージが書き出される、と規定されている。"
13883
13884 #. type: Plain text
13885 #: build/C/man3/tmpfile.3:97
13886 msgid ""
13887 "The standard does not specify the directory that B<tmpfile>()  will use.  "
13888 "Glibc will try the path prefix I<P_tmpdir> defined in I<E<lt>stdio.hE<gt>>, "
13889 "and if that fails the directory I</tmp>."
13890 msgstr ""
13891 "規格では B<tmpfile>()  が使うディレクトリは指定されていない。 glibc では "
13892 "I<E<lt>stdio.hE<gt>> で定義されている I<P_tmpdir> をパスの先頭に使おうとす"
13893 "る。 これが失敗した場合は、ディレクトリ I</tmp> を使う。"
13894
13895 #. type: Plain text
13896 #: build/C/man3/tmpfile.3:103
13897 msgid "B<exit>(3), B<mkstemp>(3), B<mktemp>(3), B<tempnam>(3), B<tmpnam>(3)"
13898 msgstr "B<exit>(3), B<mkstemp>(3), B<mktemp>(3), B<tempnam>(3), B<tmpnam>(3)"
13899
13900 #. type: TH
13901 #: build/C/man3/tmpnam.3:27
13902 #, no-wrap
13903 msgid "TMPNAM"
13904 msgstr "TMPNAM"
13905
13906 #. type: Plain text
13907 #: build/C/man3/tmpnam.3:30
13908 msgid "tmpnam, tmpnam_r - create a name for a temporary file"
13909 msgstr "tmpnam, tmpnam_r - 一時ファイルの名前を作成する"
13910
13911 #. type: Plain text
13912 #: build/C/man3/tmpnam.3:35
13913 #, no-wrap
13914 msgid "B<char *tmpnam(char *>I<s>B<);>\n"
13915 msgstr "B<char *tmpnam(char *>I<s>B<);>\n"
13916
13917 #. type: Plain text
13918 #: build/C/man3/tmpnam.3:58
13919 msgid ""
13920 "The B<tmpnam>()  function returns a pointer to a string that is a valid "
13921 "filename, and such that a file with this name did not exist at some point in "
13922 "time, so that naive programmers may think it a suitable name for a temporary "
13923 "file.  If the argument I<s> is NULL this name is generated in an internal "
13924 "static buffer and may be overwritten by the next call to B<tmpnam>().  If "
13925 "I<s> is not NULL, the name is copied to the character array (of length at "
13926 "least I<L_tmpnam>)  pointed to by I<s> and the value I<s> is returned in "
13927 "case of success."
13928 msgstr ""
13929 "B<tmpnam>()  関数は、ファイル名に使える文字列へのポインタを返す。 ある時点で"
13930 "は同じ名前を持つファイルが存在しないファイル名が返されるので、 幼稚なプログラ"
13931 "マはこの文字列が一時ファイルのファイル名として 適していると考えるかもしれな"
13932 "い。 引き数 I<s> が NULL なら、この名前は内部の静的バッファに作成され、 次に "
13933 "B<tmpnam>()  関数が呼び出された時に上書きされる。 I<s> が NULL でなければ、"
13934 "ファイル名は I<s> が指す (少なくとも I<L_tmpnam> の長さを持つ) 文字配列にコ"
13935 "ピーされ、 成功した場合は I<s> が返される。"
13936
13937 #. type: Plain text
13938 #: build/C/man3/tmpnam.3:70
13939 msgid ""
13940 "The pathname that is created, has a directory prefix I<P_tmpdir>.  (Both "
13941 "I<L_tmpnam> and I<P_tmpdir> are defined in I<E<lt>stdio.hE<gt>>, just like "
13942 "the B<TMP_MAX> mentioned below.)"
13943 msgstr ""
13944 "作成されるパス名は、ディレクトリの部分に I<P_tmpdir> が使われる。 "
13945 "(I<L_tmpnam> と I<P_tmpdir> は、以下で説明する B<TMP_MAX> 同様 I<E<lt>stdio."
13946 "hE<gt>> で定義されている。)"
13947
13948 #. type: Plain text
13949 #: build/C/man3/tmpnam.3:75
13950 msgid ""
13951 "The B<tmpnam>()  function returns a pointer to a unique temporary filename, "
13952 "or NULL if a unique name cannot be generated."
13953 msgstr ""
13954 "B<tmpnam>()  関数は一意な一時ファイル名へのポインタを返す。 一意なファイル名"
13955 "が作成できなかった場合は NULL を返す。"
13956
13957 #. type: Plain text
13958 #: build/C/man3/tmpnam.3:77
13959 msgid "No errors are defined."
13960 msgstr "エラーは定義されていない。"
13961
13962 #. type: Plain text
13963 #: build/C/man3/tmpnam.3:83
13964 msgid ""
13965 "The B<tmpnam>()  function is thread-safe with exceptions.  It is not thread-"
13966 "safe if called with a NULL parameter."
13967 msgstr ""
13968
13969 #. type: Plain text
13970 #: build/C/man3/tmpnam.3:87
13971 msgid "The B<tmpnam_r>()  function is thread-safe."
13972 msgstr ""
13973
13974 #. type: Plain text
13975 #: build/C/man3/tmpnam.3:92
13976 msgid ""
13977 "SVr4, 4.3BSD, C89, C99, POSIX.1-2001.  POSIX.1-2008 marks B<tmpnam>()  as "
13978 "obsolete."
13979 msgstr ""
13980 "SVr4, 4.3BSD, C89, C99, POSIX.1-2001.  POSIX.1-2008 は B<tmpnam>()  を廃止予"
13981 "定としている。"
13982
13983 #. type: Plain text
13984 #: build/C/man3/tmpnam.3:103
13985 msgid ""
13986 "The B<tmpnam>()  function generates a different string each time it is "
13987 "called, up to B<TMP_MAX> times.  If it is called more than B<TMP_MAX> times, "
13988 "the behavior is implementation defined."
13989 msgstr ""
13990 "B<tmpnam>()  関数は最大 B<TMP_MAX> 回まで、呼び出される度に異なる文字列を作成"
13991 "する。 B<TMP_MAX> 回以上呼び出された場合、その動作は実装依存である。"
13992
13993 #. type: Plain text
13994 #: build/C/man3/tmpnam.3:122
13995 msgid ""
13996 "Although B<tmpnam>()  generates names that are difficult to guess, it is "
13997 "nevertheless possible that between the time that B<tmpnam>()  returns a "
13998 "pathname, and the time that the program opens it, another program might "
13999 "create that pathname using B<open>(2), or create it as a symbolic link.  "
14000 "This can lead to security holes.  To avoid such possibilities, use the "
14001 "B<open>(2)  B<O_EXCL> flag to open the pathname.  Or better yet, use "
14002 "B<mkstemp>(3)  or B<tmpfile>(3)."
14003 msgstr ""
14004 "B<tmpnam>()  は推測が難しい名前を生成するが、それにもかかわらず、 B<tmpnam>"
14005 "()  がパス名を返してから、プログラムがそのファイルをオープンする までの間に、"
14006 "別のプログラムが同じパス名で、ファイルを B<open>(2)  で作成したり、シンボリッ"
14007 "クリンクを作成したりする可能性がある。 これはセキュリティホールにつながる可能"
14008 "性がある。 そのような可能性を回避するためには、 B<open>(2)  の B<O_EXCL> フラ"
14009 "グを使ってパス名をオープンすればよい。 もっといいのは、 B<mkstemp>(3)  や "
14010 "B<tmpfile>(3)  を使うことである。"
14011
14012 #. type: Plain text
14013 #: build/C/man3/tmpnam.3:130
14014 msgid ""
14015 "Portable applications that use threads cannot call B<tmpnam>()  with a NULL "
14016 "argument if either B<_POSIX_THREADS> or B<_POSIX_THREAD_SAFE_FUNCTIONS> is "
14017 "defined."
14018 msgstr ""
14019 "移植性が必要な、スレッドを使ったアプリケーションでは、 B<_POSIX_THREADS> か "
14020 "B<_POSIX_THREAD_SAFE_FUNCTIONS> が定義されている場合に、 B<tmpnam>()  関数を "
14021 "NULL 引き数で呼び出してはならない。"
14022
14023 #. type: Plain text
14024 #: build/C/man3/tmpnam.3:134
14025 msgid "A POSIX draft proposed to use a function B<tmpnam_r>()  defined by"
14026 msgstr ""
14027 "POSIX 草案では、関数 B<tmpnam_r>()  を使うことを提案している。 この関数は、以"
14028 "下のように定義されており、 NULL を使わないようにという警告の意味で NULL を別"
14029 "扱いしている。"
14030
14031 #. type: Plain text
14032 #: build/C/man3/tmpnam.3:142
14033 #, no-wrap
14034 msgid ""
14035 "char *\n"
14036 "tmpnam_r(char *s)\n"
14037 "{\n"
14038 "    return s ? tmpnam(s) : NULL;\n"
14039 "}\n"
14040 msgstr ""
14041 "char *\n"
14042 "tmpnam_r(char *s)\n"
14043 "{\n"
14044 "    return s ? tmpnam(s) : NULL;\n"
14045 "}\n"
14046
14047 #. type: Plain text
14048 #: build/C/man3/tmpnam.3:156
14049 msgid ""
14050 "apparently as a warning not to use NULL.  A few systems implement it.  To "
14051 "get a glibc prototype for this function from I<E<lt>stdio.hE<gt>>, define "
14052 "B<_SVID_SOURCE> or B<_BSD_SOURCE> (before including I<any> header file)."
14053 msgstr ""
14054 "数は少ないが、この関数を実装しているシステムもある。 この関数の glibc のプロ"
14055 "トタイプを I<E<lt>stdio.hE<gt>> から得るには、 (「どの」ヘッダファイルをイン"
14056 "クルードするよりも前に)  B<_SVID_SOURCE> か B<_BSD_SOURCE> を定義しておく必要"
14057 "がある。"
14058
14059 #. type: Plain text
14060 #: build/C/man3/tmpnam.3:168
14061 msgid "B<mkstemp>(3), B<mktemp>(3), B<tempnam>(3), B<tmpfile>(3)"
14062 msgstr "B<mkstemp>(3), B<mktemp>(3), B<tempnam>(3), B<tmpfile>(3)"
14063
14064 #. type: TH
14065 #: build/C/man2/unlink.2:32
14066 #, no-wrap
14067 msgid "UNLINK"
14068 msgstr "UNLINK"
14069
14070 #. type: TH
14071 #: build/C/man2/unlink.2:32
14072 #, no-wrap
14073 msgid "2011-09-15"
14074 msgstr "2011-09-15"
14075
14076 #. type: Plain text
14077 #: build/C/man2/unlink.2:35
14078 msgid "unlink - delete a name and possibly the file it refers to"
14079 msgstr ""
14080 "unlink - 名前を削除し、場合によってはそれが参照しているファイルも削除する"
14081
14082 #. type: Plain text
14083 #: build/C/man2/unlink.2:39
14084 msgid "B<int unlink(const char *>I<pathname>B<);>"
14085 msgstr "B<int unlink(const char *>I<pathname>B<);>"
14086
14087 #. type: Plain text
14088 #: build/C/man2/unlink.2:45
14089 msgid ""
14090 "B<unlink>()  deletes a name from the file system.  If that name was the last "
14091 "link to a file and no processes have the file open the file is deleted and "
14092 "the space it was using is made available for reuse."
14093 msgstr ""
14094 "B<unlink>()  はファイルシステム上の名前を削除する。 もしその名前がファイルへ"
14095 "の最後のリンク (link) であり、 どのプロセスもそのファイルをオープン (open) し"
14096 "ていなければ、 ファイルは削除される。 ファイルが使用していたディスク上の領域"
14097 "は再利用が可能になる。"
14098
14099 #. type: Plain text
14100 #: build/C/man2/unlink.2:49
14101 msgid ""
14102 "If the name was the last link to a file but any processes still have the "
14103 "file open the file will remain in existence until the last file descriptor "
14104 "referring to it is closed."
14105 msgstr ""
14106 "もし削除する名前がファイルへの最後のリンクだが、どれかのプロセスが そのファイ"
14107 "ルをまだオープンしている場合は、 そのファイルを参照している最後のファイルディ"
14108 "スクリプタ (file descriptor)  がクローズ (close) されるまでファイルは存在し続"
14109 "ける。"
14110
14111 #. type: Plain text
14112 #: build/C/man2/unlink.2:51
14113 msgid "If the name referred to a symbolic link the link is removed."
14114 msgstr ""
14115 "もしその名前がシンボリックリンク (symbolic link) を参照していれば、 リンクは"
14116 "削除される。"
14117
14118 #. type: Plain text
14119 #: build/C/man2/unlink.2:55
14120 msgid ""
14121 "If the name referred to a socket, fifo or device the name for it is removed "
14122 "but processes which have the object open may continue to use it."
14123 msgstr ""
14124 "もし名前がソケット (socket) や fifo やデバイス (device) を参照していれば 名前"
14125 "は削除されるがそのオブジェクトをオープンしていたプロセスは それを使い続けるこ"
14126 "とができる。"
14127
14128 #. type: Plain text
14129 #: build/C/man2/unlink.2:71
14130 msgid ""
14131 "Write access to the directory containing I<pathname> is not allowed for the "
14132 "process's effective UID, or one of the directories in I<pathname> did not "
14133 "allow search permission.  (See also B<path_resolution>(7).)"
14134 msgstr ""
14135 "I<pathname> を含んでいるディレクトリの書き込み許可がプロセスの実効 "
14136 "(effective)  ユーザー ID に与えられていないか、 I<pathname> の中のディレクト"
14137 "リのどれかに検索許可が与えられていない (B<path_resolution>(7)  も参照するこ"
14138 "と)。"
14139
14140 #. type: Plain text
14141 #: build/C/man2/unlink.2:80
14142 msgid ""
14143 "The file I<pathname> cannot be unlinked because it is being used by the "
14144 "system or another process; for example, it is a mount point or the NFS "
14145 "client software created it to represent an active but otherwise nameless "
14146 "inode (\"NFS silly renamed\")."
14147 msgstr ""
14148 "システムか別のプロセスがそのファイルを使用中のため、\n"
14149 "ファイル I<pathname> を unlink できない。\n"
14150 "例えば、そのファイルがマウントポイントの場合や、\n"
14151 "NFS クライアントソフトウェアがそのファイルがアクティブであるが\n"
14152 "名前なし inode (nameless inode) であることを示すために作成した\n"
14153 "場合 (\"NFS silly renamed\") などがある。"
14154
14155 #. type: Plain text
14156 #: build/C/man2/unlink.2:92
14157 msgid ""
14158 "I<pathname> refers to a directory.  (This is the non-POSIX value returned by "
14159 "Linux since 2.1.132.)"
14160 msgstr ""
14161 "I<pathname> がディレクトリを参照している。 (これは POSIX で規定されていない値"
14162 "で、Linux 2.1.132 以降で返される。)"
14163
14164 #. type: Plain text
14165 #: build/C/man2/unlink.2:96
14166 msgid "Too many symbolic links were encountered in translating I<pathname>."
14167 msgstr "I<pathname> を解決する際に遭遇したシンボリックリンクが多過ぎる。"
14168
14169 #. type: Plain text
14170 #: build/C/man2/unlink.2:106
14171 msgid ""
14172 "A component in I<pathname> does not exist or is a dangling symbolic link, or "
14173 "I<pathname> is empty."
14174 msgstr ""
14175 "I<pathname> に対応するものが存在しないか、壊れたシンボリックリンクであるか、 "
14176 "I<pathname> が空である。"
14177
14178 #. type: Plain text
14179 #: build/C/man2/unlink.2:114
14180 msgid ""
14181 "A component used as a directory in I<pathname> is not, in fact, a directory."
14182 msgstr "I<pathname> のディレクトリ部分が、実際には、ディレクトリでない。"
14183
14184 #. type: Plain text
14185 #: build/C/man2/unlink.2:123
14186 msgid ""
14187 "The system does not allow unlinking of directories, or unlinking of "
14188 "directories requires privileges that the calling process doesn't have.  "
14189 "(This is the POSIX prescribed error return; as noted above, Linux returns "
14190 "B<EISDIR> for this case.)"
14191 msgstr ""
14192 "システムがディレクトリに対する unlink 操作を許可していない。 またはディレクト"
14193 "リに対する unlink 操作のために必要な特権を 呼び出し元のプロセスが持っていな"
14194 "い。 (これは POSIX で規定されているエラーの返し方である。 上述の通り、この場"
14195 "合には Linux は B<EISDIR> を返す。)"
14196
14197 #. type: TP
14198 #: build/C/man2/unlink.2:123
14199 #, no-wrap
14200 msgid "B<EPERM> (Linux only)"
14201 msgstr "B<EPERM> (Linux のみ)"
14202
14203 #. type: Plain text
14204 #: build/C/man2/unlink.2:126
14205 msgid "The file system does not allow unlinking of files."
14206 msgstr "ファイルシステムがファイルに対する unlink 操作を許していない。"
14207
14208 #. type: Plain text
14209 #: build/C/man2/unlink.2:137
14210 msgid ""
14211 "The directory containing I<pathname> has the sticky bit (B<S_ISVTX>)  set "
14212 "and the process's effective UID is neither the UID of the file to be deleted "
14213 "nor that of the directory containing it, and the process is not privileged "
14214 "(Linux: does not have the B<CAP_FOWNER> capability)."
14215 msgstr ""
14216 "I<pathname> を含んでいるディレクトリにスティッキービット (sticky-bit)  "
14217 "(B<S_ISVTX>)  が設定されていて、プロセスの実効ユーザー ID が削除しようとする"
14218 "ファイルの UID でもそれを含んでいるディレクトリのものでもなく、 かつプロセス"
14219 "に特権がない (Linux では B<CAP_FOWNER> ケーパビリティ (capability) がない)。"
14220
14221 #. type: Plain text
14222 #: build/C/man2/unlink.2:141
14223 msgid "I<pathname> refers to a file on a read-only file system."
14224 msgstr "I<pathname> が読み込み専用のファイルシステムのファイルを参照している。"
14225
14226 #. type: Plain text
14227 #: build/C/man2/unlink.2:161
14228 msgid ""
14229 "B<rm>(1), B<chmod>(2), B<link>(2), B<mknod>(2), B<open>(2), B<rename>(2), "
14230 "B<rmdir>(2), B<unlinkat>(2), B<mkfifo>(3), B<remove>(3), B<path_resolution>"
14231 "(7), B<symlink>(7)"
14232 msgstr ""
14233 "B<rm>(1), B<chmod>(2), B<link>(2), B<mknod>(2), B<open>(2), B<rename>(2), "
14234 "B<rmdir>(2), B<unlinkat>(2), B<mkfifo>(3), B<remove>(3), B<path_resolution>"
14235 "(7), B<symlink>(7)"
14236
14237 #. type: TH
14238 #: build/C/man3/unlocked_stdio.3:25
14239 #, no-wrap
14240 msgid "UNLOCKED_STDIO"
14241 msgstr "UNLOCKED_STDIO"
14242
14243 #. type: Plain text
14244 #: build/C/man3/unlocked_stdio.3:29
14245 msgid ""
14246 "getc_unlocked, getchar_unlocked, putc_unlocked, putchar_unlocked - "
14247 "nonlocking stdio functions"
14248 msgstr ""
14249 "getc_unlocked, getchar_unlocked, putc_unlocked, putchar_unlocked - ロックを行"
14250 "わずに標準入出力を行う関数群"
14251
14252 #. type: Plain text
14253 #: build/C/man3/unlocked_stdio.3:37
14254 #, no-wrap
14255 msgid ""
14256 "B<int getc_unlocked(FILE *>I<stream>B<);>\n"
14257 "B<int getchar_unlocked(void);>\n"
14258 "B<int putc_unlocked(int >I<c>B<, FILE *>I<stream>B<);>\n"
14259 "B<int putchar_unlocked(int >I<c>B<);>\n"
14260 msgstr ""
14261 "B<int getc_unlocked(FILE *>I<stream>B<);>\n"
14262 "B<int getchar_unlocked(void);>\n"
14263 "B<int putc_unlocked(int >I<c>B<, FILE *>I<stream>B<);>\n"
14264 "B<int putchar_unlocked(int >I<c>B<);>\n"
14265
14266 #. type: Plain text
14267 #: build/C/man3/unlocked_stdio.3:49
14268 #, no-wrap
14269 msgid ""
14270 "B<void clearerr_unlocked(FILE *>I<stream>B<);>\n"
14271 "B<int feof_unlocked(FILE *>I<stream>B<);>\n"
14272 "B<int ferror_unlocked(FILE *>I<stream>B<);>\n"
14273 "B<int fileno_unlocked(FILE *>I<stream>B<);>\n"
14274 "B<int fflush_unlocked(FILE *>I<stream>B<);>\n"
14275 "B<int fgetc_unlocked(FILE *>I<stream>B<);>\n"
14276 "B<int fputc_unlocked(int >I<c>B<, FILE *>I<stream>B<);>\n"
14277 "B<size_t fread_unlocked(void *>I<ptr>B<, size_t >I<size>B<, size_t >I<n>B<,>\n"
14278 "B<                      FILE *>I<stream>B<);>\n"
14279 "B<size_t fwrite_unlocked(const void *>I<ptr>B<, size_t >I<size>B<, size_t >I<n>B<,>\n"
14280 "B<                      FILE *>I<stream>B<);>\n"
14281 msgstr ""
14282 "B<void clearerr_unlocked(FILE *>I<stream>B<);>\n"
14283 "B<int feof_unlocked(FILE *>I<stream>B<);>\n"
14284 "B<int ferror_unlocked(FILE *>I<stream>B<);>\n"
14285 "B<int fileno_unlocked(FILE *>I<stream>B<);>\n"
14286 "B<int fflush_unlocked(FILE *>I<stream>B<);>\n"
14287 "B<int fgetc_unlocked(FILE *>I<stream>B<);>\n"
14288 "B<int fputc_unlocked(int >I<c>B<, FILE *>I<stream>B<);>\n"
14289 "B<size_t fread_unlocked(void *>I<ptr>B<, size_t >I<size>B<, size_t >I<n>B<,>\n"
14290 "B<                      FILE *>I<stream>B<);>\n"
14291 "B<size_t fwrite_unlocked(const void *>I<ptr>B<, size_t >I<size>B<, size_t >I<n>B<,>\n"
14292 "B<                      FILE *>I<stream>B<);>\n"
14293
14294 #. type: Plain text
14295 #: build/C/man3/unlocked_stdio.3:52
14296 #, no-wrap
14297 msgid ""
14298 "B<char *fgets_unlocked(char *>I<s>B<, int >I<n>B<, FILE *>I<stream>B<);>\n"
14299 "B<int fputs_unlocked(const char *>I<s>B<, FILE *>I<stream>B<);>\n"
14300 msgstr ""
14301 "B<char *fgets_unlocked(char *>I<s>B<, int >I<n>B<, FILE *>I<stream>B<);>\n"
14302 "B<int fputs_unlocked(const char *>I<s>B<, FILE *>I<stream>B<);>\n"
14303
14304 #. type: Plain text
14305 #: build/C/man3/unlocked_stdio.3:63
14306 #, no-wrap
14307 msgid ""
14308 "B<wint_t getwc_unlocked(FILE *>I<stream>B<);>\n"
14309 "B<wint_t getwchar_unlocked(void);>\n"
14310 "B<wint_t fgetwc_unlocked(FILE *>I<stream>B<);>\n"
14311 "B<wint_t fputwc_unlocked(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
14312 "B<wint_t putwc_unlocked(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
14313 "B<wint_t putwchar_unlocked(wchar_t >I<wc>B<);>\n"
14314 "B<wchar_t *fgetws_unlocked(wchar_t *>I<ws>B<, int >I<n>B<, FILE *>I<stream>B<);>\n"
14315 "B<int fputws_unlocked(const wchar_t *>I<ws>B<, FILE *>I<stream>B<);>\n"
14316 msgstr ""
14317 "B<wint_t getwc_unlocked(FILE *>I<stream>B<);>\n"
14318 "B<wint_t getwchar_unlocked(void);>\n"
14319 "B<wint_t fgetwc_unlocked(FILE *>I<stream>B<);>\n"
14320 "B<wint_t fputwc_unlocked(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
14321 "B<wint_t putwc_unlocked(wchar_t >I<wc>B<, FILE *>I<stream>B<);>\n"
14322 "B<wint_t putwchar_unlocked(wchar_t >I<wc>B<);>\n"
14323 "B<wchar_t *fgetws_unlocked(wchar_t *>I<ws>B<, int >I<n>B<, FILE *>I<stream>B<);>\n"
14324 "B<int fputws_unlocked(const wchar_t *>I<ws>B<, FILE *>I<stream>B<);>\n"
14325
14326 #. type: Plain text
14327 #: build/C/man3/unlocked_stdio.3:75
14328 msgid ""
14329 "B<getc_unlocked>(), B<getchar_unlocked>(), B<putc_unlocked>(), "
14330 "B<putchar_unlocked>():"
14331 msgstr ""
14332 "B<getc_unlocked>(), B<getchar_unlocked>(), B<putc_unlocked>(), "
14333 "B<putchar_unlocked>():"
14334
14335 #. type: Plain text
14336 #: build/C/man3/unlocked_stdio.3:78
14337 msgid ""
14338 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE || "
14339 "_BSD_SOURCE || _SVID_SOURCE"
14340 msgstr ""
14341 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE || "
14342 "_BSD_SOURCE || _SVID_SOURCE"
14343
14344 #. type: Plain text
14345 #: build/C/man3/unlocked_stdio.3:89
14346 msgid ""
14347 "B<clearerr_unlocked>(), B<feof_unlocked>(), B<ferror_unlocked>(), "
14348 "B<fileno_unlocked>(), B<fflush_unlocked>(), B<fgetc_unlocked>(), "
14349 "B<fputc_unlocked>(), B<fread_unlocked>(), B<fwrite_unlocked>():"
14350 msgstr ""
14351 "B<clearerr_unlocked>(), B<feof_unlocked>(), B<ferror_unlocked>(), "
14352 "B<fileno_unlocked>(), B<fflush_unlocked>(), B<fgetc_unlocked>(), "
14353 "B<fputc_unlocked>(), B<fread_unlocked>(), B<fwrite_unlocked>():"
14354
14355 #. type: Plain text
14356 #: build/C/man3/unlocked_stdio.3:91
14357 msgid "_BSD_SOURCE || _SVID_SOURCE"
14358 msgstr "_BSD_SOURCE || _SVID_SOURCE"
14359
14360 #. type: Plain text
14361 #: build/C/man3/unlocked_stdio.3:102
14362 msgid ""
14363 "B<fgets_unlocked>(), B<fputs_unlocked>(), B<getwc_unlocked>(), "
14364 "B<getwchar_unlocked>(), B<fgetwc_unlocked>(), B<fputwc_unlocked>(), "
14365 "B<putwchar_unlocked>(), B<fgetws_unlocked>(), B<fputws_unlocked>():"
14366 msgstr ""
14367 "B<fgets_unlocked>(), B<fputs_unlocked>(), B<getwc_unlocked>(), "
14368 "B<getwchar_unlocked>(), B<fgetwc_unlocked>(), B<fputwc_unlocked>(), "
14369 "B<putwchar_unlocked>(), B<fgetws_unlocked>(), B<fputws_unlocked>():"
14370
14371 #. type: Plain text
14372 #: build/C/man3/unlocked_stdio.3:113
14373 msgid ""
14374 "Each of these functions has the same behavior as its counterpart without the "
14375 "\"_unlocked\" suffix, except that they do not use locking (they do not set "
14376 "locks themselves, and do not test for the presence of locks set by others) "
14377 "and hence are thread-unsafe.  See B<flockfile>(3)."
14378 msgstr ""
14379 "これらの関数は、末尾に \"_unlocked\" がついていない関数と同じ動作をするが、 "
14380 "ファイルのロックを使用しない点が異なる。(これらの関数自身はファイルのロック "
14381 "をセットせず、他の関数によってロックがセットされているかどうかのチェックも 行"
14382 "わない) それゆえ、スレッド(thread)で安全に使用することができない。 "
14383 "B<flockfile>(3)  を参照のこと。"
14384
14385 #. type: Plain text
14386 #: build/C/man3/unlocked_stdio.3:120
14387 msgid ""
14388 "The four functions B<getc_unlocked>(), B<getchar_unlocked>(), "
14389 "B<putc_unlocked>(), B<putchar_unlocked>()  are in POSIX.1-2001."
14390 msgstr ""
14391 "B<getc_unlocked>(), B<getchar_unlocked>(), B<putc_unlocked>(), "
14392 "B<putchar_unlocked>()  の 4 つの関数は POSIX.1-2001 に規定されている。"
14393
14394 #.  E.g., in HP-UX 10.0. In HP-UX 10.30 they are called obsolescent, and
14395 #.  moved to a compatibility library.
14396 #.  Available in HP-UX 10.0: clearerr_unlocked, fclose_unlocked,
14397 #.  feof_unlocked, ferror_unlocked, fflush_unlocked, fgets_unlocked,
14398 #.  fgetwc_unlocked, fgetws_unlocked, fileno_unlocked, fputs_unlocked,
14399 #.  fputwc_unlocked, fputws_unlocked, fread_unlocked, fseek_unlocked,
14400 #.  ftell_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
14401 #.  getw_unlocked, getwc_unlocked, getwchar_unlocked, putc_unlocked,
14402 #.  putchar_unlocked, puts_unlocked, putws_unlocked, putw_unlocked,
14403 #.  putwc_unlocked, putwchar_unlocked, rewind_unlocked, setvbuf_unlocked,
14404 #.  ungetc_unlocked, ungetwc_unlocked.
14405 #. type: Plain text
14406 #: build/C/man3/unlocked_stdio.3:136
14407 msgid ""
14408 "The nonstandard B<*_unlocked>()  variants occur on a few UNIX systems, and "
14409 "are available in recent glibc.  They should probably not be used."
14410 msgstr ""
14411 "非標準の B<*_unlocked>()  の仲間は 2、3 の UNIX システムで定義されており、 最"
14412 "近の glibc では使用可能であるが、 これらの関数は使わない方がよいだろう。"
14413
14414 #. type: Plain text
14415 #: build/C/man3/unlocked_stdio.3:139
14416 msgid "B<flockfile>(3), B<stdio>(3)"
14417 msgstr "B<flockfile>(3), B<stdio>(3)"
14418
14419 #. type: TH
14420 #: build/C/man3/wprintf.3:16
14421 #, no-wrap
14422 msgid "WPRINTF"
14423 msgstr "WPRINTF"
14424
14425 #. type: TH
14426 #: build/C/man3/wprintf.3:16
14427 #, no-wrap
14428 msgid "2011-09-17"
14429 msgstr "2011-09-17"
14430
14431 #. type: Plain text
14432 #: build/C/man3/wprintf.3:20
14433 msgid ""
14434 "wprintf, fwprintf, swprintf, vwprintf, vfwprintf, vswprintf - formatted wide-"
14435 "character output conversion"
14436 msgstr ""
14437 "wprintf, fwprintf, swprintf, vwprintf, vfwprintf, vswprintf - ワイド文字を "
14438 "フォーマットして出力する"
14439
14440 #. type: Plain text
14441 #: build/C/man3/wprintf.3:24
14442 #, no-wrap
14443 msgid ""
14444 "B<#include E<lt>stdio.hE<gt>>\n"
14445 "B<#include E<lt>wchar.hE<gt>>\n"
14446 msgstr ""
14447 "B<#include E<lt>stdio.hE<gt>>\n"
14448 "B<#include E<lt>wchar.hE<gt>>\n"
14449
14450 #. type: Plain text
14451 #: build/C/man3/wprintf.3:29
14452 #, no-wrap
14453 msgid ""
14454 "B<int wprintf(const wchar_t *>I<format>B<, ...);>\n"
14455 "B<int fwprintf(FILE *>I<stream>B<, const wchar_t *>I<format>B<, ...);>\n"
14456 "B<int swprintf(wchar_t *>I<wcs>B<, size_t >I<maxlen>B<,>\n"
14457 "B<             const wchar_t *>I<format>B<, ...);>\n"
14458 msgstr ""
14459 "B<int wprintf(const wchar_t *>I<format>B<, ...);>\n"
14460 "B<int fwprintf(FILE *>I<stream>B<, const wchar_t *>I<format>B<, ...);>\n"
14461 "B<int swprintf(wchar_t *>I<wcs>B<, size_t >I<maxlen>B<,>\n"
14462 "B<             const wchar_t *>I<format>B<, ...);>\n"
14463
14464 #. type: Plain text
14465 #: build/C/man3/wprintf.3:34
14466 #, no-wrap
14467 msgid ""
14468 "B<int vwprintf(const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14469 "B<int vfwprintf(FILE *>I<stream>B<, const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14470 "B<int vswprintf(wchar_t *>I<wcs>B<, size_t >I<maxlen>B<,>\n"
14471 "B<              const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14472 msgstr ""
14473 "B<int vwprintf(const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14474 "B<int vfwprintf(FILE *>I<stream>B<, const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14475 "B<int vswprintf(wchar_t *>I<wcs>B<, size_t >I<maxlen>B<,>\n"
14476 "B<              const wchar_t *>I<format>B<, va_list >I<args>B<);>\n"
14477
14478 #.  .BR wprintf (),
14479 #.  .BR fwprintf (),
14480 #.  .BR swprintf (),
14481 #.  .BR vwprintf (),
14482 #.  .BR vfwprintf (),
14483 #.  .BR vswprintf ():
14484 #. type: Plain text
14485 #: build/C/man3/wprintf.3:51
14486 msgid "_XOPEN_SOURCE\\ E<gt>=\\ 500 || _ISOC99_SOURCE ||"
14487 msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 500 || _ISOC99_SOURCE ||"
14488
14489 #. type: Plain text
14490 #: build/C/man3/wprintf.3:53
14491 msgid "_ISOC95_SOURCE /* Since glibc 2.12 */ ||"
14492 msgstr "_ISOC95_SOURCE /* Since glibc 2.12 */ ||"
14493
14494 #. type: Plain text
14495 #: build/C/man3/wprintf.3:55
14496 msgid "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L;"
14497 msgstr "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L;"
14498
14499 #. type: Plain text
14500 #: build/C/man3/wprintf.3:58
14501 msgid "or I<cc\\ -std=c99>"
14502 msgstr "or I<cc\\ -std=c99>"
14503
14504 #. type: Plain text
14505 #: build/C/man3/wprintf.3:69
14506 msgid ""
14507 "The B<wprintf>()  family of functions is the wide-character equivalent of "
14508 "the B<printf>(3)  family of functions.  It performs formatted output of wide "
14509 "characters."
14510 msgstr ""
14511 "B<wprintf>()  ファミリーの関数は B<printf>(3)  ファミリーの関数の ワイド文字"
14512 "版である。これらはワイド文字をフォーマットして出力する。"
14513
14514 #. type: Plain text
14515 #: build/C/man3/wprintf.3:81
14516 msgid ""
14517 "The B<wprintf>()  and B<vwprintf>()  functions perform wide-character output "
14518 "to I<stdout>.  I<stdout> must not be byte oriented; see B<fwide>(3)  for "
14519 "more information."
14520 msgstr ""
14521 "B<wprintf>()  と B<vwprintf>()  関数は I<stdout> に出力を行なう。 I<stdout> "
14522 "がバイト単位入出力であってはいけない。より詳しい説明は B<fwide>(3)  を参照す"
14523 "ること。"
14524
14525 #. type: Plain text
14526 #: build/C/man3/wprintf.3:93
14527 msgid ""
14528 "The B<fwprintf>()  and B<vfwprintf>()  functions perform wide-character "
14529 "output to I<stream>.  I<stream> must not be byte oriented; see B<fwide>(3)  "
14530 "for more information."
14531 msgstr ""
14532 "B<fwprintf>()  と B<vfwprintf>()  関数は I<stream> にワイド文字出力 を行な"
14533 "う。 I<stream> がバイト単位入出力であってはいけない。 より詳しい説明は "
14534 "B<fwide>(3)  を参照すること。"
14535
14536 #. type: Plain text
14537 #: build/C/man3/wprintf.3:107
14538 msgid ""
14539 "The B<swprintf>()  and B<vswprintf>()  functions perform wide-character "
14540 "output to an array of wide characters.  The programmer must ensure that "
14541 "there is room for at least I<maxlen> wide characters at I<wcs>."
14542 msgstr ""
14543 "B<swprintf>()  と B<vswprintf>()  関数はワイド文字の配列に ワイド文字出力を行"
14544 "なう。プログラマーは I<wcs> に最低でも I<maxlen> 文字のワイド文字を出力できる"
14545 "空きがあることを保証しなければ ならない。"
14546
14547 #. type: Plain text
14548 #: build/C/man3/wprintf.3:118
14549 msgid ""
14550 "These functions are like the B<printf>(3), B<vprintf>(3), B<fprintf>(3), "
14551 "B<vfprintf>(3), B<sprintf>(3), B<vsprintf>(3)  functions except for the "
14552 "following differences:"
14553 msgstr ""
14554 "これらの関数は B<printf>(3), B<vprintf>(3), B<fprintf>(3), B<vfprintf>(3), "
14555 "B<sprintf>(3), B<vsprintf>(3)  関数に似ているが以下の 点で異っている。"
14556
14557 #. type: TP
14558 #: build/C/man3/wprintf.3:118 build/C/man3/wprintf.3:123
14559 #: build/C/man3/wprintf.3:126
14560 #, no-wrap
14561 msgid "B<\\(bu>"
14562 msgstr "B<\\(bu>"
14563
14564 #. type: Plain text
14565 #: build/C/man3/wprintf.3:123
14566 msgid "The I<format> string is a wide-character string."
14567 msgstr "I<format> がワイド文字列で与えられる。"
14568
14569 #. type: Plain text
14570 #: build/C/man3/wprintf.3:126
14571 msgid "The output consists of wide characters, not bytes."
14572 msgstr "出力がバイトではなくワイド文字で構成される。"
14573
14574 #. type: Plain text
14575 #: build/C/man3/wprintf.3:145
14576 msgid ""
14577 "B<swprintf>()  and B<vswprintf>()  take a I<maxlen> argument, B<sprintf>(3)  "
14578 "and B<vsprintf>(3)  do not.  (B<snprintf>(3)  and B<vsnprintf>(3)  take a "
14579 "I<maxlen> argument, but these functions do not return -1 upon buffer "
14580 "overflow on Linux.)"
14581 msgstr ""
14582 "B<swprintf>()  と B<vswprintf>()  は I<maxlen> 引き数を取るが、 B<sprintf>"
14583 "()  と B<vsprintf>()  は取らない (B<snprintf>()  と B<vsnprintf>()  は "
14584 "I<maxlen> 引き数を取るが これらの関数が Linux では、バッファーが溢れた場合で"
14585 "も -1 を返さない)。"
14586
14587 #. type: Plain text
14588 #: build/C/man3/wprintf.3:151
14589 msgid "The treatment of the conversion characters B<c> and B<s> is different:"
14590 msgstr "B<c> と B<s> 変換文字の扱いが異っている:"
14591
14592 #. type: Plain text
14593 #: build/C/man3/wprintf.3:165
14594 msgid ""
14595 "If no B<l> modifier is present, the I<int> argument is converted to a wide "
14596 "character by a call to the B<btowc>(3)  function, and the resulting wide "
14597 "character is written.  If an B<l> modifier is present, the I<wint_t> (wide "
14598 "character) argument is written."
14599 msgstr ""
14600 "もし B<l> 修飾子が存在しない場合は I<int> 引き数は B<btowc>(3)  関数によって"
14601 "ワイド文字に変換される。そして結果のワイド文字が出力される。 B<l> 修飾子が存"
14602 "在する場合は I<wint_t> (ワイド文字)引き数が出力される。"
14603
14604 #. type: Plain text
14605 #: build/C/man3/wprintf.3:205
14606 msgid ""
14607 "If no B<l> modifier is present: The I<const\\ char\\ *> argument is expected "
14608 "to be a pointer to an array of character type (pointer to a string) "
14609 "containing a multibyte character sequence beginning in the initial shift "
14610 "state.  Characters from the array are converted to wide characters (each by "
14611 "a call to the B<mbrtowc>(3)  function with a conversion state starting in "
14612 "the initial state before the first byte).  The resulting wide characters are "
14613 "written up to (but not including) the terminating null wide character (L\\(aq"
14614 "\\e0\\(aq).  If a precision is specified, no more wide characters than the "
14615 "number specified are written.  Note that the precision determines the number "
14616 "of I<wide characters> written, not the number of I<bytes> or I<screen "
14617 "positions>.  The array must contain a terminating null byte (\\(aq"
14618 "\\e0\\(aq), unless a precision is given and it is so small that the number "
14619 "of converted wide characters reaches it before the end of the array is "
14620 "reached.  If an B<l> modifier is present: The I<const\\ wchar_t\\ *> "
14621 "argument is expected to be a pointer to an array of wide characters.  Wide "
14622 "characters from the array are written up to (but not including) a "
14623 "terminating null wide character.  If a precision is specified, no more than "
14624 "the number specified are written.  The array must contain a terminating null "
14625 "wide character, unless a precision is given and it is smaller than or equal "
14626 "to the number of wide characters in the array."
14627 msgstr "もし B<l> 修飾子が存在しない場合、 I<const\\ char\\ *> 引き数は初期状態より始まるマルチバイト文字列を含んだ char 型の配列へのポインタ(文字列へのポインタ)とみなされる。 配列の文字は(最初のバイト前に初期状態で変換を開始し、それぞれの文字を B<mbrtowc>(3)  関数によって)ワイド文字へと変換される。結果のワイド文字は終端の ナルワイド文字 (L\\(aq\\e0\\(aq) の手前までが書き込まれる。精度(precision)が指定された 場合、指定された数字を超えるワイド文字は書き込まれない。精度は 書き込まれる I<バイト> 数や I<画面上の位置> ではなく I<ワイド文字> の数を指定することに注意すること。 精度がない場合には配列の終端にナルバイト (\\(aq\\e0\\(aq) を含む必要がある。 精度を指定する場合には、配列の最後に到着する前に変換されたワイド文字の 数がそれに到達するよう、精度は十分に小さな数でなければならない。 もし B<l> 修飾子が存在する場合、 I<const\\ wchar_t\\ *> 引き数はワイド文字の配列へのポインタとみなされる。 配列のワイド文字列は終端のナルワイド文字の手間まで出力される。 もし精度が指定された場合には指定された精度以上の文字は出力されない。 精度を指定しない場合には終端のナルワイド文字を含む必要がある。 精度を指定する場合にはそれはワイド文字の配列の大きさよりも小さくな ければならない。"
14628
14629 #. type: Plain text
14630 #: build/C/man3/wprintf.3:213
14631 msgid ""
14632 "The functions return the number of wide characters written, excluding the "
14633 "terminating null wide character in case of the functions B<swprintf>()  and "
14634 "B<vswprintf>().  They return -1 when an error occurs."
14635 msgstr ""
14636 "これらの関数は書き込まれたワイド文字の文字数を返す。 B<swprintf>()  と "
14637 "B<vswprintf>()  関数の場合は 終端のナルワイド文字は含まない。エラーが起こった"
14638 "場合は -1 を返す。"
14639
14640 #. type: Plain text
14641 #: build/C/man3/wprintf.3:215
14642 msgid "C99."
14643 msgstr "C99."
14644
14645 #. type: Plain text
14646 #: build/C/man3/wprintf.3:223
14647 msgid ""
14648 "The behavior of B<wprintf>()  et al. depends on the B<LC_CTYPE> category of "
14649 "the current locale."
14650 msgstr ""
14651 "B<wprintf>()  等の動作は現在のロケールの B<LC_CTYPE> カテゴリに依存している。"
14652
14653 #. type: Plain text
14654 #: build/C/man3/wprintf.3:253
14655 msgid ""
14656 "If the I<format> string contains non-ASCII wide characters, the program will "
14657 "work correctly only if the B<LC_CTYPE> category of the current locale at run "
14658 "time is the same as the B<LC_CTYPE> category of the current locale at "
14659 "compile time.  This is because the I<wchar_t> representation is platform- "
14660 "and locale-dependent.  (The glibc represents wide characters using their "
14661 "Unicode (ISO-10646) code point, but other platforms don't do this.  Also, "
14662 "the use of C99 universal character names of the form \\eunnnn does not solve "
14663 "this problem.)  Therefore, in internationalized programs, the I<format> "
14664 "string should consist of ASCII wide characters only, or should be "
14665 "constructed at run time in an internationalized way (e.g., using B<gettext>"
14666 "(3)  or B<iconv>(3), followed by B<mbstowcs>(3))."
14667 msgstr ""
14668 "I<format> 文字列が ASCII 以外のワイド文字を含んでいる場合、 実行時のロケール"
14669 "の B<LC_CTYPE> カテゴリがコンパイル時の B<LC_CTYPE> カテゴリと 一致している場"
14670 "合にのみプログラムは正常に動作する。これは I<wchar_t> の表現がロケールやプ"
14671 "ラットホームに依存していることに原因がある。 (glibc ではワイド文字として "
14672 "Unicode (ISO-10646) のコードポイントを 使用している。他のプラットホームではそ"
14673 "うではない。同様に ISO C99 の \\eunnnn 形式の汎用文字名称はこの問題を解決しな"
14674 "い。)  このため国際化されたプログラムでは I<format> 文字列を ASCII ワイド 文"
14675 "字のみにするか、実行時に国際化された方法で構成する必要がある (例えば "
14676 "B<gettext>()  と B<iconv>()  や B<mbstowcs>()  を組み合わて使用する)。"
14677
14678 #.  .BR wscanf (3)
14679 #. type: Plain text
14680 #: build/C/man3/wprintf.3:260
14681 msgid "B<fprintf>(3), B<fputwc>(3), B<fwide>(3), B<printf>(3), B<snprintf>(3)"
14682 msgstr "B<fprintf>(3), B<fputwc>(3), B<fwide>(3), B<printf>(3), B<snprintf>(3)"
14683
14684 #. type: TH
14685 #: build/C/man2/write.2:39
14686 #, no-wrap
14687 msgid "WRITE"
14688 msgstr "WRITE"
14689
14690 #. type: Plain text
14691 #: build/C/man2/write.2:42
14692 msgid "write - write to a file descriptor"
14693 msgstr "write - ファイルディスクリプタ (file descriptor) に書き込む"
14694
14695 #. type: Plain text
14696 #: build/C/man2/write.2:46
14697 msgid ""
14698 "B<ssize_t write(int >I<fd>B<, const void *>I<buf>B<, size_t >I<count>B<);>"
14699 msgstr ""
14700 "B<ssize_t write(int >I<fd>B<, const void *>I<buf>B<, size_t >I<count>B<);>"
14701
14702 #. type: Plain text
14703 #: build/C/man2/write.2:54
14704 msgid ""
14705 "B<write>()  writes up to I<count> bytes from the buffer pointed I<buf> to "
14706 "the file referred to by the file descriptor I<fd>."
14707 msgstr ""
14708 "B<write>()  は、 I<buf> が指すバッファから、ファイルディスクリプタ I<fd> が参"
14709 "照するファイルへ、最大 I<count> バイトを書き込む。"
14710
14711 #. type: Plain text
14712 #: build/C/man2/write.2:68
14713 msgid ""
14714 "The number of bytes written may be less than I<count> if, for example, there "
14715 "is insufficient space on the underlying physical medium, or the "
14716 "B<RLIMIT_FSIZE> resource limit is encountered (see B<setrlimit>(2)), or the "
14717 "call was interrupted by a signal handler after having written less than "
14718 "I<count> bytes.  (See also B<pipe>(7).)"
14719 msgstr ""
14720 "書き込まれるバイト数は I<count> よりも小さくなることがある。 例えば、書き込み"
14721 "対象の物理メディアに十分な領域がない場合、 リソース上限 B<RLIMIT_FSIZE> に達"
14722 "した場合 (B<setrlimit>(2)  参照)、 I<count> バイト未満の書き込みが行われた後"
14723 "で 呼び出しがシグナルハンドラにより割り込まれた場合、 などである。 (B<pipe>"
14724 "(7)  も参照のこと。)"
14725
14726 #. type: Plain text
14727 #: build/C/man2/write.2:82
14728 msgid ""
14729 "For a seekable file (i.e., one to which B<lseek>(2)  may be applied, for "
14730 "example, a regular file)  writing takes place at the current file offset, "
14731 "and the file offset is incremented by the number of bytes actually written.  "
14732 "If the file was B<open>(2)ed with B<O_APPEND>, the file offset is first set "
14733 "to the end of the file before writing.  The adjustment of the file offset "
14734 "and the write operation are performed as an atomic step."
14735 msgstr ""
14736 "seek 可能なファイル (つまり B<lseek>(2)  が適用できるファイル、例えば通常の"
14737 "ファイル) では、 書き込みは現在のファイルオフセットから行われ、 ファイルオフ"
14738 "セットは実際に書き込みが行われたバイト数分 加算される。ファイルが "
14739 "B<O_APPEND> で B<open>(2)  された場合、ファイルオフセットは書き込み前に ファ"
14740 "イルの末尾に設定される。 ファイルオフセットの調整と書き込み操作はアトミックな"
14741 "処理として 実行される。"
14742
14743 #. type: Plain text
14744 #: build/C/man2/write.2:89
14745 msgid ""
14746 "POSIX requires that a B<read>(2)  which can be proved to occur after a "
14747 "B<write>()  has returned returns the new data.  Note that not all file "
14748 "systems are POSIX conforming."
14749 msgstr ""
14750 "POSIX は B<write>()  が行なわれた後に実行した B<read>(2)  が 新しいデータを返"
14751 "すことを要求している。 全てのファイルシステムが POSIX 準拠ではない点に注意す"
14752 "ること。"
14753
14754 #. type: Plain text
14755 #: build/C/man2/write.2:94
14756 msgid ""
14757 "On success, the number of bytes written is returned (zero indicates nothing "
14758 "was written).  On error, -1 is returned, and I<errno> is set appropriately."
14759 msgstr ""
14760 "成功した場合、書き込まれたバイト数が返される (ゼロは何も書き込まれなかったこ"
14761 "とを示す)。 エラーならば -1 が返され、I<errno> が適切に設定される。"
14762
14763 #. type: Plain text
14764 #: build/C/man2/write.2:107
14765 msgid ""
14766 "If I<count> is zero and I<fd> refers to a regular file, then B<write>()  may "
14767 "return a failure status if one of the errors below is detected.  If no "
14768 "errors are detected, 0 will be returned without causing any other effect.  "
14769 "If I<count> is zero and I<fd> refers to a file other than a regular file, "
14770 "the results are not specified."
14771 msgstr ""
14772 "I<count> が 0 で、 I<fd> が通常のファイル (regular file) を参照している場"
14773 "合、 B<write>()  は後述のエラーのいずれかを検出した場合、失敗を返すことがあ"
14774 "る。 エラーが検出されなかった場合は、 0 を返し、他に何の影響も与えない。 "
14775 "I<count> が 0 で、 I<fd> が通常のファイル以外のファイルを参照している場合、 "
14776 "その結果は規定されていない。"
14777
14778 #. type: Plain text
14779 #: build/C/man2/write.2:115
14780 msgid ""
14781 "The file descriptor I<fd> refers to a file other than a socket and has been "
14782 "marked nonblocking (B<O_NONBLOCK>), and the write would block."
14783 msgstr ""
14784 "ファイルディスクリプタ I<fd> がソケット以外のファイルを参照していて、 非停止 "
14785 "(nonblocking) モード (B<O_NONBLOCK>)  に設定されており、書き込みを行うと停止"
14786 "する状況にある。"
14787
14788 #.  Actually EAGAIN on Linux
14789 #. type: Plain text
14790 #: build/C/man2/write.2:126
14791 msgid ""
14792 "The file descriptor I<fd> refers to a socket and has been marked nonblocking "
14793 "(B<O_NONBLOCK>), and the write would block.  POSIX.1-2001 allows either "
14794 "error to be returned for this case, and does not require these constants to "
14795 "have the same value, so a portable application should check for both "
14796 "possibilities."
14797 msgstr ""
14798 "ファイルディスクリプタ I<fd> がソケットを参照していて、非停止 (nonblocking) "
14799 "モード (B<O_NONBLOCK>)  に設定されており、書き込みを行うと停止する状況にあ"
14800 "る。 POSIX.1-2001 は、この場合にどちらのエラーを返すことも認めており、 これ"
14801 "ら 2 つの定数が同じ値を持つことも求めていない。 したがって、移植性が必要なア"
14802 "プリケーションでは、両方の可能性を 確認すべきである。"
14803
14804 #. type: Plain text
14805 #: build/C/man2/write.2:130
14806 msgid "I<fd> is not a valid file descriptor or is not open for writing."
14807 msgstr ""
14808 "I<fd> が有効なファイルディスクリプタでないか書き込みのためにオープン (open) "
14809 "されていない。"
14810
14811 #. type: TP
14812 #: build/C/man2/write.2:130
14813 #, no-wrap
14814 msgid "B<EDESTADDRREQ>"
14815 msgstr "B<EDESTADDRREQ>"
14816
14817 #. type: Plain text
14818 #: build/C/man2/write.2:135
14819 msgid ""
14820 "I<fd> refers to a datagram socket for which a peer address has not been set "
14821 "using B<connect>(2)."
14822 msgstr ""
14823 "I<fd> が、 B<connect>(2)  を使って通信相手のアドレスが設定されていないデータ"
14824 "グラムソケットを 参照している。"
14825
14826 #. type: Plain text
14827 #: build/C/man2/write.2:141
14828 msgid ""
14829 "The user's quota of disk blocks on the file system containing the file "
14830 "referred to by I<fd> has been exhausted."
14831 msgstr ""
14832 "I<fd> が参照するファイルを含むファイルシステムのディスクブロックのユーザ"
14833 "クォータの上限に達している。"
14834
14835 #. type: Plain text
14836 #: build/C/man2/write.2:150
14837 msgid ""
14838 "An attempt was made to write a file that exceeds the implementation-defined "
14839 "maximum file size or the process's file size limit, or to write at a "
14840 "position past the maximum allowed offset."
14841 msgstr ""
14842 "実装定義の最大ファイルサイズまたはプロセスのファイルサイズ制限を 超えてファイ"
14843 "ルに書き込もうとした。 または許可されたオフセット値の限界を超えた先の位置に "
14844 "書き込もうとした。"
14845
14846 #. type: Plain text
14847 #: build/C/man2/write.2:154
14848 msgid ""
14849 "The call was interrupted by a signal before any data was written; see "
14850 "B<signal>(7)."
14851 msgstr ""
14852 "何のデータも書かない間にシグナルにより割り込まれた (interrupt)。 B<signal>"
14853 "(7)  参照。"
14854
14855 #. type: Plain text
14856 #: build/C/man2/write.2:165
14857 msgid ""
14858 "I<fd> is attached to an object which is unsuitable for writing; or the file "
14859 "was opened with the B<O_DIRECT> flag, and either the address specified in "
14860 "I<buf>, the value specified in I<count>, or the current file offset is not "
14861 "suitably aligned."
14862 msgstr ""
14863 "I<fd> が書き込みが不適切なオブジェクトを参照している。 もしくは、ファイルが "
14864 "B<O_DIRECT> フラグを指定してオープンされているが、 I<buf> に指定されたアドレ"
14865 "ス、 I<count> に指定された値、 現在のファイルオフセットのいずれかの アライン"
14866 "メントが不適切である。"
14867
14868 #. type: Plain text
14869 #: build/C/man2/write.2:168
14870 msgid "A low-level I/O error occurred while modifying the inode."
14871 msgstr "inode の修正中に低レべル (low-level) I/O エラーが発生した。"
14872
14873 #. type: Plain text
14874 #: build/C/man2/write.2:173
14875 msgid ""
14876 "The device containing the file referred to by I<fd> has no room for the data."
14877 msgstr ""
14878 "I<fd> によって参照されるファイルを含むデバイス (device) に十分な空きがない。"
14879
14880 #. type: TP
14881 #: build/C/man2/write.2:173
14882 #, no-wrap
14883 msgid "B<EPIPE>"
14884 msgstr "B<EPIPE>"
14885
14886 #. type: Plain text
14887 #: build/C/man2/write.2:182
14888 msgid ""
14889 "I<fd> is connected to a pipe or socket whose reading end is closed.  When "
14890 "this happens the writing process will also receive a B<SIGPIPE> signal.  "
14891 "(Thus, the write return value is seen only if the program catches, blocks or "
14892 "ignores this signal.)"
14893 msgstr ""
14894 "I<fd> がパイプ (pipe) かソケット (socket) に接続されており、 その反対側 (読み"
14895 "込み側) がクローズ (close) されている。 これが発生した場合には、書き込みを行"
14896 "なうプロセスは B<SIGPIPE> シグナル (signal)も受ける。 (したがって、プログラム"
14897 "がこのシグナルを捕獲 (catch)、停止 (block)、無視 (ignore)  した場合のみ、"
14898 "write の返り値を参照できる。)"
14899
14900 #. type: Plain text
14901 #: build/C/man2/write.2:185
14902 msgid "Other errors may occur, depending on the object connected to I<fd>."
14903 msgstr ""
14904 "I<fd> に接続されたオブジェクトによっては、他のエラーが起こるかもしれない。"
14905
14906 #. type: Plain text
14907 #: build/C/man2/write.2:194
14908 msgid ""
14909 "Under SVr4 a write may be interrupted and return B<EINTR> at any point, not "
14910 "just before any data is written."
14911 msgstr ""
14912 "SVr4 では write が割り込まれると、データが書き込まれる直前ではなく、 その時点"
14913 "で B<EINTR> が返る。"
14914
14915 #. type: Plain text
14916 #: build/C/man2/write.2:203
14917 msgid ""
14918 "A successful return from B<write>()  does not make any guarantee that data "
14919 "has been committed to disk.  In fact, on some buggy implementations, it does "
14920 "not even guarantee that space has successfully been reserved for the data.  "
14921 "The only way to be sure is to call B<fsync>(2)  after you are done writing "
14922 "all your data."
14923 msgstr ""
14924 "B<write>()  が成功して返ってきても、データがディスクに記録されたことを 保証す"
14925 "るものではない。 実際、データのためのスペースが確保されたことすら保証されない"
14926 "という バグっぽい実装もある。 これを確実にする唯一の方法は、 全てのデータを "
14927 "write した後に B<fsync>(2)  を呼び出すことである。"
14928
14929 #. type: Plain text
14930 #: build/C/man2/write.2:211
14931 msgid ""
14932 "If a B<write>()  is interrupted by a signal handler before any bytes are "
14933 "written, then the call fails with the error B<EINTR>; if it is interrupted "
14934 "after at least one byte has been written, the call succeeds, and returns the "
14935 "number of bytes written."
14936 msgstr ""
14937 "B<write>()  が 1 バイトも書き込まないうちにシグナルハンドラにより割り込まれた"
14938 "場合、 B<write>()  はエラー B<EINTR> で失敗する。 1バイトでも書き込んだ後で割"
14939 "り込まれた場合には、 B<write>()  は成功し、書き込んだバイト数を返す。"
14940
14941 #. type: Plain text
14942 #: build/C/man2/write.2:223
14943 msgid ""
14944 "B<close>(2), B<fcntl>(2), B<fsync>(2), B<ioctl>(2), B<lseek>(2), B<open>(2), "
14945 "B<pwrite>(2), B<read>(2), B<select>(2), B<writev>(2), B<fwrite>(3)"
14946 msgstr ""
14947 "B<close>(2), B<fcntl>(2), B<fsync>(2), B<ioctl>(2), B<lseek>(2), B<open>(2), "
14948 "B<pwrite>(2), B<read>(2), B<select>(2), B<writev>(2), B<fwrite>(3)"
14949
14950 #~ msgid "2001-12-18"
14951 #~ msgstr "2001-12-18"
14952
14953 #~ msgid "2007-07-26"
14954 #~ msgstr "2007-07-26"
14955
14956 #~ msgid "2006-12-27"
14957 #~ msgstr "2006-12-27"
14958
14959 #~ msgid "1999-07-25"
14960 #~ msgstr "1999-07-25"
14961
14962 #~ msgid "2008-06-14"
14963 #~ msgstr "2008-06-14"
14964
14965 #~ msgid "2010-06-12"
14966 #~ msgstr "2010-06-12"
14967
14968 #~ msgid "2010-02-03"
14969 #~ msgstr "2010-02-03"
14970
14971 #~ msgid "2001-12-16"
14972 #~ msgstr "2001-12-16"
14973
14974 #~ msgid "2008-08-06"
14975 #~ msgstr "2008-08-06"
14976
14977 #~ msgid "2010-09-10"
14978 #~ msgstr "2010-09-10"
14979
14980 #~ msgid ""
14981 #~ "Many file systems and disks were considered to be fast enough that the "
14982 #~ "implementation of B<O_NONBLOCK> was deemed unnecessary.  So, "
14983 #~ "B<O_NONBLOCK> may not be available on files and/or disks."
14984 #~ msgstr ""
14985 #~ "多くのファイルシステムやディスクは B<O_NONBLOCK> の実装はしなくても済むく"
14986 #~ "らいに十分に高速であると考えられている。 それでそのようなファイルやディス"
14987 #~ "クには B<O_NONBLOCK> は利用できないかもしれない。"
14988
14989 #~ msgid ""
14990 #~ "The I<local_iov> and I<remote_iov> arguments point to an array of "
14991 #~ "I<iovec> structures, defined in I<E<lt>sys/uio.hE<gt>> as:"
14992 #~ msgstr ""
14993 #~ "引き数 I<local_iov> と I<remote_iov> は I<iovec> 構造体の配列へのポイン\n"
14994 #~ "タである。 I<iovec> 構造体は I<E<lt>sys/uio.hE<gt>> で以下のように定義\n"
14995 #~ "されている:"
14996
14997 #~ msgid ""
14998 #~ "Buffers are processed in array order.  This means that B<process_vm_readv>"
14999 #~ "()  completely fills I<local_iov[0]> before proceeding to I<local_iov[1]"
15000 #~ ">, and so on.  Likewise, I<remote_iov[0]> is completely read before "
15001 #~ "proceeding to I<remote_iov[1]>, and so on."
15002 #~ msgstr ""
15003 #~ "バッファは配列の順序で処理される。これは、 B<process_vm_readv>() が\n"
15004 #~ "I<local_iov>[0] が完全に一杯になるまでデータを詰めてから、\n"
15005 #~ "I<local_iov>[1] に進むといったことを意味する。同様に、\n"
15006 #~ "I<remote_iov>[0] を完全に読み出してから I<remote_iov>[1] に進み、\n"
15007 #~ "以降も同様である。"