OSDN Git Service

(split) LDP: Restore and add Copyrights for draft pages
[linuxjm/LDP_man-pages.git] / draft / man3 / fts.3
index 9c30ac4..70506ea 100644 (file)
@@ -3,6 +3,7 @@
 .\" Copyright (c) 1989, 1991, 1993, 1994
 .\"    The Regents of the University of California.  All rights reserved.
 .\"
+.\" %%%LICENSE_START(BSD_4_CLAUSE_UCB)
 .\" Redistribution and use in source and binary forms, with or without
 .\" modification, are permitted provided that the following conditions
 .\" are met:
 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
+.\" %%%LICENSE_END
 .\"
 .\"     @(#)fts.3      8.5 (Berkeley) 4/16/94
 .\"
 .\" 2007-12-08, mtk, Converted from mdoc to man macros
 .\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
 .\" Japanese Version Copyright (c) 2000 Yuichi SATO
 .\"         all rights reserved.
 .\" Translated Tue Jul 11 19:02:58 JST 2000
 .\"         by Yuichi SATO <sato@complex.eng.hokudai.ac.jp>
 .\"
-.\"WORD:       hierarchy               ³¬ÁØ
-.\"WORD:       traverse                ¤¿¤É¤ë
-.\"WORD:       pointer                 ¥Ý¥¤¥ó¥¿
-.\"WORD:       restore                 Éü¸µ¤¹¤ë
-.\"WORD:       null-terminated         NULL ½ªÃ¼¤µ¤ì¤¿
-.\"
-.TH FTS 3 2007-12-28 "Linux" "Linux Programmer's Manual"
-.\"O .SH NAME
-.SH Ì¾Á°
-.\"O fts, fts_open, fts_read, fts_children, fts_set, fts_close \- \
-.\"O traverse a file hierarchy
-fts, fts_open, fts_read, fts_children, fts_set, fts_close \- \
-¥Õ¥¡¥¤¥ë³¬Áؤò¤¿¤É¤ë
-.\"O .SH SYNOPSIS
-.SH ½ñ¼°
+.TH FTS 3 2012\-10\-25 Linux "Linux Programmer's Manual"
+.SH 名前
+fts, fts_open, fts_read, fts_children, fts_set, fts_close \- ファイル階層をたどる
+.SH 書式
 .nf
-.B #include <sys/types.h>
-.B #include <sys/stat.h>
-.B #include <fts.h>
+\fB#include <sys/types.h>\fP
+\fB#include <sys/stat.h>\fP
+\fB#include <fts.h>\fP
 .sp
-.BI "FTS *fts_open(char * const *" path_argv ", int " options ", "
-.BI "              int (*" compar ")(const FTSENT **, const FTSENT **));"
+\fBFTS *fts_open(char * const *\fP\fIpath_argv\fP\fB, int \fP\fIoptions\fP\fB, \fP
+\fB              int (*\fP\fIcompar\fP\fB)(const FTSENT **, const FTSENT **));\fP
 .sp
-.BI "FTSENT *fts_read(FTS *" ftsp );
+\fBFTSENT *fts_read(FTS *\fP\fIftsp\fP\fB);\fP
 .sp
-.BI "FTSENT *fts_children(FTS *" ftsp ", int " options );
+\fBFTSENT *fts_children(FTS *\fP\fIftsp\fP\fB, int \fP\fIoptions\fP\fB);\fP
 .sp
-.BI "int fts_set(FTS *" ftsp ", FTSENT *" f ", int " options );
+\fBint fts_set(FTS *\fP\fIftsp\fP\fB, FTSENT *\fP\fIf\fP\fB, int \fP\fIoptions\fP\fB);\fP
 .sp
-.BI "int fts_close(FTS *" ftsp );
+\fBint fts_close(FTS *\fP\fIftsp\fP\fB);\fP
 .fi
-.\"O .SH DESCRIPTION
-.SH ÀâÌÀ
-.\"O The
-.\"O fts functions are provided for traversing
-.\"O file hierarchies.
-.\"O A simple overview is that the
-.\"O .BR fts_open ()
-.\"O function returns a "handle" on a file hierarchy, which is then supplied to
-.\"O the other
-.\"O fts functions.
-fts ´Ø¿ô·²¤Ï¡¢¥Õ¥¡¥¤¥ë³¬Áؤò¤¿¤É¤ë¤¿¤á¤ËÄ󶡤µ¤ì¤Æ¤¤¤ë¡£
-´Êñ¤Ë³µÎ¬¤¹¤ë¤È¼¡¤Î¤è¤¦¤Ë¤Ê¤ë¡£
-.BR fts_open ()
-´Ø¿ô¤Ï¡¢Â¾¤Î fts ´Ø¿ô·²¤ËÅϤ¹¤¿¤á¤Î¡¢¥Õ¥¡¥¤¥ë³¬ÁؤΡ֥ϥó¥É¥ë¡×¤òÊÖ¤¹¡£
-.\"O The function
-.\"O .BR fts_read ()
-.\"O returns a pointer to a structure describing one of the files in the file
-.\"O hierarchy.
-.\"O The function
-.\"O .BR fts_children ()
-.\"O returns a pointer to a linked list of structures, each of which describes
-.\"O one of the files contained in a directory in the hierarchy.
-.\"O In general, directories are visited two distinguishable times; in preorder
-.\"O (before any of their descendants are visited) and in postorder (after all
-.\"O of their descendants have been visited).
-.\"O Files are visited once.
-.\"O It is possible to walk the hierarchy "logically" (ignoring symbolic links)
-.\"O or physically (visiting symbolic links), order the walk of the hierarchy or
-.\"O prune and/or revisit portions of the hierarchy.
-.BR fts_read ()
-´Ø¿ô¤Ï¡¢¥Õ¥¡¥¤¥ë³¬ÁØÃæ¤Ë¤¢¤ë 1 ¤Ä¤Î¥Õ¥¡¥¤¥ë¤òµ­½Ò¤¹¤ë¹½Â¤ÂΤؤΥݥ¤¥ó¥¿¤òÊÖ¤¹¡£
-.BR fts_children ()
-´Ø¿ô¤Ï¡¢³¬ÁØÃæ¤Î¥Ç¥£¥ì¥¯¥È¥ê¤Ë¤¢¤ë¥Õ¥¡¥¤¥ë¤òµ­½Ò¤¹¤ë¹½Â¤ÂΤÎ
-¥ê¥ó¥¯¥ê¥¹¥È¤Ø¤Î¥Ý¥¤¥ó¥¿¤òÊÖ¤¹¡£
-°ìÈ̤˥ǥ£¥ì¥¯¥È¥ê¤Ï¡¢
-preorder (ÀµÊý¸þ¡§²¼¤Î³¬ÁؤΥǥ£¥ì¥¯¥È¥ê¤ò¤¿¤É¤ëÁ°) ¤È
-postorder (µÕÊý¸þ¡§²¼¤Î³¬ÁؤΥǥ£¥ì¥¯¥È¥ê¤ò¤¹¤Ù¤Æ¤¿¤É¤Ã¤¿¸å) ¤È¤¤¤¦¡¢
-°Û¤Ê¤ëÊý¸þ¤Ç 2 ²ó¤¿¤É¤é¤ì¤ë¡£¥Õ¥¡¥¤¥ë¤Ï 1 ²ó¤¿¤É¤é¤ì¤ë¡£
-¥Ç¥£¥ì¥¯¥È¥ê³¬Áؤò¡ÖÏÀÍýŪ¤Ë¡×(¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥°¤ò̵»ë¤·¤Æ) °ÜÆ°¤¹¤ë¤³¤È¤â¡¢
-ʪÍýŪ¤Ë (¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤ò¤¿¤É¤Ã¤Æ) °ÜÆ°¤¹¤ë¤³¤È¤â²Äǽ¤Ç¤¢¤ë¡£
-¤Þ¤¿¡¢³¬ÁØÃæ¤Î°ÜÆ°¤ÎÆ»¶Ú¤ò»Ø¼¨¤¹¤ë¤³¤È¡¦
-;ʬ¤Ê¤â¤Î¤ò¼è¤ê½ü¤¯¤³¤È¡¦³¬ÁؤΰìÉô¤òºÆ¤Ó¤¿¤É¤ë¤³¤È¤¬²Äǽ¤Ç¤¢¤ë¡£
+.SH 説明
+fts 関数群は、ファイル階層をたどるために提供されている。 簡単に概略すると次のようになる。 \fBfts_open\fP()  関数は、他の fts
+関数群に渡すための、ファイル階層の「ハンドル」を返す。 \fBfts_read\fP()  関数は、ファイル階層中にある 1
+つのファイルを記述する構造体へのポインタを返す。 \fBfts_children\fP()  関数は、階層中のディレクトリにあるファイルを記述する構造体の
+リンクリストへのポインタを返す。 一般にディレクトリは、 preorder (正方向:下の階層のディレクトリをたどる前) と postorder
+(逆方向:下の階層のディレクトリをすべてたどった後) という、 異なる方向で 2 回たどられる。ファイルは 1 回たどられる。
+ディレクトリ階層を「論理的に」(シンボリックリングが指すファイルを見て) 辿ることも、 物理的に (シンボリックリンク自身を見て)
+辿ることも可能である。 また、階層中の移動の道筋を指示すること・ 余分なものを取り除くこと・階層の一部を再びたどることが可能である。
 .PP
-.\"O Two structures are defined (and typedef'd) in the include file
-.\"O .IR <fts.h> .
-.\"O The first is
-.\"O .IR FTS ,
-.\"O the structure that represents the file hierarchy itself.
-.\"O The second is
-.\"O .IR FTSENT ,
-.\"O the structure that represents a file in the file
-.\"O hierarchy.
-.\"O Normally, an
-.\"O .I FTSENT
-.\"O structure is returned for every file in the file
-.\"O hierarchy.
-.\"O In this manual page, "file" and
-.\"O "FTSENT structure"
-.\"O are generally interchangeable.
-.\"O The
-.\"O .I FTSENT
-.\"O structure contains at least the following fields, which are
-.\"O described in greater detail below:
-2 ¤Ä¤Î¹½Â¤ÂΤ¬¥¤¥ó¥¯¥ë¡¼¥É¥Õ¥¡¥¤¥ë
-.I <fts.h>
-¤ÇÄêµÁ¤µ¤ì¤Æ¤¤¤ë (¤µ¤é¤Ë typedef ¤µ¤ì¤Æ¤¤¤ë)¡£
-1 ¤ÄÌܤϡ¢¥Õ¥¡¥¤¥ë³¬Áؤ½¤Î¤â¤Î¤òɽ¸½¤¹¤ë
-.I FTS
-¹½Â¤ÂΤǤ¢¤ë¡£
-2 ¤ÄÌܤϡ¢¥Õ¥¡¥¤¥ë³¬ÁØÃæ¤Î¥Õ¥¡¥¤¥ë¤òɽ¸½¤¹¤ë
-.I FTSENT
-¹½Â¤ÂΤǤ¢¤ë¡£
-.I FTSENT
-¹½Â¤ÂΤÏÄ̾¥Õ¥¡¥¤¥ë³¬ÁØÃæ¤Î¤¹¤Ù¤Æ¤Î¥Õ¥¡¥¤¥ë¤ËÂФ·¤ÆÊÖ¤µ¤ì¤ë¡£
-¤³¤Î man ¥Ú¡¼¥¸¤Ç¤Ï¡¢¡Ö¥Õ¥¡¥¤¥ë¡×¤È
-.RI ¡Ö FTSENT
-¹½Â¤ÂΡפò°ìÈ̤ËÆɤßÊѤ¨¤ë¤³¤È¤¬¤Ç¤­¤ë¡£
-.I FTSENT
-¹½Â¤ÂΤϡ¢¾¯¤Ê¤¯¤È¤â¼¡¤Î¤è¤¦¤Ê¥Õ¥£¡¼¥ë¥É¤ò»ý¤Ã¤Æ¤ª¤ê¡¢
-°Ê²¼¤Ç¤è¤ê¾Ü¤·¤¯ÀâÌÀ¤µ¤ì¤Æ¤¤¤ë¡£
+2 つの構造体がインクルードファイル \fI<fts.h>\fP で定義されている (さらに typedef されている)。 1
+つ目は、ファイル階層そのものを表現する \fIFTS\fP 構造体である。 2 つ目は、ファイル階層中のファイルを表現する \fIFTSENT\fP 構造体である。
+\fIFTSENT\fP 構造体は通常、ファイル階層中のすべてのファイルに対して返される。 この man ページでは、「ファイル」と 「\fIFTSENT\fP
+構造体」を一般に読み変えることができる。 \fIFTSENT\fP 構造体は、少なくとも次のようなフィールドを持っており、 以下でより詳しく説明されている。
 .in +4n
 .nf
 
-.\"O typedef struct _ftsent {
-.\"O     unsigned short fts_info;     /* flags for FTSENT structure */
-.\"O     char          *fts_accpath;  /* access path */
-.\"O     char          *fts_path;     /* root path */
-.\"O     short          fts_pathlen;  /* strlen(fts_path) */
-.\"O     char          *fts_name;     /* filename */
-.\"O     short          fts_namelen;  /* strlen(fts_name) */
-.\"O     short          fts_level;    /* depth (\-1 to N) */
-.\"O     int            fts_errno;    /* file errno */
-.\"O     long           fts_number;   /* local numeric value */
-.\"O     void          *fts_pointer;  /* local address value */
-.\"O     struct ftsent *fts_parent;   /* parent directory */
-.\"O     struct ftsent *fts_link;     /* next file structure */
-.\"O     struct ftsent *fts_cycle;    /* cycle structure */
-.\"O     struct stat   *fts_statp;    /* stat(2) information */
-.\"O } FTSENT;
 typedef struct _ftsent {
-    unsigned short fts_info;     /* FTSENT ¹½Â¤ÂΤΤ¿¤á¤Î¥Õ¥é¥° */
-    char          *fts_accpath;  /* ¥¢¥¯¥»¥¹¥Ñ¥¹ */
-    char          *fts_path;     /* ¥ë¡¼¥È¥Ñ¥¹ */
-    short          fts_pathlen;  /* fts_path ¤ÎŤµ */
-    char          *fts_name;     /* ¥Õ¥¡¥¤¥ë̾ */
-    short          fts_namelen;  /* fts_name ¤ÎŤµ */
-    short          fts_level;    /* ¿¼¤µ (\-1 ¡Á N) */
-    int            fts_errno;    /* ¥Õ¥¡¥¤¥ë¤Î¥¨¥é¡¼ÈÖ¹æ */
-    long           fts_number;   /* ¥í¡¼¥«¥ë¤ÊÈÖ¹æ */
-    void          *fts_pointer;  /* ¥í¡¼¥«¥ë¤Ê¥¢¥É¥ì¥¹ÈÖ¹æ */
-    struct ftsent *fts_parent;   /* ¿Æ¥Ç¥£¥ì¥¯¥È¥ê */
-    struct ftsent *fts_link;     /* ¼¡¤Î¥Õ¥¡¥¤¥ë¹½Â¤ÂΠ*/
-    struct ftsent *fts_cycle;    /* ½Û´Ä¤·¤Æ¤¤¤ë¹½Â¤ÂΠ*/
-    struct stat   *fts_statp;    /* stat(2) ¤Î¾ðÊó */
+    unsigned short fts_info;     /* FTSENT æ§\8bé\80 ä½\93ã\81®ã\81\9fã\82\81ã\81®ã\83\95ã\83©ã\82° */
+    char          *fts_accpath;  /* ã\82¢ã\82¯ã\82»ã\82¹ã\83\91ã\82¹ */
+    char          *fts_path;     /* ã\83«ã\83¼ã\83\88ã\83\91ã\82¹ */
+    short          fts_pathlen;  /* fts_path の長さ */
+    char          *fts_name;     /* ファイル名 */
+    short          fts_namelen;  /* fts_name の長さ */
+    short          fts_level;    /* 深さ (\-1 〜 N) */
+    int            fts_errno;    /* ファイルのエラー番号 */
+    long           fts_number;   /* ローカルな番号 */
+    void          *fts_pointer;  /* ローカルなアドレス番号 */
+    struct ftsent *fts_parent;   /* 親ディレクトリ */
+    struct ftsent *fts_link;     /* 次のファイル構造体 */
+    struct ftsent *fts_cycle;    /* 循環している構造体 */
+    struct stat   *fts_statp;    /* stat(2) の情報 */
 } FTSENT;
 .fi
 .in
 .PP
-.\"O These fields are defined as follows:
-¤³¤ì¤é¤Î¥Õ¥£¡¼¥ë¥É¤Ï¡¢¼¡¤Î¤è¤¦¤ËÄêµÁ¤µ¤ì¤Æ¤¤¤ë¡£
 .\" .Bl -tag -width "fts_namelen"
-.TP 12
-.IR fts_info
-.\"O One of the following flags describing the returned
-.\"O .I FTSENT
-.\"O structure and
-.\"O the file it represents.
-.\"O With the exception of directories without errors
-.\"O .RB ( FTS_D ),
-.\"O all of these
-.\"O entries are terminal, that is, they will not be revisited, nor will any
-.\"O of their descendants be visited.
-¤³¤Î¥Õ¥£¡¼¥ë¥É¤Ï¡¢ÊÖ¤µ¤ì¤¿
-.I FTSENT
-¹½Â¤ÂΤȥե¡¥¤¥ë¤òÀâÌÀ¤¹¤ë°Ê²¼¤Î¥Õ¥é¥°¤Î¤¤¤º¤ì¤«¤òɽ¤·¤Æ¤¤¤ë¡£
-¥¨¥é¡¼¤Î¤Ê¤¤¥Ç¥£¥ì¥¯¥È¥ê
-.RB ( FTS_D ),
-¤Î¾ì¹ç¤ÏÎã³°¤È¤·¤Æ¡¢¤½¤ì°Ê³°¤Î¤¹¤Ù¤Æ¤Î¥¨¥ó¥È¥ê¤Ï½ªÃ¼¤Ç¤¢¤ë¡£
-¤Ä¤Þ¤ê¡¢¥¨¥ó¥È¥ê¤ÏºÆ¤Ó¤¿¤É¤é¤ì¤ë¤³¤È¤â¤Ê¤¯¡¢
-¤½¤ì¤è¤ê²¼¤Î³¬Áؤ¬¤¿¤É¤é¤ì¤ë¤³¤È¤â¤Ê¤¤¡£
+これらのフィールドは、次のように定義されている。
+.TP  12
+\fIfts_info\fP
 .\" .Bl  -tag -width FTS_DEFAULT
+このフィールドは、返された \fIFTSENT\fP 構造体とファイルを説明する以下のフラグのいずれかを表している。 エラーのないディレクトリ
+(\fBFTS_D\fP), の場合は例外として、それ以外のすべてのエントリは終端である。 つまり、エントリは再びたどられることもなく、
+それより下の階層がたどられることもない。
 .RS 12
-.TP 12
-.BR FTS_D
-.\"O A directory being visited in preorder.
-preorder ¤Ç¤¿¤É¤é¤ì¤ë¥Ç¥£¥ì¥¯¥È¥ê¡£
-.TP
-.BR FTS_DC
-.\"O A directory that causes a cycle in the tree.
-.\"O (The
-.\"O .I fts_cycle
-.\"O field of the
-.\"O .I FTSENT
-.\"O structure will be filled in as well.)
-¥Ä¥ê¡¼¤ÎÃæ¤Ç½Û´Ä¤·¤Æ¤¤¤ë¥Ç¥£¥ì¥¯¥È¥ê¡£
-.RI ( FTSENT
-¹½Â¤ÂΤÎ
-.I fts_cycle
-¥Õ¥£¡¼¥ë¥É¤âƱÍͤËËä¤á¤é¤ì¤ë¡£)
-.TP
-.BR FTS_DEFAULT
-.\"O Any
-.\"O .I FTSENT
-.\"O structure that represents a file type not explicitly described
-.\"O by one of the other
-.\"O .I fts_info
-.\"O values.
-¥Õ¥¡¥¤¥ë¥¿¥¤¥×¤òɽ¸½¤¹¤ë
-.I FTSENT
-¹½Â¤ÂΤ¬¡¢
-.I fts_info
-¤Î¾¤Î¤¤¤º¤ì¤«¤ÎÃͤÇÌÀ¼¨Åª¤ËÀâÌÀ¤µ¤ì¤Æ¤¤¤Ê¤¤¡£
-.TP
-.BR FTS_DNR
-.\"O A directory which cannot be read.
-.\"O This is an error return, and the
-.\"O .I fts_errno
-.\"O field will be set to indicate what caused the error.
-Æɤ߹þ¤ß¤¬¤Ç¤­¤Ê¤¤¥Ç¥£¥ì¥¯¥È¥ê¡£
-¤³¤ì¤Ï¥¨¥é¡¼¤Î¾ì¹ç¤ÎÊÖ¤êÃͤǤ¢¤ê¡¢
-²¿¤¬¥¨¥é¡¼¤òµ¯¤³¤·¤¿¤«¤ò¼¨¤¹¤¿¤á¤Ë
-.I fts_errno
-¥Õ¥£¡¼¥ë¥É¤¬ÀßÄꤵ¤ì¤ë¡£
-.TP
-.BR FTS_DOT
-.\"O A file named
-.\"O "."
-.\"O or
-.\"O ".."
-.\"O which was not specified as a filename to
-.\"O .BR fts_open ()
-.\"O (see
-.\"O .BR FTS_SEEDOT ).
-.BR fts_open ()
-¤Ø¤Î¥Õ¥¡¥¤¥ë̾¤È¤·¤Æ»ØÄꤵ¤ì¤Ê¤«¤Ã¤¿
-"." ¤Þ¤¿¤Ï ".."
-¤È¤¤¤¦Ì¾Á°¤Î¥Õ¥¡¥¤¥ë
-.RB ( FTS_SEEDOT
-¤ò»²¾È¤¹¤ë¤³¤È)¡£
-.TP
-.BR FTS_DP
-.\"O A directory being visited in postorder.
-.\"O The contents of the
-.\"O .I FTSENT
-.\"O structure will be unchanged from when
-.\"O it was returned in preorder, that is, with the
-.\"O .I fts_info
-.\"O field set to
-.\"O .BR FTS_D .
-postorder ¤Ç¤¿¤É¤é¤ì¤ë¥Ç¥£¥ì¥¯¥È¥ê¡£
-.I FTSENT
-¹½Â¤ÂΤÎÆâÍƤϡ¢preorder ¤Î¤È¤­¤ËÊÖ¤µ¤ì¤¿¾õÂÖ
-(¤Ä¤Þ¤ê¡¢
-.I fts_info
-¥Õ¥£¡¼¥ë¥É¤¬
-.B FTS_D
-¤ËÀßÄꤵ¤ì¤Æ¤¤¤ë¾õÂÖ) ¤«¤éÊѹ¹¤µ¤ì¤Ê¤¤¡£
-.TP
-.B FTS_ERR
-.\"O This is an error return, and the
-.\"O .I fts_errno
-.\"O field will be set to indicate what caused the error.
-¤³¤ì¤Ï¥¨¥é¡¼¤Î¾ì¹ç¤ÎÊÖ¤êÃͤǤ¢¤ê¡¢
-.I fts_errno
-¥Õ¥£¡¼¥ë¥É¤Ï¡¢²¿¤¬¥¨¥é¡¼¤òµ¯¤³¤·¤¿¤«¤ò¼¨¤¹ÃͤËÀßÄꤵ¤ì¤ë¡£
-.TP
-.B FTS_F
-.\"O A regular file.
-Ä̾ï¤Î¥Õ¥¡¥¤¥ë¡£
-.TP
-.B FTS_NS
-.\"O A file for which no
-.\"O .BR stat (2)
-.\"O information was available.
-.\"O The contents of the
-.\"O .I fts_statp
-.\"O field are undefined.
-.\"O This is an error return, and the
-.\"O .I fts_errno
-.\"O field will be set to indicate what caused the error.
-.BR stat (2)
-¾ðÊó¤¬ÆÀ¤é¤ì¤Ê¤«¤Ã¤¿¥Õ¥¡¥¤¥ë¡£
-.I fts_statp
-¥Õ¥£¡¼¥ë¥É¤ÎÆâÍƤÏÄêµÁ¤µ¤ì¤Ê¤¤¡£
-¤³¤ì¤Ï¥¨¥é¡¼¤Î¾ì¹ç¤ÎÊÖ¤êÃͤǤ¢¤ê¡¢
-.I fts_errno
-¥Õ¥£¡¼¥ë¥É¤Ï¡¢²¿¤¬¥¨¥é¡¼¤òµ¯¤³¤·¤¿¤«¤ò¼¨¤¹ÃͤËÀßÄꤵ¤ì¤ë¡£
-.TP
-.B FTS_NSOK
-.\"O A file for which no
-.\"O .BR stat (2)
-.\"O information was requested.
-.\"O The contents of the
-.\"O .I fts_statp
-.\"O field are undefined.
-.BR stat (2)
-¾ðÊó¤¬Í׵ᤵ¤ì¤Ê¤«¤Ã¤¿¥Õ¥¡¥¤¥ë¡£
-.I fts_statp
-¥Õ¥£¡¼¥ë¥É¤ÎÆâÍƤÏÄêµÁ¤µ¤ì¤Ê¤¤¡£
-.TP
-.B FTS_SL
-.\"O A symbolic link.
-¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¡£
-.TP
-.B FTS_SLNONE
-.\"O A symbolic link with a non-existent target.
-.\"O The contents of the
-.\"O .I fts_statp
-.\"O field reference the file characteristic information for the symbolic link
-.\"O itself.
-¥ê¥ó¥¯Àè¤Î¸ºß¤·¤Ê¤¤¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¡£
-.I fts_statp
-¥Õ¥£¡¼¥ë¥É¤ÎÆâÍƤϡ¢¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤½¤Î¤â¤Î¤Î¥Õ¥¡¥¤¥ëÆÃÀ­¾ðÊó¤ò»²¾È¤¹¤ë¡£
+.TP  12
+\fBFTS_D\fP
+preorder でたどられるディレクトリ。
+.TP 
+\fBFTS_DC\fP
+ツリーの中で循環しているディレクトリ。 (\fIFTSENT\fP 構造体の \fIfts_cycle\fP フィールドも同様に埋められる。)
+.TP 
+\fBFTS_DEFAULT\fP
+ファイルタイプを表現する \fIFTSENT\fP 構造体が、 \fIfts_info\fP の他のいずれかの値で明示的に説明されていない。
+.TP 
+\fBFTS_DNR\fP
+読み込みができないディレクトリ。 これはエラーの場合の返り値であり、 何がエラーを起こしたかを示すために \fIfts_errno\fP
+フィールドが設定される。
+.TP 
+\fBFTS_DOT\fP
+\fBfts_open\fP()  へのファイル名として指定されなかった "." または ".." という名前のファイル (\fBFTS_SEEDOT\fP
+を参照すること)。
+.TP 
+\fBFTS_DP\fP
+postorder でたどられるディレクトリ。 \fIFTSENT\fP 構造体の内容は、preorder のときに返された状態 (つまり、
+\fIfts_info\fP フィールドが \fBFTS_D\fP に設定されている状態) から変更されない。
+.TP 
+\fBFTS_ERR\fP
+これはエラーの場合の返り値であり、 \fIfts_errno\fP フィールドは、何がエラーを起こしたかを示す値に設定される。
+.TP 
+\fBFTS_F\fP
+通常のファイル。
+.TP 
+\fBFTS_NS\fP
+\fBstat\fP(2)  情報が得られなかったファイル。 \fIfts_statp\fP フィールドの内容は定義されない。 これはエラーの場合の返り値であり、
+\fIfts_errno\fP フィールドは、何がエラーを起こしたかを示す値に設定される。
+.TP 
+\fBFTS_NSOK\fP
+\fBstat\fP(2)  情報が要求されなかったファイル。 \fIfts_statp\fP フィールドの内容は定義されない。
+.TP 
+\fBFTS_SL\fP
+シンボリックリンク。
+.TP 
+\fBFTS_SLNONE\fP
 .\" .El
+リンク先の存在しないシンボリックリンク。 \fIfts_statp\fP フィールドの内容は、シンボリックリンクそのもののファイル特性情報を参照する。
 .RE
-.TP
-.IR fts_accpath
-.\"O A path for accessing the file from the current directory.
-¸½ºß¤Î¥Ç¥£¥ì¥¯¥È¥ê¤«¤é¥Õ¥¡¥¤¥ë¤Ë¥¢¥¯¥»¥¹¤¹¤ë¤¿¤á¤Î¥Ñ¥¹¡£
-.TP
-.IR fts_path
-.\"O The path for the file relative to the root of the traversal.
-.\"O This path contains the path specified to
-.\"O .BR fts_open ()
-.\"O as a prefix.
-³¬Áؤò¤¿¤É¤ë¤È¤­¤Î¥ë¡¼¥È¤«¤é¤ß¤¿¥Õ¥¡¥¤¥ë¤ÎÁêÂÐŪ¤Ê¥Ñ¥¹¡£
-¤³¤Î¥Ñ¥¹¤Ë¤Ï¡¢
-.BR fts_open ()
-¤Ë»ØÄꤷ¤¿¥Ñ¥¹¤¬¥×¥ì¥Õ¥£¥Ã¥¯¥¹¤È¤·¤Æ´Þ¤Þ¤ì¤ë¡£
-.TP
-.IR fts_pathlen
-.\"O The length of the string referenced by
-.\"O .IR fts_path .
-.I fts_path
-¤Ç»²¾È¤µ¤ì¤ëʸ»úÎó¤ÎŤµ¡£
-.TP
-.IR fts_name
-.\"O The name of the file.
-¥Õ¥¡¥¤¥ë¤Î̾Á°¡£
-.TP
-.IR fts_namelen
-.\"O The length of the string referenced by
-.\"O .IR fts_name .
-.I fts_name
-¤Ç»²¾È¤µ¤ì¤ëʸ»úÎó¤ÎŤµ¡£
-.TP
-.IR fts_level
-.\"O The depth of the traversal, numbered from \-1 to N, where this file
-.\"O was found.
-.\"O The
-.\"O .I FTSENT
-.\"O structure representing the parent of the starting point (or root)
-.\"O of the traversal is numbered \-1, and the
-.\"O .I FTSENT
-.\"O structure for the root
-.\"O itself is numbered 0.
-³¬Áؤò¤¿¤É¤Ã¤Æ¡¢¤³¤Î¥Õ¥¡¥¤¥ë¤¬¤ß¤Ä¤«¤Ã¤¿¿¼¤µ¡£
-\-1 ¡Á N ¤Î¿ôÃͤÇɽ¤µ¤ì¤ë¡£
-³¬Áؤò¤¿¤É¤ë¤È¤­¤Î½ÐȯÅÀ (¥ë¡¼¥È) ¤Î¿Æ¥Ç¥£¥ì¥¯¥È¥ê¤òɽ¤¹
-.I FTSENT
-¹½Â¤ÂΤǤϠ\-1 ¤È¤Ê¤ë¡£
-¤Þ¤¿¡¢¥ë¡¼¥È¼«¿È¤Î
-.I FTSENT
-¹½Â¤ÂΤǤϠ0 ¤Ë¤Ê¤ë¡£
-.TP
-.IR fts_errno
-.\"O Upon return of a
-.\"O .I FTSENT
-.\"O structure from the
-.\"O .BR fts_children ()
-.\"O or
-.\"O .BR fts_read ()
-.\"O functions, with its
-.\"O .I fts_info
-.\"O field set to
-.\"O .BR FTS_DNR ,
-.\"O .B FTS_ERR
-.\"O or
-.\"O .BR FTS_NS ,
-.\"O the
-.\"O .I fts_errno
-.\"O field contains the value of the external variable
-.\"O .I errno
-.\"O specifying the cause of the error.
-.\"O Otherwise, the contents of the
-.\"O .I fts_errno
-.\"O field are undefined.
-´Ø¿ô
-.BR fts_children ()
-¤È
-.BR fts_read ()
-¤«¤éÊÖ¤µ¤ì¤ë
-.I FTSENT
-¹½Â¤ÂΤÎ
-.I fts_info
-¥Õ¥£¡¼¥ë¥É¤¬
-.BR FTS_DNR ,
-.BR FTS_ERR ,
-.B FTS_NS
-¤ËÀßÄꤵ¤ì¤Æ¤¤¤ë¾ì¹ç¡¢
-.I fts_errno
-¥Õ¥£¡¼¥ë¥É¤Ë¤Ï¥¨¥é¡¼¤Î¸¶°ø¤ò¼¨¤¹³°ÉôÊÑ¿ô
-.I errno
-¤ÎÃͤ¬Æþ¤ë¡£
-¤½¤ì°Ê³°¤Î¾ì¹ç¡¢
-.I fts_errno
-¥Õ¥£¡¼¥ë¥É¤ÎÆâÍƤÏÄêµÁ¤µ¤ì¤Ê¤¤¡£
-.TP
-.IR fts_number
-.\"O This field is provided for the use of the application program and is
-.\"O not modified by the
-.\"O fts functions.
-.\"O It is initialized to 0.
-¤³¤Î¥Õ¥£¡¼¥ë¥É¤Ï¡¢¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¥×¥í¥°¥é¥à¤«¤é»ÈÍѤ¹¤ë¤¿¤á¤ËÄ󶡤µ¤ì¡¢
-fts ´Ø¿ô·²¤Ç¤ÏÊѹ¹¤µ¤ì¤Ê¤¤¡£
-¤³¤Î¥Õ¥£¡¼¥ë¥É¤Ï 0 ¤Ç½é´ü²½¤µ¤ì¤ë¡£
-.TP
-.IR fts_pointer
-.\"O This field is provided for the use of the application program and is
-.\"O not modified by the
-.\"O fts functions.
-.\"O It is initialized to
-.\"O .BR NULL .
-¤³¤Î¥Õ¥£¡¼¥ë¥É¤Ï¡¢¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¥×¥í¥°¥é¥à¤«¤é»ÈÍѤ¹¤ë¤¿¤á¤ËÄ󶡤µ¤ì¡¢
-fts ´Ø¿ô·²¤Ç¤ÏÊѹ¹¤µ¤ì¤Ê¤¤¡£
-¤³¤Î¥Õ¥£¡¼¥ë¥É¤Ï
-.B NULL
-¤Ç½é´ü²½¤µ¤ì¤ë¡£
-.TP
-.IR fts_parent
-.\"O A pointer to the
-.\"O .I FTSENT
-.\"O structure referencing the file in the hierarchy
-.\"O immediately above the current file, that is, the directory of which this
-.\"O file is a member.
-.\"O A parent structure for the initial entry point is provided as well,
-.\"O however, only the
-.\"O .IR fts_level ,
-.\"O .I fts_number
-.\"O and
-.\"O .I fts_pointer
-.\"O fields are guaranteed to be initialized.
-¸½ºß¤Î¥Õ¥¡¥¤¥ë¤Î¤¹¤°¾å¤Î³¬Áؤˤ¢¤ë¥Õ¥¡¥¤¥ë
-(¤Ä¤Þ¤ê¡¢¸½ºß¤Î¥Õ¥¡¥¤¥ë¤¬¥á¥ó¥Ð¡¼¤Ë¤Ê¤Ã¤Æ¤¤¤ë¥Ç¥£¥ì¥¯¥È¥ê) ¤ò»²¾È¤¹¤ë
-.I FTSENT
-¹½Â¤ÂΤؤΥݥ¤¥ó¥¿¡£
-ºÇ½é¤Î½ÐȯÅÀ¤ËÂФ·¤Æ¤â¡¢¿Æ¤È¤Ê¤ë¹½Â¤ÂΤÏÍ¿¤¨¤é¤ì¤ë¡£
-¤·¤«¤·¡¢
-.IR fts_level ,
-.IR fts_number ,
-.I fts_pointer
-¥Õ¥£¡¼¥ë¥É¤Î¤ß¤Î½é´ü²½¤·¤«Êݾڤµ¤ì¤Ê¤¤¡£
-.TP
-.IR fts_link
-.\"O Upon return from the
-.\"O .BR fts_children ()
-.\"O function, the
-.\"O .I fts_link
-.\"O field points to the next structure in the NULL-terminated linked list of
-.\"O directory members.
-.\"O Otherwise, the contents of the
-.\"O .I fts_link
-.\"O field are undefined.
-.BR fts_children ()
-¤«¤éÊÖ¤µ¤ì¤ë¾ì¹ç¡¢
-.I fts_link
-¥Õ¥£¡¼¥ë¥É¤Ï¥Ç¥£¥ì¥¯¥È¥ê¥á¥ó¥Ð¡¼¤Î NUL ½ªÃ¼¤µ¤ì¤¿¥ê¥ó¥¯¥ê¥¹¥È¤Î·Á¼°¤Ç¡¢
-¼¡¤Î¹½Â¤ÂΤò»Ø¤·¼¨¤¹¡£
-¤½¤ì°Ê³°¤Î¾ì¹ç¡¢
-.I fts_link
-¥Õ¥£¡¼¥ë¥É¤ÏÄêµÁ¤µ¤ì¤Ê¤¤¡£
-.TP
-.IR fts_cycle
-.\"O If a directory causes a cycle in the hierarchy (see
-.\"O .BR FTS_DC ),
-.\"O either because
-.\"O of a hard link between two directories, or a symbolic link pointing to a
-.\"O directory, the
-.\"O .I fts_cycle
-.\"O field of the structure will point to the
-.\"O .I FTSENT
-.\"O structure in the hierarchy that references the same file as the current
-.\"O .I FTSENT
-.\"O structure.
-.\"O Otherwise, the contents of the
-.\"O .I fts_cycle
-.\"O field are undefined.
-2 ¤Ä¤Î¥Ç¥£¥ì¥¯¥È¥ê¤Ë¥Ï¡¼¥É¥ê¥ó¥¯¤¬Ä¥¤é¤ì¤Æ¤¤¤ë¤¿¤á¡¢
-¤Þ¤¿¤Ï¡¢¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤¬¤¢¤ë¥Ç¥£¥ì¥¯¥È¥ê¤ò»Ø¤·¤Æ¤¤¤ë¤¿¤á¤Ë¡¢
-¥Ç¥£¥ì¥¯¥È¥ê¤¬½Û´Ä¤¹¤ë³¬Áع½Â¤¤òºî¤Ã¤Æ¤¤¤ë¾ì¹ç
-.RB ( FTS_DC
-¤ò»²¾È)¡¢
-¹½Â¤ÂΤÎ
-.I fts_cycle
-¥Õ¥£¡¼¥ë¥É¤Ï¡¢³¬ÁØÃæ¤Ç¸½ºß¤Î
-.I FTSENT
-¹½Â¤ÂΤÈƱ¤¸¥Õ¥¡¥¤¥ë¤ò»²¾È¤·¤Æ¤¤¤ë
-.I FTSENT
-¹½Â¤ÂΤò»Ø¤·¼¨¤¹¡£
-¤½¤ì°Ê³°¤Î¾ì¹ç¡¢
-.I fts_cycle
-¥Õ¥£¡¼¥ë¥É¤ÏÄêµÁ¤µ¤ì¤Ê¤¤¡£
-.TP
-.IR fts_statp
-.\"O A pointer to
-.\"O .BR stat (2)
-.\"O information for the file.
-¤³¤Î¥Õ¥¡¥¤¥ë¤Î
-.BR stat (2)
-¾ðÊó¤Ø¤Î¥Ý¥¤¥ó¥¿¡£
+.TP 
+\fIfts_accpath\fP
+現在のディレクトリからファイルにアクセスするためのパス。
+.TP 
+\fIfts_path\fP
+階層をたどるときのルートからみたファイルの相対的なパス。 このパスには、 \fBfts_open\fP()  に指定したパスがプレフィックスとして含まれる。
+.TP 
+\fIfts_pathlen\fP
+\fIfts_path\fP で参照される文字列の長さ。
+.TP 
+\fIfts_name\fP
+ファイルの名前。
+.TP 
+\fIfts_namelen\fP
+\fIfts_name\fP で参照される文字列の長さ。
+.TP 
+\fIfts_level\fP
+階層をたどって、このファイルがみつかった深さ。 \-1 〜 N の数値で表される。 階層をたどるときの出発点 (ルート) の親ディレクトリを表す
+\fIFTSENT\fP 構造体では \-1 となる。 また、ルート自身の \fIFTSENT\fP 構造体では 0 になる。
+.TP 
+\fIfts_errno\fP
+関数 \fBfts_children\fP()  と \fBfts_read\fP()  から返される \fIFTSENT\fP 構造体の \fIfts_info\fP
+フィールドが \fBFTS_DNR\fP, \fBFTS_ERR\fP, \fBFTS_NS\fP に設定されている場合、 \fIfts_errno\fP
+フィールドにはエラーの原因を示す外部変数 \fIerrno\fP の値が入る。 それ以外の場合、 \fIfts_errno\fP フィールドの内容は定義されない。
+.TP 
+\fIfts_number\fP
+このフィールドは、アプリケーションプログラムから使用するために提供され、 fts 関数群では変更されない。 このフィールドは 0 で初期化される。
+.TP 
+\fIfts_pointer\fP
+このフィールドは、アプリケーションプログラムから使用するために提供され、 fts 関数群では変更されない。 このフィールドは \fBNULL\fP
+で初期化される。
+.TP 
+\fIfts_parent\fP
+現在のファイルのすぐ上の階層にあるファイル (つまり、現在のファイルがメンバーになっているディレクトリ) を参照する \fIFTSENT\fP
+構造体へのポインタ。 最初の出発点に対しても、親となる構造体は与えられる。 しかし、 \fIfts_level\fP, \fIfts_number\fP,
+\fIfts_pointer\fP フィールドのみの初期化しか保証されない。
+.TP 
+\fIfts_link\fP
+\fBfts_children\fP()  から返される場合、 \fIfts_link\fP フィールドはディレクトリメンバーの NUL
+終端されたリンクリストの形式で、 次の構造体を指し示す。 それ以外の場合、 \fIfts_link\fP フィールドは定義されない。
+.TP 
+\fIfts_cycle\fP
+2 つのディレクトリにハードリンクが張られているため、 または、シンボリックリンクがあるディレクトリを指しているために、
+ディレクトリが循環する階層構造を作っている場合 (\fBFTS_DC\fP を参照)、 構造体の \fIfts_cycle\fP フィールドは、階層中で現在の
+\fIFTSENT\fP 構造体と同じファイルを参照している \fIFTSENT\fP 構造体を指し示す。 それ以外の場合、 \fIfts_cycle\fP
+フィールドは定義されない。
+.TP 
+\fIfts_statp\fP
 .\" .El
+このファイルの \fBstat\fP(2)  情報へのポインタ。
 .PP
-.\"O A single buffer is used for all of the paths of all of the files in the
-.\"O file hierarchy.
-.\"O Therefore, the
-.\"O .I fts_path
-.\"O and
-.\"O .I fts_accpath
-.\"O fields are guaranteed to be
-.\"O null-terminated
-.\"O .I only
-.\"O for the file most recently returned by
-.\"O .BR fts_read ().
-.\"O To use these fields to reference any files represented by other
-.\"O .I FTSENT
-.\"O structures will require that the path buffer be modified using the
-.\"O information contained in that
-.\"O .I FTSENT
-.\"O structure's
-.\"O .I fts_pathlen
-.\"O field.
-.\"O Any such modifications should be undone before further calls to
-.\"O .BR fts_read ()
-.\"O are attempted.
-.\"O The
-.\"O .I fts_name
-.\"O field is always
-.\"O null-terminated.
-¥Õ¥¡¥¤¥ë³¬ÁØÃæ¤Î¤¹¤Ù¤Æ¤Î¥Õ¥¡¥¤¥ë¤Î¥Ñ¥¹¤ËÂФ·¤Æ¡¢
-¤¿¤À 1 ¤Ä¤Î¥Ð¥Ã¥Õ¥¡¡¼¤¬»È¤ï¤ì¤ë¡£
-¤·¤¿¤¬¤Ã¤Æ¡¢
-.I fts_path
-¤È
-.I fts_accpath
-¥Õ¥£¡¼¥ë¥É¤Ï¡¢
-.BR fts_read ()
-¤Ë¤è¤Ã¤ÆÊÖ¤µ¤ì¤¿ºÇ¤â¿·¤·¤¤¥Õ¥¡¥¤¥ë¤ËÂФ·¤Æ¡Ö¤Î¤ß¡×
-NULL ½ªÃ¼¤µ¤ì¤ë¤³¤È¤¬Êݾڤµ¤ì¤ë¡£
-¤³¤ì¤é¤Î¥Õ¥£¡¼¥ë¥É¤ò¡¢Â¾¤Î
-.I FTSENT
-¹½Â¤ÂΤÇɽ¸½¤µ¤ì¤ë¥Õ¥¡¥¤¥ë¤ò»²¾È¤¹¤ë¤¿¤á¤Ë»È¤¦¤Ë¤Ï¡¢
-.I FTSENT
-¹½Â¤ÂΤÎ
-.I fts_pathlen
-¥Õ¥£¡¼¥ë¥É¤Ë¤¢¤ë¾ðÊó¤ò»È¤Ã¤Æ¥Ñ¥¹¤Î¥Ð¥Ã¥Õ¥¡¡¼¤ò½¤Àµ¤¹¤ëɬÍפ¬¤¢¤ë¡£
-¤³¤ì¤é¤Î½¤Àµ¤Ï¡¢¤µ¤é¤Ë
-.BR fts_read ()
-¤ò¸Æ¤Ó½Ð¤½¤¦¤È¤¹¤ë¾ì¹ç¤Ë¤Ï¡¢¸µ¤ËÌᤷ¤Æ¤ª¤«¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
-.I fts_name
-¥Õ¥£¡¼¥ë¥É¤Ï¡¢¾ï¤Ë
-.B NUL
-½ªÃ¼¤µ¤ì¤ë¡£
+ファイル階層中のすべてのファイルのパスに対して、 ただ 1 つのバッファーが使われる。 したがって、 \fIfts_path\fP と
+\fIfts_accpath\fP フィールドは、 \fBfts_read\fP()  によって返された最も新しいファイルに対して「のみ」 NULL
+終端されることが保証される。 これらのフィールドを、他の \fIFTSENT\fP 構造体で表現されるファイルを参照するために使うには、 \fIFTSENT\fP
+構造体の \fIfts_pathlen\fP フィールドにある情報を使ってパスのバッファーを修正する必要がある。 これらの修正は、さらに
+\fBfts_read\fP()  を呼び出そうとする場合には、元に戻しておかなければならない。 \fIfts_name\fP フィールドは、常に \fBNUL\fP
+終端される。
 .SS fts_open()
-.\"O The
-.\"O .BR fts_open ()
-.\"O function takes a pointer to an array of character pointers naming one
-.\"O or more paths which make up a logical file hierarchy to be traversed.
-.\"O The array must be terminated by a
-.\"O .B NULL
-.\"O pointer.
-.BR fts_open ()
-´Ø¿ô¤Ï¡¢Ê¸»úÎó¥Ý¥¤¥ó¥¿¤ÎÇÛÎó¤Ø¤Î¥Ý¥¤¥ó¥¿¤ò°ú¤­¿ô¤Ë¼è¤ë¡£
-¤³¤Îʸ»úÎó¥Ý¥¤¥ó¥¿¤Ï¡¢ÏÀÍý¥Õ¥¡¥¤¥ë³¬Áؤò¤Ä¤¯¤ë 1 ¤Ä°Ê¾å¤Î¥Ñ¥¹¤Î̾Á°¤Ë¤Ê¤ë¡£
-ÇÛÎó¤Ï¡¢
-.B NULL
-¥Ý¥¤¥ó¥¿¤Ç½ªÃ¼¤µ¤ì¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
+\fBfts_open\fP()  関数は、文字列ポインタの配列へのポインタを引き数に取る。 この文字列ポインタは、論理ファイル階層をつくる 1
+つ以上のパスの名前になる。 配列は、 \fBNULL\fP ポインタで終端されなければならない。
 .PP
-.\"O There are
-.\"O a number of options, at least one of which (either
-.\"O .B FTS_LOGICAL
-.\"O or
-.\"O .BR FTS_PHYSICAL )
-.\"O must be specified.
-.\"O The options are selected by ORing
-.\"O the following values:
-¿¤¯¤Î¥ª¥×¥·¥ç¥ó¤¬¤¢¤ê¡¢¾¯¤Ê¤¯¤È¤â 1 ¤Ä
-.RB ( FTS_LOGICAL
-¤Þ¤¿¤Ï
-.BR FTS_PHYSICAL )
-¤¬»ØÄꤵ¤ì¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
-¥ª¥×¥·¥ç¥ó¤Ï°Ê²¼¤ÎÃͤÎÏÀÍýϤò¤È¤Ã¤ÆÁªÂò¤¹¤ë¡£
 .\" .Bl -tag -width "FTS_PHYSICAL"
-.TP
-.B FTS_COMFOLLOW
-.\"O This option causes any symbolic link specified as a root path to be
-.\"O followed immediately whether or not
-.\"O .B FTS_LOGICAL
-.\"O is also specified.
-¤³¤Î¥ª¥×¥·¥ç¥ó¤Ï¡¢
-.B FTS_LOGICAL
-¤Î»ØÄê¤Ë¤«¤«¤ï¤é¤º¡¢
-¥ë¡¼¥È¥Ñ¥¹¤Ë»ØÄꤵ¤ì¤¿¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤ò¤¹¤°¤Ë¤¿¤É¤é¤»¤ë¡£
-.TP
-.B FTS_LOGICAL
-.\"O This option causes the
-.\"O fts routines to return
-.\"O .I FTSENT
-.\"O structures for the targets of symbolic links
-.\"O instead of the symbolic links themselves.
-.\"O If this option is set, the only symbolic links for which
-.\"O .I FTSENT
-.\"O structures
-.\"O are returned to the application are those referencing non-existent files.
-.\"O Either
-.\"O .B FTS_LOGICAL
-.\"O or
-.\"O .B FTS_PHYSICAL
-.\"O .I must
-.\"O be provided to the
-.\"O .BR fts_open ()
-.\"O function.
-¤³¤Î¥ª¥×¥·¥ç¥ó¤Ï¡¢
-fts ¥ë¡¼¥Á¥ó¤Ë¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤½¤Î¤â¤Î¤Ç¤Ï¤Ê¤¯¡¢
-¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤¬»Ø¤·¤Æ¤¤¤ë¥Õ¥¡¥¤¥ë¤Î
-.I FTSENT
-¹½Â¤ÂΤòÊÖ¤µ¤»¤ë¡£
-¤³¤Î¥ª¥×¥·¥ç¥ó¤¬ÀßÄꤵ¤ì¤¿¾ì¹ç¡¢
-.I FTSENT
-¹½Â¤ÂΤ¬¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤ËÊÖ¤µ¤ì¤ë¤è¤¦¤Ê
-¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤Î¤ß¤¬¡¢Â¸ºß¤·¤Ê¤¤¥Õ¥¡¥¤¥ë¤ò»²¾È¤·¤Æ¤¤¤ë¡£
-.B FTS_LOGICAL
-¤Þ¤¿¤Ï
-.B FTS_PHYSICAL
-¤Î¤É¤Á¤é¤«¤ò¡¢
-.BR fts_open ()
-´Ø¿ô¤ËÍ¿¤¨¤Ê¤±¤ì¤Ð¡Ö¤Ê¤é¤Ê¤¤¡×¡£
-.TP
-.B FTS_NOCHDIR
-.\"O As a performance optimization, the
-.\"O fts functions change directories as they walk the file hierarchy.
-.\"O This has the side-effect that an application cannot rely on being
-.\"O in any particular directory during the traversal.
-.\"O The
-.\"O .B FTS_NOCHDIR
-.\"O option turns off this optimization, and the
-.\"O fts functions will not change the current directory.
-.\"O Note that applications should not themselves change their current directory
-.\"O and try to access files unless
-.\"O .B FTS_NOCHDIR
-.\"O is specified and absolute
-.\"O pathnames were provided as arguments to
-.\"O .BR fts_open ().
-¥Ñ¥Õ¥©¡¼¥Þ¥ó¥¹¤ÎºÇŬ²½¤Î¤¿¤á¡¢
-fts ´Ø¿ô·²¤Ï¥Õ¥¡¥¤¥ë³¬Áؤò¤¿¤É¤ë¤È¤­¥Ç¥£¥ì¥¯¥È¥ê¤òÊѤ¨¤ë¡£
-¤³¤ì¤Ë¤Ï¡¢³¬Áؤò¤¿¤É¤Ã¤Æ¤¤¤ë´Ö¤Ï
-¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤¬¤¢¤ëÆÃÄê¤Î¥Ç¥£¥ì¥¯¥È¥ê¤Ë¤¤¤ë¤È¤¤¤¦¤³¤È¤Ë
-°Í¸¤Ç¤­¤Ê¤¤¡¢¤È¤¤¤¦ÉûºîÍѤ¬¤¢¤ë¡£
-.B FTS_NOCHDIR
-¥ª¥×¥·¥ç¥ó¤ÇºÇŬ²½¤ò̵¸ú¤Ë¤¹¤ë¤È¡¢
-fts ´Ø¿ô·²¤Ï¸½ºß¤Î¥Ç¥£¥ì¥¯¥È¥ê¤òÊѹ¹¤·¤Ê¤¤¡£
-.B FTS_NOCHDIR
-¤¬»ØÄꤵ¤ì¡¢¤«¤Ä
-.BR fts_open ()
-¤Î°ú¤­¿ô¤È¤·¤ÆÀäÂХѥ¹Ì¾¤¬Í¿¤¨¤é¤ì¤¿¤È¤­°Ê³°¡¢¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤Ï¡¢
-¼«¤é¥«¥ì¥ó¥È¥Ç¥£¥ì¥¯¥È¥ê¤òÊѹ¹¤·¤¿¤ê¡¢
-¥Õ¥¡¥¤¥ë¤Ë¥¢¥¯¥»¥¹¤·¤¿¤ê¤¹¤Ù¤­¤Ç¤Ï¤Ê¤¤¡¢¤È¤¤¤¦ÅÀ¤ËÃí°Õ¤¹¤ë¤³¤È¡£
-.TP
-.B FTS_NOSTAT
-.\"O By default, returned
-.\"O .I FTSENT
-.\"O structures reference file characteristic information (the
-.\"O .I statp
-.\"O field) for each file visited.
-.\"O This option relaxes that requirement as a performance optimization,
-.\"O allowing the
-.\"O fts functions to set the
-.\"O .I fts_info
-.\"O field to
-.\"O .B FTS_NSOK
-.\"O and leave the contents of the
-.\"O .I statp
-.\"O field undefined.
-¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¡¢ÊÖ¤µ¤ì¤¿
-.I FTSENT
-¹½Â¤ÂΤϡ¢¤¿¤É¤é¤ì¤¿³Æ¥Õ¥¡¥¤¥ë¤Ë¤Ä¤¤¤Æ¤Î¥Õ¥¡¥¤¥ëÆÃħ¾ðÊó
-.I ( statp
-¥Õ¥£¡¼¥ë¥É) ¤ò»²¾È¤¹¤ë¡£
-¤³¤Î¥ª¥×¥·¥ç¥ó¤Ï¡¢
-fts ´Ø¿ô·²¤¬
-.I fts_info
-¥Õ¥£¡¼¥ë¥É¤ò
-.B FTS_NSOK
-¤ËÀßÄꤷ
-.I statp
-¤ÎÆâÍƤòÄêµÁ¤µ¤ì¤Ê¤¤¤Þ¤Þ¤Ë¤¹¤ë¤³¤È¤òµö¤¹¤³¤È¤Ë¤è¤ê¡¢
-¥Ñ¥Õ¥©¡¼¥Þ¥ó¥¹¤ÎºÇŬ²½¤ËɬÍפʤâ¤Î¤ò´ËϤ¹¤ë¡£
-.TP
-.B FTS_PHYSICAL
-.\"O This option causes the
-.\"O fts routines to return
-.\"O .I FTSENT
-.\"O structures for symbolic links themselves instead
-.\"O of the target files they point to.
-.\"O If this option is set,
-.\"O .I FTSENT
-.\"O structures for all symbolic links in the
-.\"O hierarchy are returned to the application.
-.\"O Either
-.\"O .B FTS_LOGICAL
-.\"O or
-.\"O .B FTS_PHYSICAL
-.\"O .I must
-.\"O be provided to the
-.\"O .BR fts_open ()
-.\"O function.
-¤³¤Î¥ª¥×¥·¥ç¥ó¤Ï¡¢
-fts ¥ë¡¼¥Á¥ó¤Ë¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤¬»Ø¤·¤Æ¤¤¤ë¥Õ¥¡¥¤¥ë¤Ç¤Ï¤Ê¤¯¡¢
-¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¼«¿È¤Î
-.I FTSENT
-¹½Â¤ÂΤòÊÖ¤µ¤»¤ë¡£
-¤³¤Î¥ª¥×¥·¥ç¥ó¤¬ÀßÄꤵ¤ì¤ë¤È¡¢³¬ÁØÃæ¤Î¤¹¤Ù¤Æ¤Î¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤Î
-.I FTSENT
-¹½Â¤ÂΤ¬¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤ËÊÖ¤µ¤ì¤ë¡£
-.B FTS_LOGICAL
-¤Þ¤¿¤Ï
-.B FTS_PHYSICAL
-¤Î¤É¤Á¤é¤«¤ò
-.BR fts_open ()
-´Ø¿ô¤ËÍ¿¤¨¤Ê¤±¤ì¤Ð¡Ö¤Ê¤é¤Ê¤¤¡×¡£
-.TP
-.B FTS_SEEDOT
-.\"O By default, unless they are specified as path arguments to
-.\"O .BR fts_open (),
-.\"O any files named
-.\"O "."
-.\"O or
-.\"O ".."
-.\"O encountered in the file hierarchy are ignored.
-.\"O This option causes the
-.\"O fts routines to return
-.\"O .I FTSENT
-.\"O structures for them.
-¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¡¢
-.BR fts_open ()
-¤Î¥Ñ¥¹°ú¤­¿ô¤È¤·¤Æ»ØÄꤵ¤ì¤Ê¤¤¸Â¤ê¡¢¥Õ¥¡¥¤¥ë³¬ÁØÃæ¤Ë¤¢¤ë
-"." ¤Þ¤¿¤Ï ".." ¤È¤¤¤¦Ì¾Á°¤Î¥Õ¥¡¥¤¥ë¤Ï̵»ë¤µ¤ì¤ë¡£
-¤³¤Î¥ª¥×¥·¥ç¥ó¤Ï¡¢
-fts ¥ë¡¼¥Á¥ó¤Ë¤³¤ì¤é¤Î¥Õ¥¡¥¤¥ë¤Î
-.I FTSENT
-¹½Â¤ÂΤòÊÖ¤µ¤»¤ë¡£
-.TP
-.B FTS_XDEV
-.\"O This option prevents
-.\"O fts from descending into directories that have a different device number
-.\"O than the file from which the descent began.
-¤³¤Î¥ª¥×¥·¥ç¥ó¤Ï¡¢
-fts ¤¬²¼¤ê»Ï¤á¤Î¥Õ¥¡¥¤¥ë¤È¤Ï°Û¤Ê¤ë¥Ç¥Ð¥¤¥¹ÈÖ¹æ¤ò»ý¤Ã¤Æ¤¤¤ë
-¥Ç¥£¥ì¥¯¥È¥ê¤Ë²¼¤ê¤ë¤Î¤òÁ˻ߤ¹¤ë¡£
+多くのオプションがあり、少なくとも 1 つ (\fBFTS_LOGICAL\fP または \fBFTS_PHYSICAL\fP)  が指定されなければならない。
+オプションは以下の値の論理和をとって選択する。
+.TP  13
+\fBFTS_COMFOLLOW\fP
+このオプションは、 \fBFTS_LOGICAL\fP の指定にかかわらず、 ルートパスに指定されたシンボリックリンクをすぐにたどらせる。
+.TP 
+\fBFTS_LOGICAL\fP
+このオプションは、 fts ルーチンにシンボリックリンクそのものではなく、 シンボリックリンクが指しているファイルの \fIFTSENT\fP
+構造体を返させる。 このオプションが設定された場合、 \fIFTSENT\fP 構造体がアプリケーションに返されるような
+シンボリックリンクのみが、存在しないファイルを参照している。 \fBFTS_LOGICAL\fP または \fBFTS_PHYSICAL\fP のどちらかを、
+\fBfts_open\fP()  関数に与えなければ「ならない」。
+.TP 
+\fBFTS_NOCHDIR\fP
+パフォーマンスの最適化のため、 fts 関数群はファイル階層をたどるときディレクトリを変える。 これには、階層をたどっている間は
+アプリケーションがある特定のディレクトリにいるということに 依存できない、という副作用がある。 \fBFTS_NOCHDIR\fP
+オプションで最適化を無効にすると、 fts 関数群は現在のディレクトリを変更しない。 \fBFTS_NOCHDIR\fP が指定され、かつ
+\fBfts_open\fP()  の引き数として絶対パス名が与えられたとき以外、アプリケーションは、 自らカレントディレクトリを変更したり、
+ファイルにアクセスしたりすべきではない、という点に注意すること。
+.TP 
+\fBFTS_NOSTAT\fP
+デフォルトでは、返された \fIFTSENT\fP 構造体は、たどられた各ファイルについてのファイル特徴情報 \fI( statp\fP フィールド) を参照する。
+このオプションは、 fts 関数群が \fIfts_info\fP フィールドを \fBFTS_NSOK\fP に設定し \fIstatp\fP
+の内容を定義されないままにすることを許すことにより、 パフォーマンスの最適化に必要なものを緩和する。
+.TP 
+\fBFTS_PHYSICAL\fP
+このオプションは、 fts ルーチンにシンボリックリンクが指しているファイルではなく、 シンボリックリンク自身の \fIFTSENT\fP 構造体を返させる。
+このオプションが設定されると、階層中のすべてのシンボリックリンクの \fIFTSENT\fP 構造体がアプリケーションに返される。
+\fBFTS_LOGICAL\fP または \fBFTS_PHYSICAL\fP のどちらかを \fBfts_open\fP()  関数に与えなければ「ならない」。
+.TP 
+\fBFTS_SEEDOT\fP
+デフォルトでは、 \fBfts_open\fP()  のパス引き数として指定されない限り、ファイル階層中にある "." または ".."
+という名前のファイルは無視される。 このオプションは、 fts ルーチンにこれらのファイルの \fIFTSENT\fP 構造体を返させる。
+.TP 
+\fBFTS_XDEV\fP
 .\" .El
+このオプションは、 fts が下り始めのファイルとは異なるデバイス番号を持っている ディレクトリに下りるのを阻止する。
 .PP
-.\"O The argument
-.\"O .BR compar ()
-.\"O specifies a user-defined function which may be used to order the traversal
-.\"O of the hierarchy.
-.\"O It
-.\"O takes two pointers to pointers to
-.\"O .I FTSENT
-.\"O structures as arguments and
-.\"O should return a negative value, zero, or a positive value to indicate
-.\"O if the file referenced by its first argument comes before, in any order
-.\"O with respect to, or after, the file referenced by its second argument.
-.\"O The
-.\"O .IR fts_accpath ,
-.\"O .I fts_path
-.\"O and
-.\"O .I fts_pathlen
-.\"O fields of the
-.\"O .I FTSENT
-.\"O structures may
-.\"O .I never
-.\"O be used in this comparison.
-.\"O If the
-.\"O .I fts_info
-.\"O field is set to
-.\"O .B FTS_NS
-.\"O or
-.\"O .BR FTS_NSOK ,
-.\"O the
-.\"O .I fts_statp
-.\"O field may not either.
-.\"O If the
-.\"O .BR compar ()
-.\"O argument is
-.\"O .BR NULL ,
-.\"O the directory traversal order is in the order listed in
-.\"O .I path_argv
-.\"O for the root paths, and in the order listed in the directory for
-.\"O everything else.
-°ú¤­¿ô
-.BR compar ()
-¤Ï¡¢³¬Áؤò¤¿¤É¤ë½çÈÖ¤ò·è¤á¤ë¤Î¤Ë»È¤ï¤ì¤ë¥æ¡¼¥¶¡¼ÄêµÁ´Ø¿ô¤ò»ØÄꤹ¤ë¡£
-¤³¤Î´Ø¿ô¤Ï¡¢°ú¤­¿ô¤È¤·¤Æ
-.I FTSENT
-¹½Â¤ÂΤΥݥ¤¥ó¥¿¤Î¥Ý¥¤¥ó¥¿¤ò 2 ¤Ä¤È¤ê¡¢
-1 ÈÖÌܤΰú¤­¿ô¤Ç»²¾È¤µ¤ì¤Æ¤¤¤ë¥Õ¥¡¥¤¥ë¤¬
-2 ÈÖÌܤΰú¤­¿ô¤Ç»²¾È¤µ¤ì¤Æ¤¤¤ë¥Õ¥¡¥¤¥ë¤è¤ê
-Á°¤Ë¤¢¤ë¾ì¹ç¤ÏÉé¤ÎÃÍ¡¦Æ±¤¸¾ì¹ç¤Ï¥¼¥í¡¦¸å¤Ë¤¢¤ë¾ì¹ç¤ÏÀµ¤ÎÃͤò
-ÊÖ¤µ¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
-.I FTSENT
-¹½Â¤ÂΤÎ
-.IR fts_accpath ,
-.IR fts_path ,
-.I fts_pathlen
-¥Õ¥£¡¼¥ë¥É¤Ï¡¢¤³¤ÎÈæ³Ó¤Ë¡ÖÀäÂС׻ȤäƤϤ¤¤±¤Ê¤¤¡£
-.I fts_info
-¥Õ¥£¡¼¥ë¥É¤¬
-.B FTS_NS
-¤Þ¤¿¤Ï
-.B FTS_NSOK
-¤ËÀßÄꤵ¤ì¤ë¾ì¹ç¡¢
-.I fts_statp
-¥Õ¥£¡¼¥ë¥É¤Ï¤³¤ì¤é¤Î¤É¤Á¤é¤Ç¤â¤Ê¤¤¡£
-.BR compar ()
-°ú¤­¿ô¤¬
-.B NULL
-¤Î¾ì¹ç¡¢¥Ç¥£¥ì¥¯¥È¥ê¤ò¤¿¤É¤ë½çÈ֤ϡ¢¥ë¡¼¥È¥Ñ¥¹¤Ë¤Ä¤¤¤Æ¤Ï
-.I path_argv
-¤Î¤Ê¤«¤Ç¥ê¥¹¥È¤µ¤ì¤¿½çÈ֤ǡ¢
-¤½¤Î¾¤Î¥Õ¥¡¥¤¥ë¤Ë¤Ä¤¤¤Æ¤Ï¥Ç¥£¥ì¥¯¥È¥êÆâ¤Ç¥ê¥¹¥È¤µ¤ì¤¿½çÈ֤Ȥʤ롣
+引き数 \fBcompar\fP()  は、階層をたどる順番を決めるのに使われるユーザー定義関数を指定する。 この関数は、引き数として \fIFTSENT\fP
+構造体のポインタのポインタを 2 つとり、 1 番目の引き数で参照されているファイルが 2 番目の引き数で参照されているファイルより
+前にある場合は負の値・同じ場合はゼロ・後にある場合は正の値を 返さなければならない。 \fIFTSENT\fP 構造体の \fIfts_accpath\fP,
+\fIfts_path\fP, \fIfts_pathlen\fP フィールドは、この比較に「絶対」使ってはいけない。 \fIfts_info\fP フィールドが
+\fBFTS_NS\fP または \fBFTS_NSOK\fP に設定される場合、 \fIfts_statp\fP フィールドはこれらのどちらでもない。
+\fBcompar\fP()  引き数が \fBNULL\fP の場合、ディレクトリをたどる順番は、ルートパスについては \fIpath_argv\fP
+のなかでリストされた順番で、 その他のファイルについてはディレクトリ内でリストされた順番となる。
 .SS fts_read()
-.\"O The
-.\"O .BR fts_read ()
-.\"O function returns a pointer to an
-.\"O .I FTSENT
-.\"O structure describing a file in
-.\"O the hierarchy.
-.\"O Directories (that are readable and do not cause cycles) are visited at
-.\"O least twice, once in preorder and once in postorder.
-.\"O All other files are visited at least once.
-.\"O (Hard links between directories that do not cause cycles or symbolic
-.\"O links to symbolic links may cause files to be visited more than once,
-.\"O or directories more than twice.)
-.BR fts_read ()
-´Ø¿ô¤Ï¡¢³¬ÁØÃæ¤Î¥Õ¥¡¥¤¥ë¤òµ­½Ò¤¹¤ë
-.I FTSENT
-¹½Â¤ÂΤؤΥݥ¤¥ó¥¿¤òÊÖ¤¹¡£
-(Æɤ߹þ¤ß²Äǽ¤Ç¡¢½Û´Ä¤·¤Æ¤¤¤Ê¤¤) ¥Ç¥£¥ì¥¯¥È¥ê¤Ï¡¢
-1 ²ó¤Ï preorder ¤Ç¡¢¤â¤¦ 1 ²ó¤Ï postorder ¤Ç¡¢¾¯¤Ê¤¯¤È¤â 2 ²ó¤¿¤É¤é¤ì¤ë¡£
-¾¤Î¥Õ¥¡¥¤¥ë¤Ï¡¢¾¯¤Ê¤¯¤È¤â 1 ²ó¤¿¤É¤é¤ì¤ë¡£
-(¥Ç¥£¥ì¥¯¥È¥ê´Ö¤Î¥Ï¡¼¥É¥ê¥ó¥¯¤Ë¤è¤Ã¤Æ
-½Û´Ä¤ä¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤Ø¤Î¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤¬µ¯¤³¤é¤Ê¤¤¾ì¹ç¡¢
-¥Õ¥¡¥¤¥ë¤Ï 2 ²ó°Ê¾å¡¢¥Ç¥£¥ì¥¯¥È¥ê¤Ï 3 ²ó°Ê¾å¤¿¤É¤é¤ì¤ë¡£)
+\fBfts_read\fP()  関数は、階層中のファイルを記述する \fIFTSENT\fP 構造体へのポインタを返す。 (読み込み可能で、循環していない)
+ディレクトリは、 1 回は preorder で、もう 1 回は postorder で、少なくとも 2 回たどられる。 他のファイルは、少なくとも 1
+回たどられる。 (ディレクトリ間のハードリンクによって 循環やシンボリックリンクへのシンボリックリンクが起こらない場合、 ファイルは 2
+回以上、ディレクトリは 3 回以上たどられる。)
 .PP
-.\"O If all the members of the hierarchy have been returned,
-.\"O .BR fts_read ()
-.\"O returns
-.\"O .B NULL
-.\"O and sets the external variable
-.\"O .I errno
-.\"O to 0.
-.\"O If an error unrelated to a file in the hierarchy occurs,
-.\"O .BR fts_read ()
-.\"O returns
-.\"O .B NULL
-.\"O and sets
-.\"O .I errno
-.\"O appropriately.
-.\"O If an error related to a returned file occurs, a pointer to an
-.\"O .I FTSENT
-.\"O structure is returned, and
-.\"O .I errno
-.\"O may or may not have been set (see
-.\"O .IR fts_info ).
-³¬ÁØÃæ¤Î¤¹¤Ù¤Æ¤Î¥á¥ó¥Ð¡¼¤¬ÊÖ¤µ¤ì¤¿¾ì¹ç¡¢
-.BR fts_read ()
-¤Ï
-.B NULL
-¤òÊÖ¤·¡¢³°ÉôÊÑ¿ô
-.I errno
-¤ò 0 ¤Ë¤¹¤ë¡£
-³¬ÁØÃæ¤Î¥Õ¥¡¥¤¥ë¤Ë´Ø·¸¤·¤Ê¤¤¥¨¥é¡¼¤¬µ¯¤³¤Ã¤¿¾ì¹ç¡¢
-.BR fts_read ()
-¤Ï
-.B NULL
-¤òÊÖ¤·¡¢
-.I errno
-¤ò¥¨¥é¡¼¤ËÂбþ¤·¤¿Ãͤˤ¹¤ë¡£
-³¬ÁØÃæ¤Î¥Õ¥¡¥¤¥ë¤Ë´Ø·¸¤·¤¿¥¨¥é¡¼¤¬µ¯¤³¤Ã¤¿¾ì¹ç¡¢
-.I FTSENT
-¹½Â¤ÂΤؤΥݥ¤¥ó¥¿¤¬ÊÖ¤µ¤ì¡¢
-.I errno
-¤ÏÀßÄꤵ¤ì¤ë¾ì¹ç¤ÈÀßÄꤵ¤ì¤Ê¤¤¾ì¹ç¤¬¤¢¤ë
-.RI ( fts_info
-¤ò»²¾È¤¹¤ë¤³¤È)¡£
+階層中のすべてのメンバーが返された場合、 \fBfts_read\fP()  は \fBNULL\fP を返し、外部変数 \fIerrno\fP を 0 にする。
+階層中のファイルに関係しないエラーが起こった場合、 \fBfts_read\fP()  は \fBNULL\fP を返し、 \fIerrno\fP
+をエラーに対応した値にする。 階層中のファイルに関係したエラーが起こった場合、 \fIFTSENT\fP 構造体へのポインタが返され、 \fIerrno\fP
+は設定される場合と設定されない場合がある (\fIfts_info\fP を参照すること)。
 .PP
-.\"O The
-.\"O .I FTSENT
-.\"O structures returned by
-.\"O .BR fts_read ()
-.\"O may be overwritten after a call to
-.\"O .BR fts_close ()
-.\"O on the same file hierarchy stream, or, after a call to
-.\"O .BR fts_read ()
-.\"O on the same file hierarchy stream unless they represent a file of type
-.\"O directory, in which case they will not be overwritten until after a call to
-.\"O .BR fts_read ()
-.\"O after the
-.\"O .I FTSENT
-.\"O structure has been returned by the function
-.\"O .BR fts_read ()
-.\"O in postorder.
-.BR fts_read ()
-¤Ë¤è¤Ã¤ÆÊÖ¤µ¤ì¤ë
-.I FTSENT
-¹½Â¤ÂΤϡ¢Æ±¤¸¥Õ¥¡¥¤¥ë³¬ÁØ¥¹¥È¥ê¡¼¥à¤Ø¤Î
-.BR fts_close ()
-¤Î¸Æ½Ð¤·¤Î¸å¤Ë¾å½ñ¤­¤µ¤ì¤ë¡£
-¤Þ¤¿¡¢Æ±¤¸¥Õ¥¡¥¤¥ë³¬ÁØ¥¹¥È¥ê¡¼¥à¤Ø¤Î
-.BR fts_read ()
-¤Î¸Æ½Ð¤·¤Î¸å¤Ç¤â¡¢¹½Â¤ÂΤ¬¥Ç¥£¥ì¥¯¥È¥ê¤òɽ¸½¤·¤Æ¤¤¤Ê¤¤¸Â¤ê¾å½ñ¤­¤µ¤ì¤ë¡£
-¤³¤Î¾ì¹ç¡¢
-.BR fts_read ()
-´Ø¿ô¤Ë¤è¤Ã¤Æ postorder ¤Ç
-.I FTSENT
-¹½Â¤ÂΤ¬ÊÖ¤µ¤ì¤¿¸å¡¢
-.BR fts_read ()
-¤Î¸Æ½Ð¤·¤¬¤¢¤ë¤Þ¤Ç¡¢
-¤³¤ì¤é¤Î¹½Â¤ÂΤϾå½ñ¤­¤µ¤ì¤Ê¤¤¡£
+\fBfts_read\fP()  によって返される \fIFTSENT\fP 構造体は、同じファイル階層ストリームへの \fBfts_close\fP()
+の呼出しの後に上書きされる。 また、同じファイル階層ストリームへの \fBfts_read\fP()
+の呼出しの後でも、構造体がディレクトリを表現していない限り上書きされる。 この場合、 \fBfts_read\fP()  関数によって postorder で
+\fIFTSENT\fP 構造体が返された後、 \fBfts_read\fP()  の呼出しがあるまで、 これらの構造体は上書きされない。
 .SS fts_children()
-.\"O The
-.\"O .BR fts_children ()
-.\"O function returns a pointer to an
-.\"O .I FTSENT
-.\"O structure describing the first entry in a NULL-terminated linked list of
-.\"O the files in the directory represented by the
-.\"O .I FTSENT
-.\"O structure most recently returned by
-.\"O .BR fts_read ().
-.\"O The list is linked through the
-.\"O .I fts_link
-.\"O field of the
-.\"O .I FTSENT
-.\"O structure, and is ordered by the user-specified comparison function, if any.
-.\"O Repeated calls to
-.\"O .BR fts_children ()
-.\"O will recreate this linked list.
-.BR fts_children ()
-´Ø¿ô¤Ï¡¢
-.I FTSENT
-¹½Â¤ÂΤؤΥݥ¤¥ó¥¿¤òÊÖ¤¹¡£
-¤³¤Î¹½Â¤ÂΤϡ¢(
-.BR fts_read ()
-¤ÇºÇ¤â¿·¤·¤¯ÊÖ¤µ¤ì¤¿
-.I FTSENT
-¹½Â¤ÂΤÇɽ¸½¤µ¤ì¤ë¥Ç¥£¥ì¥¯¥È¥ê¤Ë¤¢¤ë¥Õ¥¡¥¤¥ë¤Î)
-NUL ½ªÃ¼¤µ¤ì¤¿¥ê¥ó¥¯¥ê¥¹¥È¤ÎºÇ½é¤Î¥¨¥ó¥È¥ê¤òµ­½Ò¤¹¤ë¡£
-¤³¤Î¥ê¥¹¥È¤Ï¡¢
-.I FTSENT
-¹½Â¤ÂΤÎ
-.I fts_link
-¥Õ¥£¡¼¥ë¥É¤ò»È¤Ã¤Æ¥ê¥ó¥¯¤µ¤ì¡¢
-¥æ¡¼¥¶¡¼»ØÄê¤ÎÈæ³Ó´Ø¿ô¤¬¤¢¤ë¾ì¹ç¤Ï¡¢¤½¤ì¤Ç½ç½ø¤Å¤±¤é¤ì¤ë¡£
-.BR fts_children ()
-¤Î¸Æ½Ð¤·¤ò·«¤êÊÖ¤¹¤³¤È¤Ç¡¢
-¤³¤Î¥ê¥ó¥¯¥ê¥¹¥È¤ÏºÆÀ¸À®¤µ¤ì¤ë¡£
+\fBfts_children\fP()  関数は、 \fIFTSENT\fP 構造体へのポインタを返す。 この構造体は、( \fBfts_read\fP()
+で最も新しく返された \fIFTSENT\fP 構造体で表現されるディレクトリにあるファイルの)  NUL 終端されたリンクリストの最初のエントリを記述する。
+このリストは、 \fIFTSENT\fP 構造体の \fIfts_link\fP フィールドを使ってリンクされ、
+ユーザー指定の比較関数がある場合は、それで順序づけられる。 \fBfts_children\fP()  の呼出しを繰り返すことで、
+このリンクリストは再生成される。
 .PP
-.\"O As a special case, if
-.\"O .BR fts_read ()
-.\"O has not yet been called for a hierarchy,
-.\"O .BR fts_children ()
-.\"O will return a pointer to the files in the logical directory specified to
-.\"O .BR fts_open (),
-.\"O that is, the arguments specified to
-.\"O .BR fts_open ().
-.\"O Otherwise, if the
-.\"O .I FTSENT
-.\"O structure most recently returned by
-.\"O .BR fts_read ()
-.\"O is not a directory being visited in preorder,
-.\"O or the directory does not contain any files,
-.\"O .BR fts_children ()
-.\"O returns
-.\"O .B NULL
-.\"O and sets
-.\"O .I errno
-.\"O to zero.
-.\"O If an error occurs,
-.\"O .BR fts_children ()
-.\"O returns
-.\"O .B NULL
-.\"O and sets
-.\"O .I errno
-.\"O appropriately.
-ÆÃÊ̤ʾì¹ç¤È¤·¤Æ¡¢
-.BR fts_read ()
-¤¬¥Õ¥¡¥¤¥ë³¬ÁؤˤĤ¤¤Æ¸Æ¤Ð¤ì¤Æ¤¤¤Ê¤¤¾ì¹ç¡¢
-.BR fts_children ()
-¤Ï
-.BR fts_open ()
-¤Ë»ØÄꤵ¤ì¤¿ÏÀÍý¥Ç¥£¥ì¥¯¥È¥ê (¤Ä¤Þ¤ê¡¢
-.BR fts_open ()
-¤Ë»ØÄꤵ¤ì¤¿°ú¤­¿ô) ¤ÎÃæ¤Ë¤¢¤ë¥Õ¥¡¥¤¥ë¤Ø¤Î¥Ý¥¤¥ó¥¿¤òÊÖ¤¹¡£
-¤½¤ì°Ê³°¤Î¾ì¹ç¤Ç¡¢
-.BR fts_read ()
-¤Ë¤è¤Ã¤ÆºÇ¤â¿·¤·¤¯ÊÖ¤µ¤ì¤¿
-.I FTSENT
-¹½Â¤ÂΤ¬ preorder ¤Ç¤¿¤É¤é¤ì¤¿¥Ç¥£¥ì¥¯¥È¥ê¤Ç¤Ê¤¤¾ì¹ç¤ä
-²¿¤â´Þ¤ó¤Ç¤¤¤Ê¤¤¥Ç¥£¥ì¥¯¥È¥ê¤Î¾ì¹ç¤Ï¡¢
-.BR fts_children ()
-¤Ï
-.B NULL
-¤òÊÖ¤·¡¢
-.I errno
-¤ò 0 ¤Ë¤¹¤ë¡£
-¥¨¥é¡¼¤¬µ¯¤³¤Ã¤¿¾ì¹ç¡¢
-.BR fts_children ()
-¤Ï
-.B NULL
-¤òÊÖ¤·¡¢
-.I errno
-¤ò¥¨¥é¡¼¤ËÂбþ¤·¤¿Ãͤˤ¹¤ë¡£
+特別な場合として、 \fBfts_read\fP()  がファイル階層について呼ばれていない場合、 \fBfts_children\fP()  は
+\fBfts_open\fP()  に指定された論理ディレクトリ (つまり、 \fBfts_open\fP()  に指定された引き数)
+の中にあるファイルへのポインタを返す。 それ以外の場合で、 \fBfts_read\fP()  によって最も新しく返された \fIFTSENT\fP 構造体が
+preorder でたどられたディレクトリでない場合や 何も含んでいないディレクトリの場合は、 \fBfts_children\fP()  は \fBNULL\fP
+を返し、 \fIerrno\fP を 0 にする。 エラーが起こった場合、 \fBfts_children\fP()  は \fBNULL\fP を返し、
+\fIerrno\fP をエラーに対応した値にする。
 .PP
-.\"O The
-.\"O .I FTSENT
-.\"O structures returned by
-.\"O .BR fts_children ()
-.\"O may be overwritten after a call to
-.\"O .BR fts_children (),
-.\"O .BR fts_close ()
-.\"O or
-.\"O .BR fts_read ()
-.\"O on the same file hierarchy stream.
-.BR fts_children ()
-¤Ë¤è¤Ã¤ÆÊÖ¤µ¤ì¤ë
-.I FTSENT
-¹½Â¤ÂΤϡ¢Æ±¤¸¥Õ¥¡¥¤¥ë³¬ÁØ¥¹¥È¥ê¡¼¥à¤Ø¤Î
-.BR fts_children (),
-.BR fts_close (),
-.BR fts_read ()
-¤Î¸Æ½Ð¤·¤Î¸å¤Ë¾å½ñ¤­¤µ¤ì¤ë¾ì¹ç¤¬¤¢¤ë¡£
+\fBfts_children\fP()  によって返される \fIFTSENT\fP 構造体は、同じファイル階層ストリームへの
+\fBfts_children\fP(), \fBfts_close\fP(), \fBfts_read\fP()  の呼出しの後に上書きされる場合がある。
 .PP
-.\"O .I Option
-.\"O may be set to the following value:
-.I option
-¤Ï¡¢¼¡¤ÎÃͤËÀßÄê¤Ç¤­¤ë¡£
 .\" .Bl -tag -width FTS_NAMEONLY
-.TP
-.B FTS_NAMEONLY
-.\"O Only the names of the files are needed.
-.\"O The contents of all the fields in the returned linked list of structures
-.\"O are undefined with the exception of the
-.\"O .I fts_name
-.\"O and
-.\"O .I fts_namelen
-.\"O fields.
-¥Õ¥¡¥¤¥ë̾¤Î¤ß¤¬É¬ÍפȤµ¤ì¤Æ¤¤¤ë¡£
-ÊÖ¤µ¤ì¤¿¹½Â¤ÂΤΥê¥ó¥¯¥ê¥¹¥È¤Î
-.IR fts_name ,
-.I fts_namelen
-¥Õ¥£¡¼¥ë¥É°Ê³°¤Î
-¤¹¤Ù¤Æ¤Î¥Õ¥£¡¼¥ë¥É¤ÎÆâÍƤÏÄêµÁ¤µ¤ì¤Ê¤¤¡£
+\fIoption\fP は、次の値に設定できる。
+.TP  13
+\fBFTS_NAMEONLY\fP
 .\" .El
+ファイル名のみが必要とされている。 返された構造体のリンクリストの \fIfts_name\fP, \fIfts_namelen\fP フィールド以外の
+すべてのフィールドの内容は定義されない。
 .SS fts_set()
-.\"O The function
-.\"O .BR fts_set ()
-.\"O allows the user application to determine further processing for the
-.\"O file
-.\"O .I f
-.\"O of the stream
-.\"O .IR ftsp .
-.\"O The
-.\"O .BR fts_set ()
-.\"O function
-.\"O returns 0 on success, and \-1 if an error occurs.
-.\"O .I Option
-.\"O must be set to one of the following values:
-´Ø¿ô
-.BR fts_set ()
-¤Ï¡¢¥æ¡¼¥¶¡¼¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤¬
-¥¹¥È¥ê¡¼¥à
-.I ftsp
-¤Î¥Õ¥¡¥¤¥ë
-.I f
-¤Ë¤Ä¤¤¤Æ¹¹¤Ê¤ë½èÍý¤ò·èÄꤹ¤ë¤³¤Èµö¤¹¡£
-.BR fts_set ()
-´Ø¿ô¤Ï¡¢À®¸ù¤·¤¿¾ì¹ç¤Ï 0 ¤ò¡¢¥¨¥é¡¼¤¬µ¯¤³¤Ã¤¿¾ì¹ç¤Ï \-1 ¤òÊÖ¤¹¡£
-.I option
-¤Ï¡¢¼¡¤ÎÃͤΤ¤¤º¤ì¤« 1 ¤Ä¤ËÀßÄꤵ¤ì¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
 .\" .Bl -tag -width FTS_PHYSICAL
-.TP
-.B FTS_AGAIN
-.\"O Re-visit the file; any file type may be revisited.
-.\"O The next call to
-.\"O .BR fts_read ()
-.\"O will return the referenced file.
-.\"O The
-.\"O .I fts_stat
-.\"O and
-.\"O .I fts_info
-.\"O fields of the structure will be reinitialized at that time,
-.\"O but no other fields will have been changed.
-.\"O This option is meaningful only for the most recently returned
-.\"O file from
-.\"O .BR fts_read ().
-.\"O Normal use is for postorder directory visits, where it causes the
-.\"O directory to be revisited (in both preorder and postorder) as well as all
-.\"O of its descendants.
-¥Õ¥¡¥¤¥ë¤òºÆ¤Ó¤¿¤É¤ë¡£¤¹¤Ù¤Æ¤Î¥Õ¥¡¥¤¥ë¥¿¥¤¥×¤¬ºÆ¤Ó¤¿¤É¤é¤ì¤ë¡£
-¼¡¤Î
-.BR fts_read ()
-¤Î¸Æ½Ð¤·¤Ë¤è¤ê¡¢»²¾È¤µ¤ì¤Æ¤¤¤ë¥Õ¥¡¥¤¥ë¤¬ÊÖ¤µ¤ì¤ë¡£
-¹½Â¤ÂΤÎ
-.IR fts_stat ,
-.I fts_info
-¥Õ¥£¡¼¥ë¥É¤Ï¤³¤Î»þ¤Ë½é´ü²½¤µ¤ì¤ë¤¬¡¢Â¾¤Î¥Õ¥£¡¼¥ë¥É¤ÏÊѹ¹¤µ¤ì¤Ê¤¤¡£
-¤³¤Î¥ª¥×¥·¥ç¥ó¤Ï¡¢
-.BR fts_read ()
-¤Ë¤è¤Ã¤ÆºÇ¤â¿·¤·¤¯ÊÖ¤µ¤ì¤¿¥Õ¥¡¥¤¥ë¤Ë¤Ä¤¤¤Æ¤Î¤ß°ÕÌ£¤ò»ý¤Ä¡£
-Ä̾ï¤Ï¡¢postorder ¤Ç¥Ç¥£¥ì¥¯¥È¥ê¤ò¤¿¤É¤ë¾ì¹ç¤Ë»ÈÍѤ·¡¢
-¤½¤Î²¼¤Î³¬ÁؤÈƱÍͤˡ¢
-¥Ç¥£¥ì¥¯¥È¥ê¤ò (preorder ¤È postorder ¤ÎξÊý¤Ç) ºÆ¤Ó¤¿¤É¤é¤»¤ë¡£
-.TP
-.B FTS_FOLLOW
-.\"O The referenced file must be a symbolic link.
-.\"O If the referenced file is the one most recently returned by
-.\"O .BR fts_read (),
-.\"O the next call to
-
-.\"O .BR fts_read ()
-.\"O returns the file with the
-.\"O .I fts_info
-.\"O and
-.\"O .I fts_statp
-.\"O fields reinitialized to reflect the target of the symbolic link instead
-.\"O of the symbolic link itself.
-.\"O If the file is one of those most recently returned by
-.\"O .BR fts_children (),
-.\"O the
-.\"O .I fts_info
-.\"O and
-.\"O .I fts_statp
-.\"O fields of the structure, when returned by
-.\"O .BR fts_read (),
-.\"O will reflect the target of the symbolic link instead of the symbolic link
-.\"O itself.
-.\"O In either case, if the target of the symbolic link does not exist the
-.\"O fields of the returned structure will be unchanged and the
-.\"O .I fts_info
-.\"O field will be set to
-.\"O .BR FTS_SLNONE .
-.\"O .PP
-.\"O If the target of the link is a directory, the preorder return, followed
-.\"O by the return of all of its descendants, followed by a postorder return,
-.\"O is done.
-»²¾È¤µ¤ì¤Æ¤ë¥Õ¥¡¥¤¥ë¤Ï¡¢¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤Ç¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
-»²¾È¤µ¤ì¤Æ¤¤¤ë¥Õ¥¡¥¤¥ë¤¬
-.BR fts_read ()
-¤Ë¤è¤Ã¤ÆºÇ¤â¿·¤·¤¯ÊÖ¤µ¤ì¤¿¤â¤Î¤Ç¤¢¤ë¾ì¹ç¡¢¼¡¤Î
-.BR fts_read ()
-¤Î¸Æ½Ð¤·¤Ç¤Ï¡¢¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤½¤Î¤â¤Î¤Ç¤Ï¤Ê¤¯¡¢
-¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤¬»Ø¤·¤Æ¤¤¤ëÀè¤òÈ¿±Ç¤¹¤ë¤è¤¦¤Ë
-.IR fts_info ,
-.I fts_statp
-¤òºÆ¤Ó½é´ü²½¤·¤¿¥Õ¥¡¥¤¥ë¤¬ÊÖ¤µ¤ì¤ë¡£
-¥Õ¥¡¥¤¥ë¤¬
-.BR fts_children ()
-¤Ë¤è¤Ã¤ÆºÇ¤â¿·¤·¤¯ÊÖ¤µ¤ì¤¿¤â¤Î¤Î 1 ¤Ä¤Ç¤¢¤ë¾ì¹ç¡¢
-.BR fts_read ()
-¤Ë¤è¤Ã¤ÆÊÖ¤µ¤ì¤¿¤È¤­¡¢¹½Â¤ÂΤÎ
-.IR fts_info ,
-.I fts_statp
-¥Õ¥£¡¼¥ë¥É¤Ï¡¢¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤½¤Î¤â¤Î¤Ç¤Ï¤Ê¤¯¡¢
-¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤¬»Ø¤·¤Æ¤¤¤ëÀè¤òÈ¿±Ç¤¹¤ë¡£
-¤É¤Á¤é¤Î¾ì¹ç¤Ç¤â¡¢¥·¥ó¥Ü¥ê¥Ã¥¯¥ê¥ó¥¯¤¬»Ø¤·¤Æ¤¤¤ëÀ褬¤Ê¤¤¤È¤­¤Ï¡¢
-ÊÖ¤µ¤ì¤¿¹½Â¤ÂΤΥե£¡¼¥ë¥É¤ÏÊѹ¹¤µ¤ì¤º¡¢
-.I fts_info
-¥Õ¥£¡¼¥ë¥É¤¬
-.B FTS_SLNONE
-¤ËÀßÄꤵ¤ì¤ë¡£
-.PP
-.\"O If the target of the link is a directory, the preorder return, followed
-.\"O by the return of all of its descendants, followed by a postorder return,
-.\"O is done.
-¥ê¥ó¥¯À褬¥Ç¥£¥ì¥¯¥È¥ê¤Î¾ì¹ç¡¢
-¥Õ¥¡¥¤¥ë¤¬ preorder ¤ÇÊÖ¤µ¤ì¤¿¸å¡¢²¼¤Î³¬ÁؤΤ¹¤Ù¤Æ¥Õ¥¡¥¤¥ë¤¬ÊÖ¤µ¤ì¡¢
-¤½¤Î¸å¤Ç postorder ¤ÇÊÖ¤µ¤ì¤ë¡£
-.TP
-.B FTS_SKIP
-.\"O No descendants of this file are visited.
-.\"O The file may be one of those most recently returned by either
-.\"O .BR fts_children ()
-.\"O or
-.\"O .BR fts_read ().
-¤³¤Î¥Õ¥¡¥¤¥ë¤Î²¼¤Î³¬ÁؤϤ¿¤É¤é¤ì¤Ê¤¤¡£
-¤³¤Î¥Õ¥¡¥¤¥ë¤Ï¡¢
-.BR fts_children ()
-¤Þ¤¿¤Ï
-.BR fts_read ()
-¤Î¤É¤Á¤é¤«¤Ë¤è¤Ã¤ÆºÇ¤â¿·¤·¤¯ÊÖ¤µ¤ì¤¿¤â¤Î¤Î 1 ¤Ä¤Ç¤¢¤ë¡£
+関数 \fBfts_set\fP()  は、ユーザーアプリケーションが ストリーム \fIftsp\fP のファイル \fIf\fP
+について更なる処理を決定すること許す。 \fBfts_set\fP()  関数は、成功した場合は 0 を、エラーが起こった場合は \-1 を返す。
+\fIoption\fP は、次の値のいずれか 1 つに設定されなければならない。
+.TP  13
+\fBFTS_AGAIN\fP
+ファイルを再びたどる。すべてのファイルタイプが再びたどられる。 次の \fBfts_read\fP()  の呼出しにより、参照されているファイルが返される。
+構造体の \fIfts_stat\fP, \fIfts_info\fP フィールドはこの時に初期化されるが、他のフィールドは変更されない。 このオプションは、
+\fBfts_read\fP()  によって最も新しく返されたファイルについてのみ意味を持つ。 通常は、postorder
+でディレクトリをたどる場合に使用し、 その下の階層と同様に、 ディレクトリを (preorder と postorder の両方で) 再びたどらせる。
+.TP 
+\fBFTS_FOLLOW\fP
+参照されてるファイルは、シンボリックリンクでなければならない。 参照されているファイルが \fBfts_read\fP()
+によって最も新しく返されたものである場合、次の \fBfts_read\fP()  の呼出しでは、シンボリックリンクそのものではなく、
+シンボリックリンクが指している先を反映するように \fIfts_info\fP, \fIfts_statp\fP を再び初期化したファイルが返される。 ファイルが
+\fBfts_children\fP()  によって最も新しく返されたものの 1 つである場合、 \fBfts_read\fP()  によって返されたとき、構造体の
+\fIfts_info\fP, \fIfts_statp\fP フィールドは、シンボリックリンクそのものではなく、 シンボリックリンクが指している先を反映する。
+どちらの場合でも、シンボリックリンクが指している先がないときは、 返された構造体のフィールドは変更されず、 \fIfts_info\fP フィールドが
+\fBFTS_SLNONE\fP に設定される。
+.IP
+リンク先がディレクトリの場合、 ファイルが preorder で返された後、下の階層のすべてファイルが返され、 その後で postorder
+で返される。
+.TP 
+\fBFTS_SKIP\fP
 .\" .El
+このファイルの下の階層はたどられない。 このファイルは、 \fBfts_children\fP()  または \fBfts_read\fP()
+のどちらかによって最も新しく返されたものの 1 つである。
 .SS fts_close()
-.\"O The
-.\"O .BR fts_close ()
-.\"O function closes a file hierarchy stream
-.\"O .I ftsp
-.\"O and restores the current directory to the directory from which
-.\"O .BR fts_open ()
-.\"O was called to open
-.\"O .IR ftsp .
-.\"O The
-.\"O .BR fts_close ()
-.\"O function
-.\"O returns 0 on success, and \-1 if an error occurs.
-.BR fts_close ()
-´Ø¿ô¤Ï¡¢¥Õ¥¡¥¤¥ë³¬ÁØ¥¹¥È¥ê¡¼¥à
-.I ftsp
-¤òÊĤ¸¤ë¡£¤½¤·¤Æ¡¢¸½ºß¤Î¥Ç¥£¥ì¥¯¥È¥ê¤ò
-.I ftsp
-¤ò³«¤¯¤¿¤á¤Ë
-.BR fts_open ()
-¤¬¸Æ¤Ð¤ì¤¿¥Ç¥£¥ì¥¯¥È¥ê¤ËÉü¸µ¤¹¤ë¡£
-.BR fts_close ()
-´Ø¿ô¤Ï¡¢À®¸ù¤·¤¿¾ì¹ç¤Ï 0 ¤ò¡¢¥¨¥é¡¼¤¬µ¯¤³¤Ã¤¿¾ì¹ç¤Ï \-1 ¤òÊÖ¤¹¡£
-.\"O .SS ERRORS
-.SS ¥¨¥é¡¼
-.\"O The function
-.\"O .BR fts_open ()
-.\"O may fail and set
-.\"O .I errno
-.\"O for any of the errors specified for the library functions
-.\"O .BR open (2)
-.\"O and
-.\"O .BR malloc (3).
-´Ø¿ô
-.BR fts_open ()
-¤¬¼ºÇÔ¤·¤¿¾ì¹ç¡¢
-.I errno
-¤Ï¡¢¥é¥¤¥Ö¥é¥ê´Ø¿ô
-.BR open (2)
-¤È
-.BR malloc (3)
-¤ËÂФ·¤Æ»ØÄꤵ¤ì¤ë¥¨¥é¡¼¤ËÀßÄꤵ¤ì¤ë¡£
+\fBfts_close\fP()  関数は、ファイル階層ストリーム \fIftsp\fP を閉じる。そして、現在のディレクトリを \fIftsp\fP を開くために
+\fBfts_open\fP()  が呼ばれたディレクトリに復元する。 \fBfts_close\fP()  関数は、成功した場合は 0 を、エラーが起こった場合は
+\-1 を返す。
+.SH エラー
+関数 \fBfts_open\fP()  が失敗した場合、 \fIerrno\fP は、ライブラリ関数 \fBopen\fP(2)  と \fBmalloc\fP(3)
+に対して指定されるエラーに設定される。
 .PP
-.\"O The function
-.\"O .BR fts_close ()
-.\"O may fail and set
-.\"O .I errno
-.\"O for any of the errors specified for the library functions
-.\"O .BR chdir (2)
-.\"O and
-.\"O .BR close (2).
-´Ø¿ô
-.BR fts_close ()
-¤¬¼ºÇÔ¤·¤¿¾ì¹ç¡¢
-.I errno
-¤Ï¡¢¥é¥¤¥Ö¥é¥ê´Ø¿ô
-.BR chdir (2)
-¤È
-.BR close (2)
-¤ËÂФ·¤Æ»ØÄꤵ¤ì¤ë¥¨¥é¡¼¤ËÀßÄꤵ¤ì¤ë¡£
+関数 \fBfts_close\fP()  が失敗した場合、 \fIerrno\fP は、ライブラリ関数 \fBchdir\fP(2)  と \fBclose\fP(2)
+に対して指定されるエラーに設定される。
 .PP
-.\"O The functions
-.\"O .BR fts_read ()
-.\"O and
-.\"O .BR fts_children ()
-.\"O may fail and set
-.\"O .I errno
-.\"O for any of the errors specified for the library functions
-.\"O .BR chdir (2),
-.\"O .BR malloc (3),
-.\"O .BR opendir (3),
-.\"O .BR readdir (3)
-.\"O and
-.\"O .BR stat (2).
-´Ø¿ô
-.BR fts_read ()
-¤È
-.BR fts_children ()
-¤¬¼ºÇÔ¤·¤¿¾ì¹ç¡¢
-.I errno
-¤Ï¡¢¥é¥¤¥Ö¥é¥ê´Ø¿ô
-.BR chdir (2),
-.BR malloc (3),
-.BR opendir (3),
-.BR readdir (3),
-.BR stat (2)
-¤ËÂФ·¤Æ»ØÄꤵ¤ì¤ë¥¨¥é¡¼¤ËÀßÄꤵ¤ì¤ë¡£
+関数 \fBfts_read\fP()  と \fBfts_children\fP()  が失敗した場合、 \fIerrno\fP は、ライブラリ関数
+\fBchdir\fP(2), \fBmalloc\fP(3), \fBopendir\fP(3), \fBreaddir\fP(3), \fBstat\fP(2)
+に対して指定されるエラーに設定される。
 .PP
-.\"O In addition,
-.\"O .BR fts_children (),
-.\"O .BR fts_open ()
-.\"O and
-.\"O .BR fts_set ()
-.\"O may fail and set
-.\"O .I errno
-.\"O as follows:
-¹¹¤Ë¡¢
-.BR fts_children (),
-.BR fts_open (),
-.BR fts_set ()
-¤¬¼ºÇÔ¤·¤¿¾ì¹ç¡¢
-.I errno
-¤¬¼¡¤ÎÃͤˤµ¤ì¤ë¡£
-.TP
-.B EINVAL
-.\"O The options were invalid.
-¥ª¥×¥·¥ç¥ó¤¬Ìµ¸ú¤Ç¤¢¤Ã¤¿¡£
-.\"O .SH VERSIONS
-.SH ¥Ð¡¼¥¸¥ç¥ó
-.\"O These functions are available in Linux since glibc2.
-¤³¤ì¤é¤Î´Ø¿ô¤Ï¡¢Linux ¤Ç¤Ï glibc2 ¤«¤é»ÈÍѲÄǽ¤Ç¤¢¤ë¡£
-.\"O SH "CONFORMING TO"
-.SH ½àµò
-4.4BSD.
+更に、 \fBfts_children\fP(), \fBfts_open\fP(), \fBfts_set\fP()  が失敗した場合、 \fIerrno\fP
+が次の値にされる。
+.TP 
+\fBEINVAL\fP
+オプションが無効であった。
+.SH バージョン
+これらの関数は、Linux では glibc2 から使用可能である。
+.SH 準拠
 .\" The following statement is years old, and seems no closer to
 .\" being true -- mtk
-.\"O .\" The
-.\"O .\" .I fts
-.\"O .\" utility is expected to be included in a future
-.\"O .\" POSIX.1
-.\"O .\" revision.
+.\" The
 .\" .I fts
-.\" ¥æ¡¼¥Æ¥£¥ê¥Æ¥£¤Ï¡¢¾­Íè¤Î
+.\" utility is expected to be included in a future
 .\" POSIX.1
-.\" ¥ê¥Ó¥¸¥ç¥ó¤Ë´Þ¤Þ¤ì¤ë¤È´üÂÔ¤µ¤ì¤Æ¤¤¤ë¡£
-.\"O .SH SEE ALSO
-.SH ´ØÏ¢¹àÌÜ
-.BR find (1),
-.BR chdir (2),
-.BR stat (2),
-.BR ftw (3),
-.BR qsort (3)
+.\" revision.
+4.4BSD.
+.SH 関連項目
+\fBfind\fP(1), \fBchdir\fP(2), \fBstat\fP(2), \fBftw\fP(3), \fBqsort\fP(3)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.53 の一部
+である。プロジェクトの説明とバグ報告に関する情報は
+http://www.kernel.org/doc/man\-pages/ に書かれている。