OSDN Git Service

157ed8e9b23754638f56b2b6883d6076248b76bd
[linuxjm/LDP_man-pages.git] / po4a / dirent / 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-08-15 19:31+0900\n"
10 "PO-Revision-Date: 2013-08-15 20:08+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/closedir.3:31
20 #, no-wrap
21 msgid "CLOSEDIR"
22 msgstr "CLOSEDIR"
23
24 #. type: TH
25 #: build/C/man3/closedir.3:31
26 #, no-wrap
27 msgid "2008-09-23"
28 msgstr "2008-09-23"
29
30 #. type: TH
31 #: build/C/man3/closedir.3:31 build/C/man3/dirfd.3:25
32 #: build/C/man2/getdents.2:30 build/C/man3/getdirentries.3:27
33 #: build/C/man3/opendir.3:32 build/C/man2/readdir.2:30
34 #: build/C/man3/readdir.3:36 build/C/man3/rewinddir.3:31
35 #: build/C/man3/scandir.3:36 build/C/man3/scandirat.3:25
36 #: build/C/man3/seekdir.3:31 build/C/man3/telldir.3:30
37 #, no-wrap
38 msgid "Linux Programmer's Manual"
39 msgstr "Linux Programmer's Manual"
40
41 #. type: SH
42 #: build/C/man3/closedir.3:32 build/C/man3/dirfd.3:26
43 #: build/C/man2/getdents.2:31 build/C/man3/getdirentries.3:28
44 #: build/C/man3/opendir.3:33 build/C/man2/readdir.2:31
45 #: build/C/man3/readdir.3:37 build/C/man3/rewinddir.3:32
46 #: build/C/man3/scandir.3:37 build/C/man3/scandirat.3:26
47 #: build/C/man3/seekdir.3:32 build/C/man3/telldir.3:31
48 #, no-wrap
49 msgid "NAME"
50 msgstr "名前"
51
52 #. type: Plain text
53 #: build/C/man3/closedir.3:34
54 msgid "closedir - close a directory"
55 msgstr "closedir - ディレクトリをクローズする"
56
57 #. type: SH
58 #: build/C/man3/closedir.3:34 build/C/man3/dirfd.3:28
59 #: build/C/man2/getdents.2:33 build/C/man3/getdirentries.3:30
60 #: build/C/man3/opendir.3:35 build/C/man2/readdir.2:33
61 #: build/C/man3/readdir.3:39 build/C/man3/rewinddir.3:34
62 #: build/C/man3/scandir.3:39 build/C/man3/scandirat.3:28
63 #: build/C/man3/seekdir.3:35 build/C/man3/telldir.3:33
64 #, no-wrap
65 msgid "SYNOPSIS"
66 msgstr "書式"
67
68 #. type: Plain text
69 #: build/C/man3/closedir.3:37 build/C/man3/opendir.3:38
70 #: build/C/man3/rewinddir.3:37
71 #, no-wrap
72 msgid "B<#include E<lt>sys/types.hE<gt>>\n"
73 msgstr "B<#include E<lt>sys/types.hE<gt>>\n"
74
75 #. type: Plain text
76 #: build/C/man3/closedir.3:39 build/C/man3/opendir.3:40
77 #: build/C/man3/readdir.3:42 build/C/man3/rewinddir.3:39
78 #: build/C/man3/scandir.3:42 build/C/man3/seekdir.3:38
79 #: build/C/man3/telldir.3:36
80 #, no-wrap
81 msgid "B<#include E<lt>dirent.hE<gt>>\n"
82 msgstr "B<#include E<lt>dirent.hE<gt>>\n"
83
84 #. type: Plain text
85 #: build/C/man3/closedir.3:41
86 #, no-wrap
87 msgid "B<int closedir(DIR *>I<dirp>B<);>\n"
88 msgstr "B<int closedir(DIR *>I<dirp>B<);>\n"
89
90 #. type: SH
91 #: build/C/man3/closedir.3:42 build/C/man3/dirfd.3:54
92 #: build/C/man2/getdents.2:41 build/C/man3/getdirentries.3:43
93 #: build/C/man3/opendir.3:63 build/C/man2/readdir.2:42
94 #: build/C/man3/readdir.3:61 build/C/man3/rewinddir.3:42
95 #: build/C/man3/scandir.3:65 build/C/man3/scandirat.3:44
96 #: build/C/man3/seekdir.3:49 build/C/man3/telldir.3:47
97 #, no-wrap
98 msgid "DESCRIPTION"
99 msgstr "説明"
100
101 #. type: Plain text
102 #: build/C/man3/closedir.3:55
103 msgid ""
104 "The B<closedir>()  function closes the directory stream associated with "
105 "I<dirp>.  A successful call to B<closedir>()  also closes the underlying "
106 "file descriptor associated with I<dirp>.  The directory stream descriptor "
107 "I<dirp> is not available after this call."
108 msgstr ""
109 "B<closedir>()  関数は I<dirp> に関連付けられた ディレクトリストリームをクロー"
110 "ズする。\n"
111 "B<closedir>()  の呼び出しが成功すると、 I<dirp> に関連付けられた\n"
112 "ファイルディスクリプタもクローズされる。\n"
113 "ディレクトリストリームディスクリプタ (directory stream descriptor) I<dirp> "
114 "は、\n"
115 "この呼び出しの後では使用することができない。"
116
117 #. type: SH
118 #: build/C/man3/closedir.3:55 build/C/man3/dirfd.3:69
119 #: build/C/man2/getdents.2:142 build/C/man3/getdirentries.3:56
120 #: build/C/man3/opendir.3:83 build/C/man2/readdir.2:91
121 #: build/C/man3/readdir.3:119 build/C/man3/rewinddir.3:49
122 #: build/C/man3/scandir.3:92 build/C/man3/scandirat.3:78
123 #: build/C/man3/seekdir.3:60 build/C/man3/telldir.3:52
124 #, no-wrap
125 msgid "RETURN VALUE"
126 msgstr "返り値"
127
128 #. type: Plain text
129 #: build/C/man3/closedir.3:62
130 msgid ""
131 "The B<closedir>()  function returns 0 on success.  On error, -1 is returned, "
132 "and I<errno> is set appropriately."
133 msgstr ""
134 "B<closedir>()  関数は成功時に 0 を返す。 エラーの場合は、-1 が返されて、 "
135 "I<errno> が適切に設定される。"
136
137 #. type: SH
138 #: build/C/man3/closedir.3:62 build/C/man3/dirfd.3:74
139 #: build/C/man2/getdents.2:148 build/C/man3/getdirentries.3:62
140 #: build/C/man3/opendir.3:92 build/C/man2/readdir.2:97
141 #: build/C/man3/readdir.3:143 build/C/man3/scandir.3:108
142 #: build/C/man3/scandirat.3:85 build/C/man3/telldir.3:60
143 #, no-wrap
144 msgid "ERRORS"
145 msgstr "エラー"
146
147 #. type: TP
148 #: build/C/man3/closedir.3:63 build/C/man2/getdents.2:149
149 #: build/C/man3/opendir.3:96 build/C/man2/readdir.2:98
150 #: build/C/man3/readdir.3:144 build/C/man3/scandirat.3:92
151 #: build/C/man3/telldir.3:61
152 #, no-wrap
153 msgid "B<EBADF>"
154 msgstr "B<EBADF>"
155
156 #. type: Plain text
157 #: build/C/man3/closedir.3:67 build/C/man3/readdir.3:147
158 #: build/C/man3/telldir.3:64
159 msgid "Invalid directory stream descriptor I<dirp>."
160 msgstr "ディレクトリストリームディスクリプタ I<dirp> が無効である。"
161
162 #. type: SH
163 #: build/C/man3/closedir.3:67 build/C/man3/dirfd.3:92
164 #: build/C/man2/getdents.2:165 build/C/man3/getdirentries.3:64
165 #: build/C/man3/opendir.3:118 build/C/man2/readdir.2:114
166 #: build/C/man3/readdir.3:156 build/C/man3/rewinddir.3:53
167 #: build/C/man3/scandir.3:121 build/C/man3/scandirat.3:105
168 #: build/C/man3/seekdir.3:64 build/C/man3/telldir.3:64
169 #, no-wrap
170 msgid "CONFORMING TO"
171 msgstr "準拠"
172
173 #. type: Plain text
174 #: build/C/man3/closedir.3:69
175 msgid "SVr4, POSIX.1-2001, 4.3BSD."
176 msgstr "SVr4, POSIX.1-2001, 4.3BSD."
177
178 #. type: SH
179 #: build/C/man3/closedir.3:69 build/C/man3/dirfd.3:104
180 #: build/C/man2/getdents.2:282 build/C/man3/getdirentries.3:72
181 #: build/C/man3/opendir.3:140 build/C/man2/readdir.2:127
182 #: build/C/man3/readdir.3:265 build/C/man3/rewinddir.3:55
183 #: build/C/man3/scandir.3:177 build/C/man3/scandirat.3:112
184 #: build/C/man3/seekdir.3:78 build/C/man3/telldir.3:90
185 #, no-wrap
186 msgid "SEE ALSO"
187 msgstr "関連項目"
188
189 #. type: Plain text
190 #: build/C/man3/closedir.3:77
191 msgid ""
192 "B<close>(2), B<opendir>(3), B<readdir>(3), B<rewinddir>(3), B<scandir>(3), "
193 "B<seekdir>(3), B<telldir>(3)"
194 msgstr ""
195 "B<close>(2), B<opendir>(3), B<readdir>(3), B<rewinddir>(3), B<scandir>(3), "
196 "B<seekdir>(3), B<telldir>(3)"
197
198 #. type: SH
199 #: build/C/man3/closedir.3:77 build/C/man3/dirfd.3:113
200 #: build/C/man2/getdents.2:285 build/C/man3/getdirentries.3:75
201 #: build/C/man3/opendir.3:149 build/C/man2/readdir.2:130
202 #: build/C/man3/readdir.3:277 build/C/man3/rewinddir.3:62
203 #: build/C/man3/scandir.3:189 build/C/man3/scandirat.3:116
204 #: build/C/man3/seekdir.3:86 build/C/man3/telldir.3:97
205 #, no-wrap
206 msgid "COLOPHON"
207 msgstr "この文書について"
208
209 #. type: Plain text
210 #: build/C/man3/closedir.3:84 build/C/man3/dirfd.3:120
211 #: build/C/man2/getdents.2:292 build/C/man3/getdirentries.3:82
212 #: build/C/man3/opendir.3:156 build/C/man2/readdir.2:137
213 #: build/C/man3/readdir.3:284 build/C/man3/rewinddir.3:69
214 #: build/C/man3/scandir.3:196 build/C/man3/scandirat.3:123
215 #: build/C/man3/seekdir.3:93 build/C/man3/telldir.3:104
216 msgid ""
217 "This page is part of release 3.53 of the Linux I<man-pages> project.  A "
218 "description of the project, and information about reporting bugs, can be "
219 "found at \\%http://www.kernel.org/doc/man-pages/."
220 msgstr ""
221 "この man ページは Linux I<man-pages> プロジェクトのリリース 3.53 の一部\n"
222 "である。プロジェクトの説明とバグ報告に関する情報は\n"
223 "http://www.kernel.org/doc/man-pages/ に書かれている。"
224
225 #. type: TH
226 #: build/C/man3/dirfd.3:25
227 #, no-wrap
228 msgid "DIRFD"
229 msgstr "DIRFD"
230
231 #. type: TH
232 #: build/C/man3/dirfd.3:25
233 #, fuzzy, no-wrap
234 #| msgid "2013-04-19"
235 msgid "2013-07-05"
236 msgstr "2013-04-19"
237
238 #. type: TH
239 #: build/C/man3/dirfd.3:25 build/C/man2/getdents.2:30
240 #: build/C/man2/readdir.2:30 build/C/man3/scandirat.3:25
241 #, no-wrap
242 msgid "Linux"
243 msgstr "Linux"
244
245 #. type: Plain text
246 #: build/C/man3/dirfd.3:28
247 msgid "dirfd - get directory stream file descriptor"
248 msgstr "dirfd - ディレクトリストリームのファイルディスクリプタを取得する"
249
250 #. type: Plain text
251 #: build/C/man3/dirfd.3:30
252 msgid "B<#include E<lt>sys/types.hE<gt>>"
253 msgstr "B<#include E<lt>sys/types.hE<gt>>"
254
255 #. type: Plain text
256 #: build/C/man3/dirfd.3:32 build/C/man3/getdirentries.3:32
257 msgid "B<#include E<lt>dirent.hE<gt>>"
258 msgstr "B<#include E<lt>dirent.hE<gt>>"
259
260 #. type: Plain text
261 #: build/C/man3/dirfd.3:34
262 msgid "B<int dirfd(DIR *>I<dirp>B<);>"
263 msgstr "B<int dirfd(DIR *>I<dirp>B<);>"
264
265 #. type: Plain text
266 #: build/C/man3/dirfd.3:38 build/C/man3/getdirentries.3:39
267 #: build/C/man3/opendir.3:48 build/C/man3/readdir.3:52
268 #: build/C/man3/scandir.3:57 build/C/man3/seekdir.3:45
269 #: build/C/man3/telldir.3:43
270 msgid ""
271 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
272 msgstr "glibc 向けの機能検査マクロの要件 (B<feature_test_macros>(7)  参照):"
273
274 #. type: Plain text
275 #: build/C/man3/dirfd.3:41
276 msgid "B<dirfd>():"
277 msgstr "B<dirfd>():"
278
279 #. type: Plain text
280 #: build/C/man3/dirfd.3:46
281 msgid "_BSD_SOURCE || _SVID_SOURCE"
282 msgstr "_BSD_SOURCE || _SVID_SOURCE"
283
284 #. type: Plain text
285 #: build/C/man3/dirfd.3:48
286 msgid "|| /* Since glibc 2.10: */"
287 msgstr "|| /* glibc 2.10 以降: */"
288
289 #. type: Plain text
290 #: build/C/man3/dirfd.3:50
291 msgid "(_POSIX_C_SOURCE\\ E<gt>=\\ 200809L || _XOPEN_SOURCE\\ E<gt>=\\ 700)"
292 msgstr "(_POSIX_C_SOURCE\\ E<gt>=\\ 200809L || _XOPEN_SOURCE\\ E<gt>=\\ 700)"
293
294 #. type: Plain text
295 #: build/C/man3/dirfd.3:59
296 msgid ""
297 "The function B<dirfd>()  returns the file descriptor associated with the "
298 "directory stream I<dirp>."
299 msgstr ""
300 "関数 B<dirfd>()  はディレクトリストリーム I<dirp> に関連づけられたファイル"
301 "ディスクリプタを返す。"
302
303 #. type: Plain text
304 #: build/C/man3/dirfd.3:69
305 msgid ""
306 "This descriptor is the one used internally by the directory stream.  As a "
307 "result, it is useful only for functions which do not depend on or alter the "
308 "file position, such as B<fstat>(2)  and B<fchdir>(2).  It will be "
309 "automatically closed when B<closedir>(3)  is called."
310 msgstr ""
311 "このディスクリプタはディレクトリストリームが内部で使用するものである。 よっ"
312 "て、ファイルの位置に依存せず、かつその位置を変更しない関数 B<fstat>(2)  や "
313 "B<fchdir>(2)  などでしか役に立たない。 このディスクリプタは B<closedir>(3)  "
314 "が呼ばれたときに自動的にクローズされる。"
315
316 #. type: Plain text
317 #: build/C/man3/dirfd.3:74
318 msgid ""
319 "On success, a nonnegative file descriptor is returned.  On error, -1 is "
320 "returned, and I<errno> is set to indicate the cause of the error."
321 msgstr ""
322 "成功すると、負でない値のファイルディスクリプタが返される。 エラーの場合は -1 "
323 "が返され、 I<errno> にエラーの原因を示す値が設定される。"
324
325 #.  glibc 2.8
326 #. type: Plain text
327 #: build/C/man3/dirfd.3:79
328 msgid ""
329 "POSIX.1-2008 specifies two errors, neither of which is returned by the "
330 "current implementation."
331 msgstr ""
332 "POSIX.1-2008 では 2 つのエラーが規定されている。 現在の実装ではどちらのエラー"
333 "も返されない。"
334
335 #. type: TP
336 #: build/C/man3/dirfd.3:79 build/C/man2/getdents.2:156
337 #: build/C/man2/readdir.2:105
338 #, no-wrap
339 msgid "B<EINVAL>"
340 msgstr "B<EINVAL>"
341
342 #. type: Plain text
343 #: build/C/man3/dirfd.3:83
344 msgid "I<dirp> does not refer to a valid directory stream."
345 msgstr "I<dirp> が有効なディレクトリストリームを参照していない。"
346
347 #. type: TP
348 #: build/C/man3/dirfd.3:83
349 #, no-wrap
350 msgid "B<ENOTSUP>"
351 msgstr "B<ENOTSUP>"
352
353 #. type: Plain text
354 #: build/C/man3/dirfd.3:87
355 msgid ""
356 "The implementation does not support the association of a file descriptor "
357 "with a directory."
358 msgstr ""
359 "この実装では、ファイルディスクリプタのディレクトリとの関連付けが サポートされ"
360 "ていない。"
361
362 #. type: SH
363 #: build/C/man3/dirfd.3:87 build/C/man3/readdir.3:147
364 #, no-wrap
365 msgid "ATTRIBUTES"
366 msgstr "属性"
367
368 #. type: SS
369 #: build/C/man3/dirfd.3:88 build/C/man3/readdir.3:148
370 #, no-wrap
371 msgid "Multithreading (see pthreads(7))"
372 msgstr "マルチスレッディング (pthreads(7) 参照)"
373
374 #. type: Plain text
375 #: build/C/man3/dirfd.3:92
376 #, fuzzy
377 #| msgid "The B<readdir_r>()  function is thread-safe."
378 msgid "The B<dirfd>()  function is thread-safe."
379 msgstr "B<readdir_r>() 関数はスレッドセーフである。"
380
381 #.  It is present in libc5 (since 5.1.2) and in glibc2.
382 #. type: Plain text
383 #: build/C/man3/dirfd.3:96
384 msgid ""
385 "POSIX.1-2008.  This function was a BSD extension, present in 4.3BSD-Reno, "
386 "not in 4.2BSD."
387 msgstr ""
388 "POSIX.1-2008.  この関数は BSD 拡張であった。 4.3BSD-Reno には存在するが、"
389 "4.2BSD には存在しない。"
390
391 #. type: SH
392 #: build/C/man3/dirfd.3:96 build/C/man2/getdents.2:168
393 #: build/C/man3/opendir.3:123 build/C/man2/readdir.2:116
394 #: build/C/man3/readdir.3:158 build/C/man3/scandirat.3:107
395 #: build/C/man3/seekdir.3:66 build/C/man3/telldir.3:66
396 #, no-wrap
397 msgid "NOTES"
398 msgstr "注意"
399
400 #. type: Plain text
401 #: build/C/man3/dirfd.3:104
402 msgid ""
403 "The prototype for B<dirfd>()  is available only if B<_BSD_SOURCE> or "
404 "B<_SVID_SOURCE> is defined."
405 msgstr ""
406 "B<dirfd>()  のプロトタイプが使用可能なのは、 B<_BSD_SOURCE> または "
407 "B<_SVID_SOURCE> が定義されたときのみである。"
408
409 #. type: Plain text
410 #: build/C/man3/dirfd.3:113
411 msgid ""
412 "B<open>(2), B<closedir>(3), B<opendir>(3), B<readdir>(3), B<rewinddir>(3), "
413 "B<scandir>(3), B<seekdir>(3), B<telldir>(3)"
414 msgstr ""
415 "B<open>(2), B<closedir>(3), B<opendir>(3), B<readdir>(3), B<rewinddir>(3), "
416 "B<scandir>(3), B<seekdir>(3), B<telldir>(3)"
417
418 #. type: TH
419 #: build/C/man2/getdents.2:30
420 #, no-wrap
421 msgid "GETDENTS"
422 msgstr "GETDENTS"
423
424 #. type: TH
425 #: build/C/man2/getdents.2:30
426 #, no-wrap
427 msgid "2012-08-03"
428 msgstr "2012-08-03"
429
430 #. type: Plain text
431 #: build/C/man2/getdents.2:33
432 msgid "getdents - get directory entries"
433 msgstr "getdents - ディレクトリ・エントリを取得する"
434
435 #. type: Plain text
436 #: build/C/man2/getdents.2:37
437 #, no-wrap
438 msgid ""
439 "B<int getdents(unsigned int >I<fd>B<, struct linux_dirent *>I<dirp>B<,>\n"
440 "B<             unsigned int >I<count>B<);>\n"
441 msgstr ""
442 "B<int getdents(unsigned int >I<fd>B<, struct linux_dirent *>I<dirp>B<,>\n"
443 "B<             unsigned int >I<count>B<);>\n"
444
445 #. type: Plain text
446 #: build/C/man2/getdents.2:41 build/C/man2/readdir.2:42
447 msgid "I<Note>: There is no glibc wrapper for this system call; see NOTES."
448 msgstr ""
449 "I<注>: このシステムコールには glibc のラッパー関数は存在しない。「注意」の節"
450 "を参照。"
451
452 #. type: Plain text
453 #: build/C/man2/getdents.2:47
454 msgid ""
455 "This is not the function you are interested in.  Look at B<readdir>(3)  for "
456 "the POSIX conforming C library interface.  This page documents the bare "
457 "kernel system call interface."
458 msgstr ""
459 "これはあなたの関心を引くような関数ではない。 POSIX 準拠の C ライブラリイン"
460 "ターフェースについては B<readdir>(3)  を見ること。 このページは、カーネルシス"
461 "テムコールの生のインターフェースについて 記載したものである。"
462
463 #. type: Plain text
464 #: build/C/man2/getdents.2:60
465 msgid ""
466 "The system call B<getdents>()  reads several I<linux_dirent> structures from "
467 "the directory referred to by the open file descriptor I<fd> into the buffer "
468 "pointed to by I<dirp>.  The argument I<count> specifies the size of that "
469 "buffer."
470 msgstr ""
471 "B<getdents>()  システムコールは、オープン済みのファイルディスクリプタ I<fd> "
472 "で参照されるディレクトリから I<linux_dirent> 構造体をいくつか読み出し、 "
473 "I<dirp> が指しているバッファに格納する。 I<count> 引き数はそのバッファのサイ"
474 "ズを示す。"
475
476 #. type: Plain text
477 #: build/C/man2/getdents.2:64
478 msgid "The I<linux_dirent> structure is declared as follows:"
479 msgstr "I<linux_dirent> 構造体は以下のように宣言されている:"
480
481 #. type: Plain text
482 #: build/C/man2/getdents.2:79
483 #, no-wrap
484 msgid ""
485 "struct linux_dirent {\n"
486 "    unsigned long  d_ino;     /* Inode number */\n"
487 "    unsigned long  d_off;     /* Offset to next I<linux_dirent> */\n"
488 "    unsigned short d_reclen;  /* Length of this I<linux_dirent> */\n"
489 "    char           d_name[];  /* Filename (null-terminated) */\n"
490 "                      /* length is actually (d_reclen - 2 -\n"
491 "                         offsetof(struct linux_dirent, d_name)) */\n"
492 "    /*\n"
493 "    char           pad;       // Zero padding byte\n"
494 "    char           d_type;    // File type (only since Linux\n"
495 "                              // 2.6.4); offset is (d_reclen - 1)\n"
496 "    */\n"
497 msgstr ""
498 "struct linux_dirent {\n"
499 "    unsigned long  d_ino;     /* Inode number */\n"
500 "    unsigned long  d_off;     /* Offset to next I<linux_dirent> */\n"
501 "    unsigned short d_reclen;  /* Length of this I<linux_dirent> */\n"
502 "    char           d_name[];  /* Filename (null-terminated) */\n"
503 "                      /* length is actually (d_reclen - 2 -\n"
504 "                         offsetof(struct linux_dirent, d_name)) */\n"
505 "    /*\n"
506 "    char           pad;       // Zero padding byte\n"
507 "    char           d_type;    // File type (only since Linux\n"
508 "                              // 2.6.4); offset is (d_reclen - 1)\n"
509 "    */\n"
510
511 #. type: Plain text
512 #: build/C/man2/getdents.2:81
513 #, no-wrap
514 msgid "}\n"
515 msgstr "}\n"
516
517 #. type: Plain text
518 #: build/C/man2/getdents.2:94
519 msgid ""
520 "I<d_ino> is an inode number.  I<d_off> is the distance from the start of the "
521 "directory to the start of the next I<linux_dirent>.  I<d_reclen> is the size "
522 "of this entire I<linux_dirent>.  I<d_name> is a null-terminated filename."
523 msgstr ""
524 "I<d_ino> は inode 番号である。 I<d_off> はディレクトリの先頭から次の "
525 "I<linux_dirent> の先頭までの距離である。 I<d_reclen> はこの I<linux_dirent> "
526 "全体のサイズである。 I<d_name> はヌル(null)文字で終わるファイル名である。"
527
528 #. type: Plain text
529 #: build/C/man2/getdents.2:99
530 msgid ""
531 "I<d_type> is a byte at the end of the structure that indicates the file "
532 "type.  It contains one of the following values (defined in I<E<lt>dirent."
533 "hE<gt>>):"
534 msgstr ""
535 "I<d_type> は、構造体の最後のバイトであり、ファイルタイプを示す。 I<d_type> は"
536 "以下の値の一つを取る (I<E<lt>dirent.hE<gt>> で定義されている)。"
537
538 #. type: TP
539 #: build/C/man2/getdents.2:99 build/C/man3/readdir.3:200
540 #, no-wrap
541 msgid "B<DT_BLK>"
542 msgstr "B<DT_BLK>"
543
544 #. type: Plain text
545 #: build/C/man2/getdents.2:102 build/C/man3/readdir.3:203
546 msgid "This is a block device."
547 msgstr "ブロックデバイスである。"
548
549 #. type: TP
550 #: build/C/man2/getdents.2:102 build/C/man3/readdir.3:203
551 #, no-wrap
552 msgid "B<DT_CHR>"
553 msgstr "B<DT_CHR>"
554
555 #. type: Plain text
556 #: build/C/man2/getdents.2:105 build/C/man3/readdir.3:206
557 msgid "This is a character device."
558 msgstr "キャラクタデバイスである。"
559
560 #. type: TP
561 #: build/C/man2/getdents.2:105 build/C/man3/readdir.3:206
562 #, no-wrap
563 msgid "B<DT_DIR>"
564 msgstr "B<DT_DIR>"
565
566 #. type: Plain text
567 #: build/C/man2/getdents.2:108 build/C/man3/readdir.3:209
568 msgid "This is a directory."
569 msgstr "ディレクトリである。"
570
571 #. type: TP
572 #: build/C/man2/getdents.2:108 build/C/man3/readdir.3:209
573 #, no-wrap
574 msgid "B<DT_FIFO>"
575 msgstr "B<DT_FIFO>"
576
577 #. type: Plain text
578 #: build/C/man2/getdents.2:111 build/C/man3/readdir.3:212
579 msgid "This is a named pipe (FIFO)."
580 msgstr "名前付きパイプ (FIFO) である。"
581
582 #. type: TP
583 #: build/C/man2/getdents.2:111 build/C/man3/readdir.3:212
584 #, no-wrap
585 msgid "B<DT_LNK>"
586 msgstr "B<DT_LNK>"
587
588 #. type: Plain text
589 #: build/C/man2/getdents.2:114 build/C/man3/readdir.3:215
590 msgid "This is a symbolic link."
591 msgstr "シンボリックリンクである。"
592
593 #. type: TP
594 #: build/C/man2/getdents.2:114 build/C/man3/readdir.3:215
595 #, no-wrap
596 msgid "B<DT_REG>"
597 msgstr "B<DT_REG>"
598
599 #. type: Plain text
600 #: build/C/man2/getdents.2:117 build/C/man3/readdir.3:218
601 msgid "This is a regular file."
602 msgstr "通常のファイルである。"
603
604 #. type: TP
605 #: build/C/man2/getdents.2:117 build/C/man3/readdir.3:218
606 #, no-wrap
607 msgid "B<DT_SOCK>"
608 msgstr "B<DT_SOCK>"
609
610 #. type: Plain text
611 #: build/C/man2/getdents.2:120 build/C/man3/readdir.3:221
612 msgid "This is a UNIX domain socket."
613 msgstr "UNIX ドメインソケットである。"
614
615 #. type: TP
616 #: build/C/man2/getdents.2:120 build/C/man3/readdir.3:221
617 #, no-wrap
618 msgid "B<DT_UNKNOWN>"
619 msgstr "B<DT_UNKNOWN>"
620
621 #.  The glibc manual says that on some systems this is the only
622 #.  value returned
623 #. type: Plain text
624 #: build/C/man2/getdents.2:123 build/C/man3/readdir.3:226
625 msgid "The file type is unknown."
626 msgstr "ファイルタイプが不明である。"
627
628 #. type: Plain text
629 #: build/C/man2/getdents.2:133
630 msgid ""
631 "The I<d_type> field is implemented since Linux 2.6.4.  It occupies a space "
632 "that was previously a zero-filled padding byte in the I<linux_dirent> "
633 "structure.  Thus, on kernels before 2.6.3, attempting to access this field "
634 "always provides the value 0 (B<DT_UNKNOWN>)."
635 msgstr ""
636 "I<d_type> フィールドは Linux 2.6.4 から実装されている。 これは "
637 "I<linux_dirent> 構造体のうち、以前はゼロで埋められていた空間に配置されてい"
638 "る。 従って、2.6.3 以前のカーネルでは、このフィールドにアクセスしようとする"
639 "と 常に値 0 (B<DT_UNKNOWN>)  が返される。"
640
641 #.  kernel 2.6.27
642 #.  The same sentence is in getdents.2
643 #. type: Plain text
644 #: build/C/man2/getdents.2:142 build/C/man3/readdir.3:240
645 msgid ""
646 "Currently, only some file systems (among them: Btrfs, ext2, ext3, and ext4)  "
647 "have full support for returning the file type in I<d_type>.  All "
648 "applications must properly handle a return of B<DT_UNKNOWN>."
649 msgstr ""
650 "現在のところ、 I<d_type> でファイルタイプを返す機能が完全にサポートされている"
651 "のは、 いくつかのファイルシステムにおいてのみである (Btrfs, ext2, ext3, ext4 "
652 "はサポートしている)。 どのアプリケーションも、 B<DT_UNKNOWN> が返された際に適"
653 "切に処理できなければならない。"
654
655 #. type: Plain text
656 #: build/C/man2/getdents.2:148
657 msgid ""
658 "On success, the number of bytes read is returned.  On end of directory, 0 is "
659 "returned.  On error, -1 is returned, and I<errno> is set appropriately."
660 msgstr ""
661 "成功した場合は、読み込んだバイト数が返される。 ディレクトリの終わりならば 0 "
662 "が返される。 エラーの場合は -1 を返され、 I<errno> に適切な値が設定される。"
663
664 #. type: Plain text
665 #: build/C/man2/getdents.2:153 build/C/man2/readdir.2:102
666 msgid "Invalid file descriptor I<fd>."
667 msgstr "ファイルディスクリプタ I<fd> が不正である。"
668
669 #. type: TP
670 #: build/C/man2/getdents.2:153 build/C/man2/readdir.2:102
671 #, no-wrap
672 msgid "B<EFAULT>"
673 msgstr "B<EFAULT>"
674
675 #. type: Plain text
676 #: build/C/man2/getdents.2:156 build/C/man2/readdir.2:105
677 msgid "Argument points outside the calling process's address space."
678 msgstr "引き数が呼び出したプロセスのアドレス空間外を指している。"
679
680 #. type: Plain text
681 #: build/C/man2/getdents.2:159 build/C/man2/readdir.2:108
682 msgid "Result buffer is too small."
683 msgstr "結果用のバッファーが小さすぎる。"
684
685 #. type: TP
686 #: build/C/man2/getdents.2:159 build/C/man3/opendir.3:106
687 #: build/C/man2/readdir.2:108 build/C/man3/scandir.3:109
688 #, no-wrap
689 msgid "B<ENOENT>"
690 msgstr "B<ENOENT>"
691
692 #. type: Plain text
693 #: build/C/man2/getdents.2:162 build/C/man2/readdir.2:111
694 msgid "No such directory."
695 msgstr "そのようなディレクトリは存在しない。"
696
697 #. type: TP
698 #: build/C/man2/getdents.2:162 build/C/man3/opendir.3:112
699 #: build/C/man2/readdir.2:111 build/C/man3/scandir.3:115
700 #: build/C/man3/scandirat.3:96
701 #, no-wrap
702 msgid "B<ENOTDIR>"
703 msgstr "B<ENOTDIR>"
704
705 #. type: Plain text
706 #: build/C/man2/getdents.2:165 build/C/man2/readdir.2:114
707 msgid "File descriptor does not refer to a directory."
708 msgstr "ファイルディスクリプタがディレクトリを参照していない。"
709
710 #.  SVr4 documents additional ENOLINK, EIO error conditions.
711 #. type: Plain text
712 #: build/C/man2/getdents.2:168
713 msgid "SVr4."
714 msgstr "SVr4."
715
716 #. type: Plain text
717 #: build/C/man2/getdents.2:177
718 msgid ""
719 "Glibc does not provide a wrapper for this system call; call it using "
720 "B<syscall>(2).  You will need to define the I<linux_dirent> structure "
721 "yourself.  However, you probably want to use B<readdir>(3)  instead."
722 msgstr ""
723 "glibc はこのシステムコールに対するラッパー関数を提供していないので、 "
724 "B<syscall>(2)  を使って呼び出すこと。 I<linux_dirent> 構造体は自分で定義する"
725 "必要がある。しかし、たいていはこのシステムコールではなく B<readdir>(3) を使う"
726 "べき場面のことが多い。"
727
728 #. type: Plain text
729 #: build/C/man2/getdents.2:180
730 msgid "This call supersedes B<readdir>(2)."
731 msgstr "このシステムコールは B<readdir>(2)  を置き換えるものである。"
732
733 #. type: Plain text
734 #: build/C/man2/getdents.2:193
735 msgid ""
736 "The original Linux B<getdents>()  system call did not handle large file "
737 "systems and large file offsets.  Consequently, Linux 2.4 added B<getdents64>"
738 "(), with wider types for the I<d_ino> and I<d_off> fields employed in the "
739 "I<linux_dirent> structure."
740 msgstr ""
741 "元々の Linux の B<getdents>() システムコールは、大きなファイルシステムと\n"
742 "大きなファイルオフセットを扱うことができなかった。\n"
743 "その結果、Linux 2.4 で B<getdents64>() が追加された。\n"
744 "B<getdents64>() では、I<linux_dirent> 構造体のフィールド I<d_ino> と\n"
745 "I<d_off> でビット幅の大きなデータ型が使われている。"
746
747 #. type: SH
748 #: build/C/man2/getdents.2:193 build/C/man3/scandir.3:153
749 #, no-wrap
750 msgid "EXAMPLE"
751 msgstr "例"
752
753 #.  FIXME: This program uses the older getdents() system call
754 #.  and the structure with smaller field widths.
755 #. type: Plain text
756 #: build/C/man2/getdents.2:200
757 msgid ""
758 "The program below demonstrates the use of B<getdents>().  The following "
759 "output shows an example of what we see when running this program on an ext2 "
760 "directory:"
761 msgstr ""
762 "下記のプログラムは B<getdents>()  の使用例を示したものである。 以下は、このプ"
763 "ログラムを ext2 ディレクトリで実行した際に得られる 出力の例である。"
764
765 #. type: Plain text
766 #: build/C/man2/getdents.2:213
767 #, no-wrap
768 msgid ""
769 "$B< ./a.out /testfs/>\n"
770 "--------------- nread=120 ---------------\n"
771 "i-node#  file type  d_reclen  d_off   d_name\n"
772 "       2  directory    16         12  .\n"
773 "       2  directory    16         24  ..\n"
774 "      11  directory    24         44  lost+found\n"
775 "      12  regular      16         56  a\n"
776 "  228929  directory    16         68  sub\n"
777 "   16353  directory    16         80  sub2\n"
778 "  130817  directory    16       4096  sub3\n"
779 msgstr ""
780 "$B< ./a.out /testfs/>\n"
781 "--------------- nread=120 ---------------\n"
782 "i-node#  file type  d_reclen  d_off   d_name\n"
783 "       2  directory    16         12  .\n"
784 "       2  directory    16         24  ..\n"
785 "      11  directory    24         44  lost+found\n"
786 "      12  regular      16         56  a\n"
787 "  228929  directory    16         68  sub\n"
788 "   16353  directory    16         80  sub2\n"
789 "  130817  directory    16       4096  sub3\n"
790
791 #. type: SS
792 #: build/C/man2/getdents.2:215
793 #, no-wrap
794 msgid "Program source"
795 msgstr "プログラムのソース"
796
797 #. type: Plain text
798 #: build/C/man2/getdents.2:226
799 #, no-wrap
800 msgid ""
801 "#define _GNU_SOURCE\n"
802 "#include E<lt>dirent.hE<gt>     /* Defines DT_* constants */\n"
803 "#include E<lt>fcntl.hE<gt>\n"
804 "#include E<lt>stdio.hE<gt>\n"
805 "#include E<lt>unistd.hE<gt>\n"
806 "#include E<lt>stdlib.hE<gt>\n"
807 "#include E<lt>sys/stat.hE<gt>\n"
808 "#include E<lt>sys/syscall.hE<gt>\n"
809 msgstr ""
810 "#define _GNU_SOURCE\n"
811 "#include E<lt>dirent.hE<gt>     /* Defines DT_* constants */\n"
812 "#include E<lt>fcntl.hE<gt>\n"
813 "#include E<lt>stdio.hE<gt>\n"
814 "#include E<lt>unistd.hE<gt>\n"
815 "#include E<lt>stdlib.hE<gt>\n"
816 "#include E<lt>sys/stat.hE<gt>\n"
817 "#include E<lt>sys/syscall.hE<gt>\n"
818
819 #. type: Plain text
820 #: build/C/man2/getdents.2:229
821 #, no-wrap
822 msgid ""
823 "#define handle_error(msg) \\e\n"
824 "        do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
825 msgstr ""
826 "#define handle_error(msg) \\e\n"
827 "        do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
828
829 #. type: Plain text
830 #: build/C/man2/getdents.2:236
831 #, no-wrap
832 msgid ""
833 "struct linux_dirent {\n"
834 "    long           d_ino;\n"
835 "    off_t          d_off;\n"
836 "    unsigned short d_reclen;\n"
837 "    char           d_name[];\n"
838 "};\n"
839 msgstr ""
840 "struct linux_dirent {\n"
841 "    long           d_ino;\n"
842 "    off_t          d_off;\n"
843 "    unsigned short d_reclen;\n"
844 "    char           d_name[];\n"
845 "};\n"
846
847 #. type: Plain text
848 #: build/C/man2/getdents.2:238
849 #, no-wrap
850 msgid "#define BUF_SIZE 1024\n"
851 msgstr "#define BUF_SIZE 1024\n"
852
853 #. type: Plain text
854 #: build/C/man2/getdents.2:247
855 #, no-wrap
856 msgid ""
857 "int\n"
858 "main(int argc, char *argv[])\n"
859 "{\n"
860 "    int fd, nread;\n"
861 "    char buf[BUF_SIZE];\n"
862 "    struct linux_dirent *d;\n"
863 "    int bpos;\n"
864 "    char d_type;\n"
865 msgstr ""
866 "int\n"
867 "main(int argc, char *argv[])\n"
868 "{\n"
869 "    int fd, nread;\n"
870 "    char buf[BUF_SIZE];\n"
871 "    struct linux_dirent *d;\n"
872 "    int bpos;\n"
873 "    char d_type;\n"
874
875 #. type: Plain text
876 #: build/C/man2/getdents.2:251
877 #, no-wrap
878 msgid ""
879 "    fd = open(argc E<gt> 1 ? argv[1] : \".\", O_RDONLY | O_DIRECTORY);\n"
880 "    if (fd == -1)\n"
881 "        handle_error(\"open\");\n"
882 msgstr ""
883 "    fd = open(argc E<gt> 1 ? argv[1] : \".\", O_RDONLY | O_DIRECTORY);\n"
884 "    if (fd == -1)\n"
885 "        handle_error(\"open\");\n"
886
887 #. type: Plain text
888 #: build/C/man2/getdents.2:256
889 #, no-wrap
890 msgid ""
891 "    for ( ; ; ) {\n"
892 "        nread = syscall(SYS_getdents, fd, buf, BUF_SIZE);\n"
893 "        if (nread == -1)\n"
894 "            handle_error(\"getdents\");\n"
895 msgstr ""
896 "    for ( ; ; ) {\n"
897 "        nread = syscall(SYS_getdents, fd, buf, BUF_SIZE);\n"
898 "        if (nread == -1)\n"
899 "            handle_error(\"getdents\");\n"
900
901 #. type: Plain text
902 #: build/C/man2/getdents.2:259
903 #, no-wrap
904 msgid ""
905 "        if (nread == 0)\n"
906 "            break;\n"
907 msgstr ""
908 "        if (nread == 0)\n"
909 "            break;\n"
910
911 #. type: Plain text
912 #: build/C/man2/getdents.2:278
913 #, no-wrap
914 msgid ""
915 "        printf(\"--------------- nread=%d ---------------\\en\", nread);\n"
916 "        printf(\"i-node#  file type  d_reclen  d_off   d_name\\en\");\n"
917 "        for (bpos = 0; bpos E<lt> nread;) {\n"
918 "            d = (struct linux_dirent *) (buf + bpos);\n"
919 "            printf(\"%8ld  \", d-E<gt>d_ino);\n"
920 "            d_type = *(buf + bpos + d-E<gt>d_reclen - 1);\n"
921 "            printf(\"%-10s \", (d_type == DT_REG) ?  \"regular\" :\n"
922 "                             (d_type == DT_DIR) ?  \"directory\" :\n"
923 "                             (d_type == DT_FIFO) ? \"FIFO\" :\n"
924 "                             (d_type == DT_SOCK) ? \"socket\" :\n"
925 "                             (d_type == DT_LNK) ?  \"symlink\" :\n"
926 "                             (d_type == DT_BLK) ?  \"block dev\" :\n"
927 "                             (d_type == DT_CHR) ?  \"char dev\" : \"???\");\n"
928 "            printf(\"%4d %10lld  %s\\en\", d-E<gt>d_reclen,\n"
929 "                    (long long) d-E<gt>d_off, d-E<gt>d_name);\n"
930 "            bpos += d-E<gt>d_reclen;\n"
931 "        }\n"
932 "    }\n"
933 msgstr ""
934 "        printf(\"--------------- nread=%d ---------------\\en\", nread);\n"
935 "        printf(\"i-node#  file type  d_reclen  d_off   d_name\\en\");\n"
936 "        for (bpos = 0; bpos E<lt> nread;) {\n"
937 "            d = (struct linux_dirent *) (buf + bpos);\n"
938 "            printf(\"%8ld  \", d-E<gt>d_ino);\n"
939 "            d_type = *(buf + bpos + d-E<gt>d_reclen - 1);\n"
940 "            printf(\"%-10s \", (d_type == DT_REG) ?  \"regular\" :\n"
941 "                             (d_type == DT_DIR) ?  \"directory\" :\n"
942 "                             (d_type == DT_FIFO) ? \"FIFO\" :\n"
943 "                             (d_type == DT_SOCK) ? \"socket\" :\n"
944 "                             (d_type == DT_LNK) ?  \"symlink\" :\n"
945 "                             (d_type == DT_BLK) ?  \"block dev\" :\n"
946 "                             (d_type == DT_CHR) ?  \"char dev\" : \"???\");\n"
947 "            printf(\"%4d %10lld  %s\\en\", d-E<gt>d_reclen,\n"
948 "                    (long long) d-E<gt>d_off, d-E<gt>d_name);\n"
949 "            bpos += d-E<gt>d_reclen;\n"
950 "        }\n"
951 "    }\n"
952
953 #. type: Plain text
954 #: build/C/man2/getdents.2:281
955 #, no-wrap
956 msgid ""
957 "    exit(EXIT_SUCCESS);\n"
958 "}\n"
959 msgstr ""
960 "    exit(EXIT_SUCCESS);\n"
961 "}\n"
962
963 #. type: Plain text
964 #: build/C/man2/getdents.2:285
965 msgid "B<readdir>(2), B<readdir>(3)"
966 msgstr "B<readdir>(2), B<readdir>(3)"
967
968 #. type: TH
969 #: build/C/man3/getdirentries.3:27
970 #, no-wrap
971 msgid "GETDIRENTRIES"
972 msgstr "GETDIRENTRIES"
973
974 #. type: TH
975 #: build/C/man3/getdirentries.3:27
976 #, no-wrap
977 msgid "2007-07-26"
978 msgstr "2007-07-26"
979
980 #. type: TH
981 #: build/C/man3/getdirentries.3:27 build/C/man3/opendir.3:32
982 #: build/C/man3/scandir.3:36
983 #, no-wrap
984 msgid "GNU"
985 msgstr "GNU"
986
987 #. type: Plain text
988 #: build/C/man3/getdirentries.3:30
989 msgid ""
990 "getdirentries - get directory entries in a file system-independent format"
991 msgstr ""
992 "getdirentries - ディレクトリのエントリをファイルシステムに依存しない形式で取"
993 "得する"
994
995 #. type: Plain text
996 #: build/C/man3/getdirentries.3:35
997 msgid ""
998 "B<ssize_t getdirentries(int >I<fd>B<, char *>I<buf>B<, size_t >I<nbytes> B<, "
999 "off_t *>I<basep>B<);>"
1000 msgstr ""
1001 "B<ssize_t getdirentries(int >I<fd>B<, char *>I<buf>B<, size_t >I<nbytes> B<, "
1002 "off_t *>I<basep>B<);>"
1003
1004 #. type: Plain text
1005 #: build/C/man3/getdirentries.3:43
1006 msgid "B<getdirentries>(): _BSD_SOURCE || _SVID_SOURCE"
1007 msgstr "B<getdirentries>(): _BSD_SOURCE || _SVID_SOURCE"
1008
1009 #. type: Plain text
1010 #: build/C/man3/getdirentries.3:56
1011 msgid ""
1012 "Read directory entries from the directory specified by I<fd> into I<buf>.  "
1013 "At most I<nbytes> are read.  Reading starts at offset I<*basep>, and "
1014 "I<*basep> is updated with the new position after reading."
1015 msgstr ""
1016 "I<fd> で指定されたディレクトリからエントリを読み、 I<buf> に格納する。最大で "
1017 "I<nbytes> が読み込まれる。読み込みはオフセット I<*basep> から開始され、読み込"
1018 "み終了時には I<*basep> は新しい位置に更新される。"
1019
1020 #. type: Plain text
1021 #: build/C/man3/getdirentries.3:62
1022 msgid ""
1023 "B<getdirentries>()  returns the number of bytes read or zero when at the end "
1024 "of the directory.  If an error occurs, -1 is returned, and I<errno> is set "
1025 "appropriately."
1026 msgstr ""
1027 "B<getdirentries>()  は読み込んだバイト数を返すか、ディレクトリの最後にきた場"
1028 "合は 0 を返す。 エラーが起こったら -1 を返し、 I<errno> をエラーに対応する値"
1029 "にセットする。"
1030
1031 #. type: Plain text
1032 #: build/C/man3/getdirentries.3:64
1033 msgid "See the Linux library source code for details."
1034 msgstr "詳細は Linux のライブラリソースコードを読んでほしい。"
1035
1036 #. type: Plain text
1037 #: build/C/man3/getdirentries.3:72
1038 msgid ""
1039 "Not in POSIX.1-2001.  Present on the BSDs, and a few other systems.  Use "
1040 "B<opendir>(3)  and B<readdir>(3)  instead."
1041 msgstr ""
1042 "POSIX.1-2001 にはない。 BSD に存在し、他にもいくつかのシステムにもある。 代わ"
1043 "りに B<opendir>(3)  と B<readdir>(3)  を使用すること。"
1044
1045 #. type: Plain text
1046 #: build/C/man3/getdirentries.3:75
1047 msgid "B<lseek>(2), B<open>(2)"
1048 msgstr "B<lseek>(2), B<open>(2)"
1049
1050 #. type: TH
1051 #: build/C/man3/opendir.3:32
1052 #, no-wrap
1053 msgid "OPENDIR"
1054 msgstr "OPENDIR"
1055
1056 #. type: TH
1057 #: build/C/man3/opendir.3:32
1058 #, no-wrap
1059 msgid "2010-06-20"
1060 msgstr "2010-06-20"
1061
1062 #. type: Plain text
1063 #: build/C/man3/opendir.3:35
1064 msgid "opendir, fdopendir - open a directory"
1065 msgstr "opendir, fdopendir - ディレクトリをオープンする"
1066
1067 #. type: Plain text
1068 #: build/C/man3/opendir.3:43
1069 #, no-wrap
1070 msgid ""
1071 "B<DIR *opendir(const char *>I<name>B<);>\n"
1072 "B<DIR *fdopendir(int >I<fd>B<);>\n"
1073 msgstr ""
1074 "B<DIR *opendir(const char *>I<name>B<);>\n"
1075 "B<DIR *fdopendir(int >I<fd>B<);>\n"
1076
1077 #. type: Plain text
1078 #: build/C/man3/opendir.3:51
1079 msgid "B<fdopendir>():"
1080 msgstr "B<fdopendir>():"
1081
1082 #. type: TP
1083 #: build/C/man3/opendir.3:54
1084 #, no-wrap
1085 msgid "Since glibc 2.10:"
1086 msgstr "glibc 2.10 以降:"
1087
1088 #. type: Plain text
1089 #: build/C/man3/opendir.3:57
1090 msgid "_XOPEN_SOURCE\\ E<gt>=\\ 700 || _POSIX_C_SOURCE\\ E<gt>=\\ 200809L"
1091 msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 700 || _POSIX_C_SOURCE\\ E<gt>=\\ 200809L"
1092
1093 #. type: TP
1094 #: build/C/man3/opendir.3:57
1095 #, no-wrap
1096 msgid "Before glibc 2.10:"
1097 msgstr "glibc 2.10 より前:"
1098
1099 #. type: Plain text
1100 #: build/C/man3/opendir.3:60
1101 msgid "_GNU_SOURCE"
1102 msgstr "_GNU_SOURCE"
1103
1104 #. type: Plain text
1105 #: build/C/man3/opendir.3:69
1106 msgid ""
1107 "The B<opendir>()  function opens a directory stream corresponding to the "
1108 "directory I<name>, and returns a pointer to the directory stream.  The "
1109 "stream is positioned at the first entry in the directory."
1110 msgstr ""
1111 "B<opendir>()  関数はディレクトリ I<name> に対応する ディレクトリストリームを"
1112 "オープンし、そのストリームへのポインタを返す。 ストリームの位置はディレクトリ"
1113 "の先頭のエントリに設定される。"
1114
1115 #. type: Plain text
1116 #: build/C/man3/opendir.3:83
1117 msgid ""
1118 "The B<fdopendir>()  function is like B<opendir>(), but returns a directory "
1119 "stream for the directory referred to by the open file descriptor I<fd>.  "
1120 "After a successful call to B<fdopendir>(), I<fd> is used internally by the "
1121 "implementation, and should not otherwise be used by the application."
1122 msgstr ""
1123 "B<fdopendir>()  関数は B<opendir>()  と同様だが、オープン済みのファイルディス"
1124 "クリプタ I<fd> により参照されるディレクトリに対する ディレクトリストリームを"
1125 "返す。 B<fdopendir>()  の呼び出しが成功した後は、 I<fd> は実装の内部で使用さ"
1126 "れる。アプリケーションは I<fd> を他の場面で使用すべきではない。"
1127
1128 #. type: Plain text
1129 #: build/C/man3/opendir.3:92
1130 msgid ""
1131 "The B<opendir>()  and B<fdopendir>()  functions return a pointer to the "
1132 "directory stream.  On error, NULL is returned, and I<errno> is set "
1133 "appropriately."
1134 msgstr ""
1135 "関数 B<opendir>()  と B<fdopendir>()  はディレクトリストリームへのポインタを"
1136 "返す。 エラーの場合は、NULL が返されて、 I<errno> が適切に設定される。"
1137
1138 #. type: TP
1139 #: build/C/man3/opendir.3:93
1140 #, no-wrap
1141 msgid "B<EACCES>"
1142 msgstr "B<EACCES>"
1143
1144 #. type: Plain text
1145 #: build/C/man3/opendir.3:96
1146 msgid "Permission denied."
1147 msgstr "アクセス権限がない。"
1148
1149 #. type: Plain text
1150 #: build/C/man3/opendir.3:100
1151 msgid "I<fd> is not a valid file descriptor opened for reading."
1152 msgstr ""
1153 "I<fd> が読み出し用にオープンされた、有効なファイルディスクリプタではない。"
1154
1155 #. type: TP
1156 #: build/C/man3/opendir.3:100
1157 #, no-wrap
1158 msgid "B<EMFILE>"
1159 msgstr "B<EMFILE>"
1160
1161 #. type: Plain text
1162 #: build/C/man3/opendir.3:103
1163 msgid "Too many file descriptors in use by process."
1164 msgstr "プロセスが使用中のファイルディスクリプタが多すぎる。"
1165
1166 #. type: TP
1167 #: build/C/man3/opendir.3:103
1168 #, no-wrap
1169 msgid "B<ENFILE>"
1170 msgstr "B<ENFILE>"
1171
1172 #. type: Plain text
1173 #: build/C/man3/opendir.3:106
1174 msgid "Too many files are currently open in the system."
1175 msgstr "システムでオープンされているファイルが多すぎる。"
1176
1177 #. type: Plain text
1178 #: build/C/man3/opendir.3:109
1179 msgid "Directory does not exist, or I<name> is an empty string."
1180 msgstr "ディレクトリが存在しないか、または I<name> が空文字列である。"
1181
1182 #. type: TP
1183 #: build/C/man3/opendir.3:109 build/C/man3/scandir.3:112
1184 #, no-wrap
1185 msgid "B<ENOMEM>"
1186 msgstr "B<ENOMEM>"
1187
1188 #. type: Plain text
1189 #: build/C/man3/opendir.3:112 build/C/man3/scandir.3:115
1190 msgid "Insufficient memory to complete the operation."
1191 msgstr "操作を完了するのに十分なメモリがない。"
1192
1193 #. type: Plain text
1194 #: build/C/man3/opendir.3:115
1195 msgid "I<name> is not a directory."
1196 msgstr "I<name> はディレクトリではない。"
1197
1198 #. type: SH
1199 #: build/C/man3/opendir.3:115 build/C/man3/scandir.3:118
1200 #: build/C/man3/scandirat.3:102
1201 #, no-wrap
1202 msgid "VERSIONS"
1203 msgstr "バージョン"
1204
1205 #. type: Plain text
1206 #: build/C/man3/opendir.3:118
1207 msgid "B<fdopendir>()  is available in glibc since version 2.4."
1208 msgstr "B<fdopendir>()  は glibc 2.4 以降で利用可能である。"
1209
1210 #. type: Plain text
1211 #: build/C/man3/opendir.3:123
1212 msgid ""
1213 "B<opendir>()  is present on SVr4, 4.3BSD, and specified in POSIX.1-2001.  "
1214 "B<fdopendir>()  is specified in POSIX.1-2008."
1215 msgstr ""
1216 "B<opendir>()  は SVr4 と 4.3BSD に存在し、 POSIX.1-2001 で規定されている。 "
1217 "B<fdopendir>()  は POSIX.1-2008 で規定されている。"
1218
1219 #. type: Plain text
1220 #: build/C/man3/opendir.3:126
1221 msgid ""
1222 "The underlying file descriptor of the directory stream can be obtained using "
1223 "B<dirfd>(3)."
1224 msgstr ""
1225 "ディレクトリストリームに対応するファイルディスクリプタは B<dirfd>(3)  を使用"
1226 "して得ることができる。"
1227
1228 #. type: Plain text
1229 #: build/C/man3/opendir.3:140
1230 msgid ""
1231 "The B<opendir>()  function sets the close-on-exec flag for the file "
1232 "descriptor underlying the I<DIR *>.  The B<fdopendir>()  function leaves the "
1233 "setting of the close-on-exec flag unchanged for the file descriptor, I<fd>.  "
1234 "POSIX.1-200x leaves it unspecified whether a successful call to B<fdopendir>"
1235 "()  will set the close-on-exec flag for the file descriptor, I<fd>."
1236 msgstr ""
1237 "B<opendir>()  関数は、 I<DIR *> の背後にあるファイルディスクリプタの close-"
1238 "on-exec フラグを設定する。 B<fdopendir>()  関数は、ファイルディスクリプタの "
1239 "close-on-exec フラグの設定を変更しない。 B<fdopendir>()  の呼び出しが成功した"
1240 "際に、ファイルディスクリプタ I<fd> の close-on-exec を設定するかどうかは、 "
1241 "POSIX.1-200x では規定されていない。"
1242
1243 #. type: Plain text
1244 #: build/C/man3/opendir.3:149
1245 msgid ""
1246 "B<open>(2), B<closedir>(3), B<dirfd>(3), B<readdir>(3), B<rewinddir>(3), "
1247 "B<scandir>(3), B<seekdir>(3), B<telldir>(3)"
1248 msgstr ""
1249 "B<open>(2), B<closedir>(3), B<dirfd>(3), B<readdir>(3), B<rewinddir>(3), "
1250 "B<scandir>(3), B<seekdir>(3), B<telldir>(3)"
1251
1252 #. type: TH
1253 #: build/C/man2/readdir.2:30 build/C/man3/readdir.3:36
1254 #, no-wrap
1255 msgid "READDIR"
1256 msgstr "READDIR"
1257
1258 #. type: TH
1259 #: build/C/man2/readdir.2:30 build/C/man3/readdir.3:36
1260 #, no-wrap
1261 msgid "2013-06-21"
1262 msgstr "2013-06-21"
1263
1264 #. type: Plain text
1265 #: build/C/man2/readdir.2:33
1266 msgid "readdir - read directory entry"
1267 msgstr "readdir - ディレクトリ・エントリを読み込む"
1268
1269 #. type: Plain text
1270 #: build/C/man2/readdir.2:38
1271 #, no-wrap
1272 msgid ""
1273 "B<int readdir(unsigned int >I<fd>B<, struct old_linux_dirent *>I<dirp>B<,>\n"
1274 "B<            unsigned int >I<count>B<);>\n"
1275 msgstr ""
1276 "B<int readdir(unsigned int >I<fd>B<, struct old_linux_dirent *>I<dirp>B<,>\n"
1277 "B<            unsigned int >I<count>B<);>\n"
1278
1279 #. type: Plain text
1280 #: build/C/man2/readdir.2:50
1281 msgid ""
1282 "This is not the function you are interested in.  Look at B<readdir>(3)  for "
1283 "the POSIX conforming C library interface.  This page documents the bare "
1284 "kernel system call interface, which is superseded by B<getdents>(2)."
1285 msgstr ""
1286 "これはあなたの興味をもっている関数ではない。 POSIX 準拠の C ライブラリ・イン"
1287 "ターフェースについては B<readdir>(3)  を見ること。 このページは裸のカーネルの"
1288 "システムコール・インターフェースについて 記述しているが、このインターフェース"
1289 "は B<getdents>(2)  によって取って代わられた。"
1290
1291 #. type: Plain text
1292 #: build/C/man2/readdir.2:64
1293 msgid ""
1294 "B<readdir>()  reads one I<old_linux_dirent> structure from the directory "
1295 "referred to by the file descriptor I<fd> into the buffer pointed to by "
1296 "I<dirp>.  The argument I<count> is ignored; at most one I<old_linux_dirent> "
1297 "structure is read."
1298 msgstr ""
1299 "B<readdir>()  は、ファイルディスクリプタ I<fd> が参照しているディレクトリか"
1300 "ら I<old_linux_dirent> 構造体を読み込み、 I<dirp> で指されたバッファに格納す"
1301 "る。 I<count> 引き数は(ほとんどの I<old_linux_dirent> 構造体の読み込みにおい"
1302 "て)無視される"
1303
1304 #. type: Plain text
1305 #: build/C/man2/readdir.2:68
1306 msgid "The I<old_linux_dirent> structure is declared as follows:"
1307 msgstr "I<old_linux_dirent> 構造体は以下のように宣言される:"
1308
1309 #. type: Plain text
1310 #: build/C/man2/readdir.2:77
1311 #, no-wrap
1312 msgid ""
1313 "struct old_linux_dirent {\n"
1314 "    long  d_ino;              /* inode number */\n"
1315 "    off_t d_off;              /* offset to this I<old_linux_dirent> */\n"
1316 "    unsigned short d_reclen;  /* length of this I<d_name> */\n"
1317 "    char  d_name[NAME_MAX+1]; /* filename (null-terminated) */\n"
1318 "}\n"
1319 msgstr ""
1320 "struct old_linux_dirent {\n"
1321 "    long  d_ino;              /* inode number */\n"
1322 "    off_t d_off;              /* offset to this I<old_linux_dirent> */\n"
1323 "    unsigned short d_reclen;  /* length of this I<d_name> */\n"
1324 "    char  d_name[NAME_MAX+1]; /* filename (null-terminated) */\n"
1325 "}\n"
1326
1327 #. type: Plain text
1328 #: build/C/man2/readdir.2:91
1329 msgid ""
1330 "I<d_ino> is an inode number.  I<d_off> is the distance from the start of the "
1331 "directory to this I<old_linux_dirent>.  I<d_reclen> is the size of "
1332 "I<d_name>, not counting the terminating null byte (\\(aq\\e0\\(aq).  "
1333 "I<d_name> is a null-terminated filename."
1334 msgstr ""
1335 "I<d_ino> は inode 番号である。 I<d_off> はディレクトリの最初からこの "
1336 "I<old_linux_dirent> まで距離である。 I<d_reclen> は I<d_name> の大きさで、終"
1337 "端のヌルバイト (\\(aq\\e0\\(aq) を含まない。 I<d_name> はヌルバイトで終わる"
1338 "ファイル名である。"
1339
1340 #. type: Plain text
1341 #: build/C/man2/readdir.2:97
1342 msgid ""
1343 "On success, 1 is returned.  On end of directory, 0 is returned.  On error, "
1344 "-1 is returned, and I<errno> is set appropriately."
1345 msgstr ""
1346 "成功した場合は、1 が返される。 ディレクトリの最後では 0 が返される。 エラーの"
1347 "場合は -1 が返され、 I<errno> が適切に設定される。"
1348
1349 #. type: Plain text
1350 #: build/C/man2/readdir.2:116
1351 msgid "This system call is Linux-specific."
1352 msgstr "このシステム・コールは Linux 特有である。"
1353
1354 #. type: Plain text
1355 #: build/C/man2/readdir.2:125
1356 msgid ""
1357 "Glibc does not provide a wrapper for this system call; call it using "
1358 "B<syscall>(2).  You will need to define the I<old_linux_dirent> structure "
1359 "yourself.  However, probably you should use B<readdir>(3)  instead."
1360 msgstr ""
1361 "glibc はこのシステムコールに対するラッパー関数を提供していない。 B<syscall>"
1362 "(2)  を使って呼び出すこと。 I<old_linux_dirent> 構造体を自分自身で定義する必"
1363 "要がある。しかし、たいていはこのシステムコールではなく B<readdir>(3) を使うべ"
1364 "き場面のことが多い。"
1365
1366 #. type: Plain text
1367 #: build/C/man2/readdir.2:127
1368 msgid "This system call does not exist on x86-64."
1369 msgstr "このシステムコールは x86-64 では存在しない。"
1370
1371 #. type: Plain text
1372 #: build/C/man2/readdir.2:130
1373 msgid "B<getdents>(2), B<readdir>(3)"
1374 msgstr "B<getdents>(2), B<readdir>(3)"
1375
1376 #. type: Plain text
1377 #: build/C/man3/readdir.3:39
1378 msgid "readdir, readdir_r - read a directory"
1379 msgstr "readdir, readdir_r - ディレクトリを読み込む"
1380
1381 #. type: Plain text
1382 #: build/C/man3/readdir.3:44
1383 #, no-wrap
1384 msgid "B<struct dirent *readdir(DIR *>I<dirp>B<);>\n"
1385 msgstr "B<struct dirent *readdir(DIR *>I<dirp>B<);>\n"
1386
1387 #. type: Plain text
1388 #: build/C/man3/readdir.3:47
1389 #, no-wrap
1390 msgid "B<int readdir_r(DIR *>I<dirp>B<, struct dirent *>I<entry>B<, struct dirent **>I<result>B<);>\n"
1391 msgstr "B<int readdir_r(DIR *>I<dirp>B<, struct dirent *>I<entry>B<, struct dirent **>I<result>B<);>\n"
1392
1393 #. type: Plain text
1394 #: build/C/man3/readdir.3:56
1395 msgid "B<readdir_r>():"
1396 msgstr "B<readdir_r>():"
1397
1398 #. type: Plain text
1399 #: build/C/man3/readdir.3:59
1400 msgid ""
1401 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE "
1402 "|| _POSIX_SOURCE"
1403 msgstr ""
1404 "_POSIX_C_SOURCE\\ E<gt>=\\ 1 || _XOPEN_SOURCE || _BSD_SOURCE || _SVID_SOURCE "
1405 "|| _POSIX_SOURCE"
1406
1407 #. type: Plain text
1408 #: build/C/man3/readdir.3:69
1409 msgid ""
1410 "The B<readdir>()  function returns a pointer to a I<dirent> structure "
1411 "representing the next directory entry in the directory stream pointed to by "
1412 "I<dirp>.  It returns NULL on reaching the end of the directory stream or if "
1413 "an error occurred."
1414 msgstr ""
1415 "B<readdir>()  関数は、I<dirp> が指すディレクトリストリームの中で、 次のディレ"
1416 "クトリエントリを表す I<dirent> 構造体へのポインタを返す。 ディレクトリスト"
1417 "リームの末尾に達した場合や、 エラーが発生した場合は、 NULL を返す。"
1418
1419 #. type: Plain text
1420 #: build/C/man3/readdir.3:73
1421 msgid "On Linux, the I<dirent> structure is defined as follows:"
1422 msgstr "Linux では I<dirent> 構造体は以下のように定義されている。"
1423
1424 #. type: Plain text
1425 #: build/C/man3/readdir.3:84
1426 #, no-wrap
1427 msgid ""
1428 "struct dirent {\n"
1429 "    ino_t          d_ino;       /* inode number */\n"
1430 "    off_t          d_off;       /* not an offset; see NOTES */\n"
1431 "    unsigned short d_reclen;    /* length of this record */\n"
1432 "    unsigned char  d_type;      /* type of file; not supported\n"
1433 "                                   by all file system types */\n"
1434 "    char           d_name[256]; /* filename */\n"
1435 "};\n"
1436 msgstr ""
1437 "struct dirent {\n"
1438 "    ino_t          d_ino;       /* inode 番号 */\n"
1439 "    off_t          d_off;       /* オフセットではない; 注意を参照 */\n"
1440 "    unsigned short d_reclen;    /* このレコードの長さ */\n"
1441 "    unsigned char  d_type;      /* ファイル種別。全ファイルシステム */\n"
1442 "                                   でサポートされているわけではない */\n"
1443 "    char           d_name[256]; /* ファイル名 */\n"
1444 "};\n"
1445
1446 #. type: Plain text
1447 #: build/C/man3/readdir.3:98
1448 msgid ""
1449 "The only fields in the I<dirent> structure that are mandated by POSIX.1 are: "
1450 "I<d_name>[], of unspecified size, with at most B<NAME_MAX> characters "
1451 "preceding the terminating null byte (\\(aq\\e0\\(aq); and (as an XSI "
1452 "extension)  I<d_ino>.  The other fields are unstandardized, and not present "
1453 "on all systems; see NOTES below for some further details."
1454 msgstr ""
1455 "I<dirent> 構造体のフィールドで POSIX.1 で要求されているのは、 I<d_name>[] と "
1456 "(XSI 拡張での)  I<d_ino> だけである。 I<d_name>[] はその大きさも規定されてお"
1457 "らず、 このフィールドには最大で B<NAME_MAX> 個の文字と、それに続く終端の "
1458 "NULL バイト (\\(aq\\e0\\(aq)が格納される。 他のフィールドは非標準であり、全て"
1459 "のシステムに存在するわけではない。 詳細については、下記の「注意」を参照のこ"
1460 "と。"
1461
1462 #. type: Plain text
1463 #: build/C/man3/readdir.3:104
1464 msgid ""
1465 "The data returned by B<readdir>()  may be overwritten by subsequent calls to "
1466 "B<readdir>()  for the same directory stream."
1467 msgstr ""
1468 "B<readdir>()  によって返されるデータは、それ以降の同じストリームに対する "
1469 "B<readdir>()  の呼び出しによって上書きされる可能性がある。"
1470
1471 #. type: Plain text
1472 #: build/C/man3/readdir.3:119
1473 msgid ""
1474 "The B<readdir_r>()  function is a reentrant version of B<readdir>().  It "
1475 "reads the next directory entry from the directory stream I<dirp>, and "
1476 "returns it in the caller-allocated buffer pointed to by I<entry>.  (See "
1477 "NOTES for information on allocating this buffer.)  A pointer to the returned "
1478 "item is placed in I<*result>; if the end of the directory stream was "
1479 "encountered, then NULL is instead returned in I<*result>."
1480 msgstr ""
1481 "B<readdir_r>()  関数は B<readdir>()  のリエントラント版である。 この関数は"
1482 "ディレクトリストリーム I<dirp> から次のディレクトリエントリを読み込み、 "
1483 "I<entry> が指す呼び出し元が割り当てたバッファにそのエントリを格納して返す (こ"
1484 "のバッファの割り当てについては「注意」の節を参照のこと)。 返されるエントリへ"
1485 "のポインタが I<*result> に格納される。ディレクトリストリームの末尾に達した場"
1486 "合は、 NULL が I<*result> に格納される。"
1487
1488 #. type: Plain text
1489 #: build/C/man3/readdir.3:134
1490 msgid ""
1491 "On success, B<readdir>()  returns a pointer to a I<dirent> structure.  (This "
1492 "structure may be statically allocated; do not attempt to B<free>(3)  it.)  "
1493 "If the end of the directory stream is reached, NULL is returned and I<errno> "
1494 "is not changed.  If an error occurs, NULL is returned and I<errno> is set "
1495 "appropriately."
1496 msgstr ""
1497 "成功すると、 B<readdir>()  は I<dirent> 構造体へのポインタを返す。 (この構造"
1498 "体は静的に割り当てられているかもしれない。 このポインタを B<free>(3)  しよう"
1499 "としないこと。)  ディレクトリストリームの末尾に達した場合には、NULL が返さ"
1500 "れ、 I<errno> は変化しない。 エラーが発生した場合、NULL が返され、 I<errno> "
1501 "が適切に設定される。"
1502
1503 #. type: Plain text
1504 #: build/C/man3/readdir.3:143
1505 msgid ""
1506 "The B<readdir_r>()  function returns 0 on success.  On error, it returns a "
1507 "positive error number (listed under ERRORS).  If the end of the directory "
1508 "stream is reached, B<readdir_r>()  returns 0, and returns NULL in I<*result>."
1509 msgstr ""
1510 "成功すると、 B<readdir_r>()  関数は 0 を返す。 エラーの場合、(「エラー」の節"
1511 "のリストに載っている) 正のエラー番号を返す。 ディレクトリストリームの末尾に達"
1512 "した場合、 B<readdir_r>()  は返り値として 0 を返し、 I<*result> に NULL を格"
1513 "納する。"
1514
1515 #. type: Plain text
1516 #: build/C/man3/readdir.3:152
1517 msgid "The B<readdir>()  function is not thread-safe."
1518 msgstr "B<readdir>() 関数はスレッドセーフではない。"
1519
1520 #. type: Plain text
1521 #: build/C/man3/readdir.3:156
1522 msgid "The B<readdir_r>()  function is thread-safe."
1523 msgstr "B<readdir_r>() 関数はスレッドセーフである。"
1524
1525 #. type: Plain text
1526 #: build/C/man3/readdir.3:158 build/C/man3/rewinddir.3:55
1527 msgid "SVr4, 4.3BSD, POSIX.1-2001."
1528 msgstr "SVr4, 4.3BSD, POSIX.1-2001."
1529
1530 #. type: Plain text
1531 #: build/C/man3/readdir.3:174
1532 msgid ""
1533 "Only the fields I<d_name> and I<d_ino> are specified in POSIX.1-2001.  The "
1534 "remaining fields are available on many, but not all systems.  Under glibc, "
1535 "programs can check for the availability of the fields not defined in POSIX.1 "
1536 "by testing whether the macros B<_DIRENT_HAVE_D_NAMLEN>, "
1537 "B<_DIRENT_HAVE_D_RECLEN>, B<_DIRENT_HAVE_D_OFF>, or B<_DIRENT_HAVE_D_TYPE> "
1538 "are defined."
1539 msgstr ""
1540 "フィールド I<d_name> と I<d_ino> だけが POSIX.1-2001 で規定されている。 残り"
1541 "のフィールドは多くのシステムに存在するが、全てのシステムに 存在するわけではな"
1542 "い。 glibc では、プログラムが POSIX.1 で定義されていないフィールドが 利用でき"
1543 "るかをチェックすることができる。 チェックするには、マクロ "
1544 "B<_DIRENT_HAVE_D_NAMLEN>, B<_DIRENT_HAVE_D_RECLEN>, B<_DIRENT_HAVE_D_OFF>, "
1545 "B<_DIRENT_HAVE_D_TYPE> が定義されているかをテストすればよい。"
1546
1547 #.  https://lwn.net/Articles/544298/
1548 #. type: Plain text
1549 #: build/C/man3/readdir.3:187
1550 msgid ""
1551 "The value returned in I<d_off> is the same as would be returned by calling "
1552 "B<telldir>(3)  at the current position in the directory stream.  Be aware "
1553 "that despite its type and name, the I<d_off> field is seldom any kind of "
1554 "directory offset on modern file systems.  Applications should treat this "
1555 "field as an opaque value, making no assumptions about its contents; see also "
1556 "B<telldir>(3)."
1557 msgstr ""
1558 "I<d_off> で返される値は B<telldir>(3) が返す値と同じで、ディレクトリストリー"
1559 "ム内の現在の位置を示す。\n"
1560 "フィールドの型や名前はこうなっていますが、最近のファイルシステムでは "
1561 "I<d_off> フィールドが何らかのディレクトリオフセットであることはめったいにな"
1562 "い。アプリケーションプログラムでは、必ずこの値を内容を意識せず単なる値として"
1563 "扱うべきであり、その内容について前提を持つべきではない。"
1564
1565 #. type: Plain text
1566 #: build/C/man3/readdir.3:200
1567 msgid ""
1568 "Other than Linux, the I<d_type> field is available mainly only on BSD "
1569 "systems.  This field makes it possible to avoid the expense of calling "
1570 "B<lstat>(2)  if further actions depend on the type of the file.  If the "
1571 "B<_BSD_SOURCE> feature test macro is defined, then glibc defines the "
1572 "following macro constants for the value returned in I<d_type>:"
1573 msgstr ""
1574 "I<d_type> フィールドは、Linux 以外では、 主に BSD 系のシステムにだけ存在す"
1575 "る。 このフィールドを使うと、 その後の動作がファイルの種別により決まる場合"
1576 "に、 B<lstat>(2)  を呼び出すコストを避けることができる。 機能検査マクロ "
1577 "B<_BSD_SOURCE> が定義された場合、glibc は I<d_type> で返される値として以下の"
1578 "マクロ定数を定義する。"
1579
1580 #. type: Plain text
1581 #: build/C/man3/readdir.3:231
1582 msgid ""
1583 "If the file type could not be determined, the value B<DT_UNKNOWN> is "
1584 "returned in I<d_type>."
1585 msgstr ""
1586 "ファイル種別を決定できなかった場合には、 I<d_type> に B<DT_UNKNOWN> が入る。"
1587
1588 #. type: Plain text
1589 #: build/C/man3/readdir.3:250
1590 msgid ""
1591 "Since POSIX.1 does not specify the size of the I<d_name> field, and other "
1592 "nonstandard fields may precede that field within the I<dirent> structure, "
1593 "portable applications that use B<readdir_r>()  should allocate the buffer "
1594 "whose address is passed in I<entry> as follows:"
1595 msgstr ""
1596 "POSIX.1 では I<d_name> フィールドのサイズは規定されておらず、 I<dirent> 構造"
1597 "体の I<d_name> の後ろに他の非標準のフィールドがあるかもしれないので、 移植性"
1598 "が必要なアプリケーションで B<readdir_r>()  を使う場合は I<entry> に渡すバッ"
1599 "ファを次のようにして割り当てるべきである。"
1600
1601 #. type: Plain text
1602 #: build/C/man3/readdir.3:258
1603 #, no-wrap
1604 msgid ""
1605 "name_max = pathconf(dirpath, _PC_NAME_MAX);\n"
1606 "if (name_max == -1)         /* Limit not defined, or error */\n"
1607 "    name_max = 255;         /* Take a guess */\n"
1608 "len = offsetof(struct dirent, d_name) + name_max + 1;\n"
1609 "entryp = malloc(len);\n"
1610 msgstr ""
1611 "name_max = pathconf(dirpath, _PC_NAME_MAX);\n"
1612 "if (name_max == -1)         /* 上限が定義されていない、またはエラー */\n"
1613 "    name_max = 255;         /* 適当な値を入れる */\n"
1614 "len = offsetof(struct dirent, d_name) + name_max + 1;\n"
1615 "entryp = malloc(len);\n"
1616
1617 #. type: Plain text
1618 #: build/C/man3/readdir.3:265
1619 msgid ""
1620 "(POSIX.1 requires that I<d_name> is the last field in a I<struct dirent>.)"
1621 msgstr ""
1622 "(POSIX.1 では I<struct dirent> の最後のフィールドが I<d_name> であることを要"
1623 "求している。)"
1624
1625 #. type: Plain text
1626 #: build/C/man3/readdir.3:277
1627 msgid ""
1628 "B<getdents>(2), B<read>(2), B<closedir>(3), B<dirfd>(3), B<ftw>(3), "
1629 "B<offsetof>(3), B<opendir>(3), B<rewinddir>(3), B<scandir>(3), B<seekdir>"
1630 "(3), B<telldir>(3)"
1631 msgstr ""
1632 "B<getdents>(2), B<read>(2), B<closedir>(3), B<dirfd>(3), B<ftw>(3), "
1633 "B<offsetof>(3), B<opendir>(3), B<rewinddir>(3), B<scandir>(3), B<seekdir>"
1634 "(3), B<telldir>(3)"
1635
1636 #. type: TH
1637 #: build/C/man3/rewinddir.3:31
1638 #, no-wrap
1639 msgid "REWINDDIR"
1640 msgstr "REWINDDIR"
1641
1642 #. type: TH
1643 #: build/C/man3/rewinddir.3:31
1644 #, no-wrap
1645 msgid "1995-06-11"
1646 msgstr "1995-06-11"
1647
1648 #. type: Plain text
1649 #: build/C/man3/rewinddir.3:34
1650 msgid "rewinddir - reset directory stream"
1651 msgstr "rewinddir - ディレクトリストリームの初期化"
1652
1653 #. type: Plain text
1654 #: build/C/man3/rewinddir.3:41
1655 #, no-wrap
1656 msgid "B<void rewinddir(DIR *>I<dirp>B<);>\n"
1657 msgstr "B<void rewinddir(DIR *>I<dirp>B<);>\n"
1658
1659 #. type: Plain text
1660 #: build/C/man3/rewinddir.3:49
1661 msgid ""
1662 "The B<rewinddir>()  function resets the position of the directory stream "
1663 "I<dirp> to the beginning of the directory."
1664 msgstr ""
1665 "B<rewinddir>()  関数は、ディレクトリストリーム I<dirp> の位置を ディレクトリ"
1666 "の先頭に初期化する。"
1667
1668 #. type: Plain text
1669 #: build/C/man3/rewinddir.3:53
1670 msgid "The B<rewinddir>()  function returns no value."
1671 msgstr "B<rewinddir>()  関数は、値を返さない。"
1672
1673 #. type: Plain text
1674 #: build/C/man3/rewinddir.3:62
1675 msgid ""
1676 "B<closedir>(3), B<opendir>(3), B<readdir>(3), B<scandir>(3), B<seekdir>(3), "
1677 "B<telldir>(3)"
1678 msgstr ""
1679 "B<closedir>(3), B<opendir>(3), B<readdir>(3), B<scandir>(3), B<seekdir>(3), "
1680 "B<telldir>(3)"
1681
1682 #. type: TH
1683 #: build/C/man3/scandir.3:36
1684 #, no-wrap
1685 msgid "SCANDIR"
1686 msgstr "SCANDIR"
1687
1688 #. type: TH
1689 #: build/C/man3/scandir.3:36
1690 #, no-wrap
1691 msgid "2013-04-19"
1692 msgstr "2013-04-19"
1693
1694 #. type: Plain text
1695 #: build/C/man3/scandir.3:39
1696 msgid "scandir, alphasort, versionsort - scan a directory for matching entries"
1697 msgstr "scandir, alphasort, versionsort - ディレクトリを走査する"
1698
1699 #. type: Plain text
1700 #: build/C/man3/scandir.3:44
1701 #, no-wrap
1702 msgid "B<int scandir(const char *>I<dirp>B<, struct dirent ***>I<namelist>B<,>\n"
1703 msgstr "B<int scandir(const char *>I<dirp>B<, struct dirent ***>I<namelist>B<,>\n"
1704
1705 #. type: Plain text
1706 #: build/C/man3/scandir.3:47 build/C/man3/scandirat.3:42
1707 #, no-wrap
1708 msgid ""
1709 "B<int (*>I<filter>B<)(const struct dirent *),>\n"
1710 "B<int (*>I<compar>B<)(const struct dirent **, const struct dirent **));>\n"
1711 msgstr ""
1712 "B<int (*>I<filter>B<)(const struct dirent *),>\n"
1713 "B<int (*>I<compar>B<)(const struct dirent **, const struct dirent **));>\n"
1714
1715 #. type: Plain text
1716 #: build/C/man3/scandir.3:50
1717 #, no-wrap
1718 msgid "B<int alphasort(const void *>I<a>B<, const void *>I<b>B<);>\n"
1719 msgstr "B<int alphasort(const void *>I<a>B<, const void *>I<b>B<);>\n"
1720
1721 #. type: Plain text
1722 #: build/C/man3/scandir.3:52
1723 #, no-wrap
1724 msgid "B<int versionsort(const void *>I<a>B<, const void *>I<b>B<);>\n"
1725 msgstr "B<int versionsort(const void *>I<a>B<, const void *>I<b>B<);>\n"
1726
1727 #. type: Plain text
1728 #: build/C/man3/scandir.3:62
1729 msgid "B<scandir>(), B<alphasort>(): _BSD_SOURCE || _SVID_SOURCE"
1730 msgstr "B<scandir>(), B<alphasort>(): _BSD_SOURCE || _SVID_SOURCE"
1731
1732 #. type: Plain text
1733 #: build/C/man3/scandir.3:65
1734 msgid "B<versionsort>(): _GNU_SOURCE"
1735 msgstr "B<versionsort>(): _GNU_SOURCE"
1736
1737 #. type: Plain text
1738 #: build/C/man3/scandir.3:80
1739 msgid ""
1740 "The B<scandir>()  function scans the directory I<dirp>, calling I<filter>() "
1741 "on each directory entry.  Entries for which I<filter>() returns nonzero are "
1742 "stored in strings allocated via B<malloc>(3), sorted using B<qsort>(3)  with "
1743 "the comparison function I<compar>(), and collected in array I<namelist> "
1744 "which is allocated via B<malloc>(3).  If I<filter> is NULL, all entries are "
1745 "selected."
1746 msgstr ""
1747 "関数 B<scandir>()  はディレクトリ I<dirp> を走査し、 ディレクトリの各エントリ"
1748 "を引き数として B<filter>()  を呼び出す。 B<filter>()  が 0 以外の値を返すエン"
1749 "トリは B<malloc>(3)  によって 確保された文字列に保存され、比較関数 B<compar>"
1750 "()  を用いて B<qsort>(3)  によりソートされ、 B<malloc>(3)  により確保された配"
1751 "列 I<namelist> にまとめられる。 I<filter> が NULL ならば、すべてのエントリが"
1752 "選択される。"
1753
1754 #. type: Plain text
1755 #: build/C/man3/scandir.3:92
1756 msgid ""
1757 "The B<alphasort>()  and B<versionsort>()  functions can be used as the "
1758 "comparison function I<compar>().  The former sorts directory entries using "
1759 "B<strcoll>(3), the latter using B<strverscmp>(3)  on the strings I<(*a)-"
1760 "E<gt>d_name> and I<(*b)-E<gt>d_name>."
1761 msgstr ""
1762 "比較関数 I<compar>()  には B<alphasort>()  関数と B<versionsort>()  関数を使"
1763 "うことができる。 B<alphasort>()  は B<strcoll>(3)  を用いてディレクトリエント"
1764 "リをソートし、 B<versionsort>()  は文字列 I<(*a)-E<gt>d_name> と I<(*b)-"
1765 "E<gt>d_name> に対して B<strverscmp>(3)  を用いる。"
1766
1767 #. type: Plain text
1768 #: build/C/man3/scandir.3:100
1769 msgid ""
1770 "The B<scandir>()  function returns the number of directory entries "
1771 "selected.  On error, -1 is returned, with I<errno> set to indicate the cause "
1772 "of the error."
1773 msgstr ""
1774 "B<scandir>() 関数は、選択されたディレクトリのエントリ数を返す。 エラーの場"
1775 "合、 -1 を返し、 I<errno> にエラーの原因を示す値を設定する。"
1776
1777 #. type: Plain text
1778 #: build/C/man3/scandir.3:108
1779 msgid ""
1780 "The B<alphasort>()  and B<versionsort>()  functions return an integer less "
1781 "than, equal to, or greater than zero if the first argument is considered to "
1782 "be respectively less than, equal to, or greater than the second."
1783 msgstr ""
1784 "関数 B<alphasort>()  と B<versionsort>()  は 1 番目の引き数が 2 番目の引き数"
1785 "に対して、 [小さい/等しい/大きい] かに応じて、0 より [小さい/等しい/大きい] "
1786 "値を返す。"
1787
1788 #. type: Plain text
1789 #: build/C/man3/scandir.3:112
1790 msgid "The path in I<dirp> does not exist."
1791 msgstr "I<dirp> で指定されたパスが存在しない。"
1792
1793 #. type: Plain text
1794 #: build/C/man3/scandir.3:118
1795 msgid "The path in I<dirp> is not a directory."
1796 msgstr "I<dirp> で指定されたパスがディレクトリではない。"
1797
1798 #. type: Plain text
1799 #: build/C/man3/scandir.3:121
1800 msgid "B<versionsort>()  was added to glibc in version 2.1."
1801 msgstr "B<versionsort>()  は、glibc バージョン 2.1 で追加された。"
1802
1803 #. type: Plain text
1804 #: build/C/man3/scandir.3:128
1805 msgid ""
1806 "B<alphasort>()  and B<scandir>()  are specified in POSIX.1-2008, and are "
1807 "widely available.  B<versionsort>()  is a GNU extension."
1808 msgstr ""
1809 "B<alphasort>()  と B<scandir>()  は POSIX.1-2008 で規定されており、広く利用可"
1810 "能である。 B<versionsort>()  は GNU 拡張である。"
1811
1812 #. type: Plain text
1813 #: build/C/man3/scandir.3:135
1814 msgid ""
1815 "The functions B<scandir>()  and B<alphasort>()  are from 4.3BSD, and have "
1816 "been available under Linux since libc4.  Libc4 and libc5 use the more "
1817 "precise prototype"
1818 msgstr ""
1819 "関数 B<scandir>()  と B<alphasort>()  は 4.3BSD から取り入れられ、Linux では "
1820 "libc4 から使用可能になった。 libc4 と libc5 では以下のようなもっと詳細なプロ"
1821 "トタイプを使っている。"
1822
1823 #. type: Plain text
1824 #: build/C/man3/scandir.3:139
1825 #, no-wrap
1826 msgid ""
1827 "    int alphasort(const struct dirent ** a,\n"
1828 "                  const struct dirent **b);\n"
1829 msgstr ""
1830 "    int alphasort(const struct dirent ** a,\n"
1831 "                  const struct dirent **b);\n"
1832
1833 #. type: Plain text
1834 #: build/C/man3/scandir.3:142
1835 msgid "but glibc 2.0 returns to the imprecise BSD prototype."
1836 msgstr "しかし glibc 2.0 では不正確な BSD のプロトタイプに戻った。"
1837
1838 #. type: Plain text
1839 #: build/C/man3/scandir.3:146
1840 msgid ""
1841 "The function B<versionsort>()  is a GNU extension, available since glibc 2.1."
1842 msgstr ""
1843 "関数 B<versionsort>()  は GNU の拡張であり、glibc 2.1 以降で使用可能である。"
1844
1845 #. type: Plain text
1846 #: build/C/man3/scandir.3:153
1847 msgid ""
1848 "Since glibc 2.1, B<alphasort>()  calls B<strcoll>(3); earlier it used "
1849 "B<strcmp>(3)."
1850 msgstr ""
1851 "glibc 2.1 以降では B<alphasort>()  は B<strcoll>(3)  を呼び出す。 "
1852 "B<alphasort>()  は以前は B<strcmp>(3)  を使っていた。"
1853
1854 #. type: Plain text
1855 #: build/C/man3/scandir.3:158
1856 #, no-wrap
1857 msgid ""
1858 "#define _SVID_SOURCE\n"
1859 "/* print files in current directory in reverse order */\n"
1860 "#include E<lt>dirent.hE<gt>\n"
1861 msgstr ""
1862 "#define _SVID_SOURCE\n"
1863 "/* カレントディレクトリのファイルを逆順に出力する */\n"
1864 "#include E<lt>dirent.hE<gt>\n"
1865
1866 #. type: Plain text
1867 #: build/C/man3/scandir.3:164
1868 #, no-wrap
1869 msgid ""
1870 "int\n"
1871 "main(void)\n"
1872 "{\n"
1873 "    struct dirent **namelist;\n"
1874 "    int n;\n"
1875 msgstr ""
1876 "int\n"
1877 "main(void)\n"
1878 "{\n"
1879 "    struct dirent **namelist;\n"
1880 "    int n;\n"
1881
1882 #. type: Plain text
1883 #: build/C/man3/scandir.3:176
1884 #, no-wrap
1885 msgid ""
1886 "    n = scandir(\".\", &namelist, NULL, alphasort);\n"
1887 "    if (n E<lt> 0)\n"
1888 "        perror(\"scandir\");\n"
1889 "    else {\n"
1890 "        while (n--) {\n"
1891 "            printf(\"%s\\en\", namelist[n]-E<gt>d_name);\n"
1892 "            free(namelist[n]);\n"
1893 "        }\n"
1894 "        free(namelist);\n"
1895 "    }\n"
1896 "}\n"
1897 msgstr ""
1898 "    n = scandir(\".\", &namelist, NULL, alphasort);\n"
1899 "    if (n E<lt> 0)\n"
1900 "        perror(\"scandir\");\n"
1901 "    else {\n"
1902 "        while (n--) {\n"
1903 "            printf(\"%s\\en\", namelist[n]-E<gt>d_name);\n"
1904 "            free(namelist[n]);\n"
1905 "        }\n"
1906 "        free(namelist);\n"
1907 "    }\n"
1908 "}\n"
1909
1910 #. type: Plain text
1911 #: build/C/man3/scandir.3:189
1912 msgid ""
1913 "B<closedir>(3), B<fnmatch>(3), B<opendir>(3), B<readdir>(3), B<rewinddir>"
1914 "(3), B<scandirat>(3), B<seekdir>(3), B<strcmp>(3), B<strcoll>(3), "
1915 "B<strverscmp>(3), B<telldir>(3)"
1916 msgstr ""
1917 "B<closedir>(3), B<fnmatch>(3), B<opendir>(3), B<readdir>(3), B<rewinddir>"
1918 "(3), B<scandirat>(3), B<seekdir>(3), B<strcmp>(3), B<strcoll>(3), "
1919 "B<strverscmp>(3), B<telldir>(3)"
1920
1921 #. type: TH
1922 #: build/C/man3/scandirat.3:25
1923 #, no-wrap
1924 msgid "SCANDIRAT"
1925 msgstr "SCANDIRAT"
1926
1927 #. type: TH
1928 #: build/C/man3/scandirat.3:25
1929 #, no-wrap
1930 msgid "2012-03-17"
1931 msgstr "2012-03-17"
1932
1933 #. type: Plain text
1934 #: build/C/man3/scandirat.3:28
1935 msgid "scandirat - scan a directory relative to a directory file descriptor"
1936 msgstr ""
1937 "scandirat - ディレクトリのファイルディスクリプタからの相対パスで指定された"
1938 "ディレクトリを走査する"
1939
1940 #. type: Plain text
1941 #: build/C/man3/scandirat.3:31
1942 #, no-wrap
1943 msgid "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
1944 msgstr "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
1945
1946 #. type: Plain text
1947 #: build/C/man3/scandirat.3:34
1948 #, no-wrap
1949 msgid ""
1950 "B<#include E<lt>fcntl.hE<gt>>          /* Definition of AT_* constants */\n"
1951 "B<#include E<lt>dirent.hE<gt>>\n"
1952 msgstr ""
1953 "B<#include E<lt>fcntl.hE<gt>>          /* AT_* 定数の定義 */\n"
1954 "B<#include E<lt>dirent.hE<gt>>\n"
1955
1956 #. type: Plain text
1957 #: build/C/man3/scandirat.3:38
1958 msgid ""
1959 "B<int scandirat(int >I<dirfd>B<, const char *>I<dirp>B<,> B<struct dirent "
1960 "***>I<namelist>B<,>"
1961 msgstr ""
1962 "B<int scandirat(int >I<dirfd>B<, const char *>I<dirp>B<,> B<struct dirent "
1963 "***>I<namelist>B<,>"
1964
1965 #. type: Plain text
1966 #: build/C/man3/scandirat.3:50
1967 msgid ""
1968 "The B<scandirat>()  system call operates in exactly the same way as "
1969 "B<scandir>(3), except for the differences described in this manual page."
1970 msgstr ""
1971 "B<scandirat>() システムコールは B<scandir>() と全く同様の動作をする。\n"
1972 "差分についてこのマニュアルページで説明する。"
1973
1974 #. type: Plain text
1975 #: build/C/man3/scandirat.3:60
1976 msgid ""
1977 "If the pathname given in I<dirp> is relative, then it is interpreted "
1978 "relative to the directory referred to by the file descriptor I<dirfd> "
1979 "(rather than relative to the current working directory of the calling "
1980 "process, as is done by B<scandir>(3)  for a relative pathname)."
1981 msgstr ""
1982 "I<dirp> で指定されたパス名が相対パスの場合、ファイルディスクリプタ I<dirfd>\n"
1983 "が参照するディレクトリからの相対パスと解釈される\n"
1984 "(これに対して、B<scandir>(3) の場合は、相対パス名は、呼び出したプロセスの\n"
1985 "カレントワーキングディレクトリからの相対パスと解釈される)。"
1986
1987 #. type: Plain text
1988 #: build/C/man3/scandirat.3:72
1989 msgid ""
1990 "If I<dirp> is relative and I<dirfd> is the special value B<AT_FDCWD>, then "
1991 "I<dirp> is interpreted relative to the current working directory of the "
1992 "calling process (like B<scandir>(3))."
1993 msgstr ""
1994 "I<dirp> が相対パスで I<dirfd> が特別な値 B<AT_FDCWD> の場合、\n"
1995 "I<dirp> は (B<scandir>(3) と同様に) 呼び出したプロセスのカレントワーキング\n"
1996 "ディレクトリからの相対パスと解釈される。"
1997
1998 #. type: Plain text
1999 #: build/C/man3/scandirat.3:78
2000 msgid "If I<dirp> is absolute, then I<dirfd> is ignored."
2001 msgstr "I<dirp> が絶対パスの場合、I<dirfd> は無視される。"
2002
2003 #. type: Plain text
2004 #: build/C/man3/scandirat.3:85
2005 msgid ""
2006 "On success, B<scandirat>()  returns the number of directory entries "
2007 "selected.  On error, -1 is returned and I<errno> is set to indicate the "
2008 "error."
2009 msgstr ""
2010 "成功した場合は、 B<scandirat>() は選択されたディレクトリエントリ数を返す。\n"
2011 "エラーの場合、 -1 が返され、 I<errno> にエラーを示す値が設定される。"
2012
2013 #. type: Plain text
2014 #: build/C/man3/scandirat.3:92
2015 msgid ""
2016 "The same errors that occur for B<scandir>(3)  can also occur for B<scandirat>"
2017 "().  The following additional errors can occur for B<scandirat>():"
2018 msgstr ""
2019 "B<scandir>(3) で発生するのと同じエラーが B<scandirat>() でも発生する。\n"
2020 "B<scandirat>() では追加で以下のエラーも発生する:"
2021
2022 #. type: Plain text
2023 #: build/C/man3/scandirat.3:96
2024 msgid "I<dirfd> is not a valid file descriptor."
2025 msgstr "I<dirfd> が有効なファイルディスクリプタではない。"
2026
2027 #. type: Plain text
2028 #: build/C/man3/scandirat.3:102
2029 msgid ""
2030 "I<dirp> is a relative path and I<dirfd> is a file descriptor referring to a "
2031 "file other than a directory."
2032 msgstr ""
2033 "I<dirp> が相対パスで、I<dirfd> がディレクトリ以外のファイルを参照している\n"
2034 "ファイルディスクリプタである。"
2035
2036 #. type: Plain text
2037 #: build/C/man3/scandirat.3:105
2038 msgid "B<scandirat>()  was added to glibc in version 2.15."
2039 msgstr "B<scandirat>()  は glibc バージョン 2.15 で追加された。"
2040
2041 #. type: Plain text
2042 #: build/C/man3/scandirat.3:107
2043 msgid "This function is a GNU extension."
2044 msgstr "この関数は GNU による拡張である。"
2045
2046 #. type: Plain text
2047 #: build/C/man3/scandirat.3:112
2048 msgid "See B<openat>(2)  for an explanation of the need for B<scandirat>()."
2049 msgstr "B<scandirat>() が必要な理由については B<openat>(2) を参照すること。"
2050
2051 #. type: Plain text
2052 #: build/C/man3/scandirat.3:116
2053 msgid "B<openat>(2), B<scandir>(3), B<path_resolution>(7)"
2054 msgstr "B<openat>(2), B<scandir>(3), B<path_resolution>(7)"
2055
2056 #. type: TH
2057 #: build/C/man3/seekdir.3:31
2058 #, no-wrap
2059 msgid "SEEKDIR"
2060 msgstr "SEEKDIR"
2061
2062 #. type: TH
2063 #: build/C/man3/seekdir.3:31 build/C/man3/telldir.3:30
2064 #, no-wrap
2065 msgid "2013-03-24"
2066 msgstr "2013-03-24"
2067
2068 #. type: Plain text
2069 #: build/C/man3/seekdir.3:35
2070 msgid ""
2071 "seekdir - set the position of the next readdir() call in the directory "
2072 "stream."
2073 msgstr ""
2074 "seekdir - 次の readdir() 呼び出しのために、ディレクトリストリーム中の位置を "
2075 "設定する"
2076
2077 #. type: Plain text
2078 #: build/C/man3/seekdir.3:40
2079 #, no-wrap
2080 msgid "B<void seekdir(DIR *>I<dirp>B<, long >I<loc>B<);>\n"
2081 msgstr "B<void seekdir(DIR *>I<dirp>B<, long >I<loc>B<);>\n"
2082
2083 #. type: Plain text
2084 #: build/C/man3/seekdir.3:49
2085 msgid "B<seekdir>(): _BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE"
2086 msgstr "B<seekdir>(): _BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE"
2087
2088 #. type: Plain text
2089 #: build/C/man3/seekdir.3:60
2090 msgid ""
2091 "The B<seekdir>()  function sets the location in the directory stream from "
2092 "which the next B<readdir>(2)  call will start.  The I<loc> argument should "
2093 "be a value returned by a previous call to B<telldir>(3)."
2094 msgstr ""
2095 "B<seekdir>()  関数は、次の B<readdir>(3)  呼び出しの開始位置である、 ディレク"
2096 "トリストリームの中での位置を設定する。 I<loc> 引き数には、それ以前の "
2097 "B<telldir>(3) の呼び出しで返された値を渡すべきである。"
2098
2099 #. type: Plain text
2100 #: build/C/man3/seekdir.3:64
2101 msgid "The B<seekdir>()  function returns no value."
2102 msgstr "B<seekdir>()  関数は、値を返さない。"
2103
2104 #. type: Plain text
2105 #: build/C/man3/seekdir.3:66 build/C/man3/telldir.3:66
2106 msgid "4.3BSD, POSIX.1-2001."
2107 msgstr "4.3BSD, POSIX.1-2001."
2108
2109 #. type: Plain text
2110 #: build/C/man3/seekdir.3:78
2111 msgid ""
2112 "In glibc up to version 2.1.1, the type of the I<loc> argument was I<off_t>.  "
2113 "POSIX.1-2001 specifies I<long>, and this is the type used since glibc "
2114 "2.1.2.  See B<telldir>(3)  for information on why you should be careful in "
2115 "making any assumptions about the value in this argument."
2116 msgstr ""
2117 "バージョン 2.1.1 以前の glibc では、 I<loc> 引き数の型は I<off_t> であった。 "
2118 "POSIX.1-2001 では I<long> と規定されており、glibc 2.1.2 以降では I<long> に"
2119 "なっている。この引き数の値に前提を置く際には気を付けないといけない理由につい"
2120 "ては B<telldir>(3) を参照のこと。"
2121
2122 #. type: Plain text
2123 #: build/C/man3/seekdir.3:86
2124 msgid ""
2125 "B<lseek>(2), B<closedir>(3), B<opendir>(3), B<readdir>(3), B<rewinddir>(3), "
2126 "B<scandir>(3), B<telldir>(3)"
2127 msgstr ""
2128 "B<lseek>(2), B<closedir>(3), B<opendir>(3), B<readdir>(3), B<rewinddir>(3), "
2129 "B<scandir>(3), B<telldir>(3)"
2130
2131 #. type: TH
2132 #: build/C/man3/telldir.3:30
2133 #, no-wrap
2134 msgid "TELLDIR"
2135 msgstr "TELLDIR"
2136
2137 #. type: Plain text
2138 #: build/C/man3/telldir.3:33
2139 msgid "telldir - return current location in directory stream"
2140 msgstr "telldir - ディレクトリストリーム中の現在位置を返す"
2141
2142 #. type: Plain text
2143 #: build/C/man3/telldir.3:38
2144 #, no-wrap
2145 msgid "B<long telldir(DIR *>I<dirp>B<);>\n"
2146 msgstr "B<long telldir(DIR *>I<dirp>B<);>\n"
2147
2148 #. type: Plain text
2149 #: build/C/man3/telldir.3:47
2150 msgid "B<telldir>(): _BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE"
2151 msgstr "B<telldir>(): _BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE"
2152
2153 #. type: Plain text
2154 #: build/C/man3/telldir.3:52
2155 msgid ""
2156 "The B<telldir>()  function returns the current location associated with the "
2157 "directory stream I<dirp>."
2158 msgstr ""
2159 "B<telldir>()  関数は、ディレクトリストリーム I<dirp> に結びつけられた 現在位"
2160 "置を返す。"
2161
2162 #. type: Plain text
2163 #: build/C/man3/telldir.3:60
2164 msgid ""
2165 "On success, the B<telldir>()  function returns the current location in the "
2166 "directory stream.  On error, -1 is returned, and I<errno> is set "
2167 "appropriately."
2168 msgstr ""
2169 "成功した場合、 B<telldir>()  関数はディレクトリストリーム中の現在位置を返"
2170 "す。 エラーの場合、-1 が返されて、 I<errno> が適切に設定される。"
2171
2172 #. type: Plain text
2173 #: build/C/man3/telldir.3:74
2174 msgid ""
2175 "In glibc up to version 2.1.1, the return type of B<telldir>()  was "
2176 "I<off_t>.  POSIX.1-2001 specifies I<long>, and this is the type used since "
2177 "glibc 2.1.2."
2178 msgstr ""
2179 "バージョン 2.1.1 以前の glibc では、 B<telldir>()9 の返り値の型は I<off_t> で"
2180 "あった。 POSIX.1-2001 では I<long> と規定されており、glibc 2.1.2 以降では "
2181 "I<long> になっている。"
2182
2183 #.  https://lwn.net/Articles/544298/
2184 #. type: Plain text
2185 #: build/C/man3/telldir.3:90
2186 msgid ""
2187 "In early file systems, the value returned by B<telldir>()  was a simple file "
2188 "offset within a directory.  Modern file systems use tree or hash structures, "
2189 "rather than flat tables, to represent directories.  On such file systems, "
2190 "the value returned by B<telldir>()  (and used internally by B<readdir>(3))  "
2191 "is a \"cookie\" that is used by the implementation to derive a position "
2192 "within a directory.  Application programs should treat this strictly as an "
2193 "opaque value, making I<no> assumptions about its contents."
2194 msgstr ""
2195 "初期のファイルシステムでは、 B<telldir>() が返す値は単なるディレクトリ内の"
2196 "ファイルオフセットであった。新しめのファイルシステムでは、ディレクトリを表現"
2197 "するのに、フラットなテーブルではなく、ツリーやハッシュ構造が使用されている。"
2198 "このようなファイルシステムでは、 B<telldir>() が返す値 (および B<readdir>(3) "
2199 "が内部で使用する値) は、ディレクトリ内での値を示すのにファイルシステム実装が"
2200 "使っている \"cookie\" となる。アプリケーションプログラムでは、必ずこの値を内"
2201 "容を意識せず単なる値として扱うべきであり、その内容について前提を持つべきでは"
2202 "「ない」。"
2203
2204 #. type: Plain text
2205 #: build/C/man3/telldir.3:97
2206 msgid ""
2207 "B<closedir>(3), B<opendir>(3), B<readdir>(3), B<rewinddir>(3), B<scandir>"
2208 "(3), B<seekdir>(3)"
2209 msgstr ""
2210 "B<closedir>(3), B<opendir>(3), B<readdir>(3), B<rewinddir>(3), B<scandir>"
2211 "(3), B<seekdir>(3)"
2212
2213 #~ msgid "2010-09-26"
2214 #~ msgstr "2010-09-26"
2215
2216 #~ msgid "2012-04-26"
2217 #~ msgstr "2012-04-26"
2218
2219 #~ msgid ""
2220 #~ "The B<scandir>()  function returns the number of directory entries "
2221 #~ "selected or -1 if an error occurs."
2222 #~ msgstr ""
2223 #~ "関数 B<scandir>()  は選択されたエントリの数か、 (エラーが発生した場合) -1 "
2224 #~ "を返す。"