[cs631apue] About FTS
Yuxi Wang
ywang286 at stevens.edu
Sat Oct 5 19:55:16 EDT 2019
Hi professor,
Here is the quote from fts(3):
1.To use these fields to reference any files represented by
other FTSENT structures will require that the path buffer be modified
using the information contained in that FTSENT structure's fts_pathlen
field. Any such modifications should be undone before further calls to
fts_read() are attempted. The fts_name field is always NUL-terminated.
I saw the source code of fts.c. I can understand a single buffer is used for all of the paths of all of the files in the file hierarchy. But I don’t know how to only use fts_path to reference files. What the manual want to tell us? Could you give me a example or something?
2.What does the fts_accpath represent for? I tracked the FTS structure and found it always equal fts_name.
Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.stevens.edu/pipermail/cs631apue/attachments/20191005/e2830f3c/attachment.html>
More information about the cs631apue
mailing list